RedCloth是一个令你可以在Ruby中使用Textile的模块。Textile是一个文本格式,一个非常简单的文本格式。可以将一个可读的文本转成HTML。
1.安装
$ gem install RedCloth
NB: The RedCloth gem name is CamelCase, not lowercase. If you mistakenly do a gem install redcloth
, you’ll get ERROR: could not find redcloth locally or in a repository
.
2源码安装:
$ git clone git://github.com/jgarber/redcloth.git
$ cd redcloth
$ rake install
You’ll need echoe and Ragel to compile it.
3.使用redcloth
RedCloth.new("Some text").to_html
#=> "<p>Some text</p>"
See the Official Textile Reference Manual for RedCloth 4 for help with Textile formatting
分享到:
相关推荐
redcloth使用,其包括了redcloth.rb以及页面显示用到的js,css,image.以及语法帮助。 博文链接:https://hooney.iteye.com/blog/208838
redcloth, RedCloth是一个用于将 Textile 转换为HTML的ruby 库 RedCloth - ruby的Textile 解析器主页redcloth.org维护者Joshua Siler github.com/joshuasiler作者Garber版权
RedCloth :: Formatters :: Plain 与RedCloth中包含的HTML和Latex格式化程序类似,此格式允许您将Textile转换为纯文本,而无需使用Textile语法。依存关系这个插件只需要 。例子RedCloth.new("p. this is *simple* _...
博文链接:https://mqqqvpppm.iteye.com/blog/112290
git-wiki 是使用 Git 做为数据存储的 wiki 引擎,使用 Ruby 开发。要求环境支持: rubygems sinatra grit redcloth rubypants 标签:gitwiki
Webgen网站的来源 ...$ gem install maruku rdiscount rdoc RedCloth sass $ gem install webgen-zurb_foundation-bundle $ gem install webgen-font_awesome-bundle $ gem install webgen-tipue_search-bund
JavaCloth 是流行的 RedCloth Textile / Markdown 解析器的 JRuby 支持的包装器
gem install RedCloth -v '4.2.9' gem install nokogiri -v '1.6.6.2' 克隆此存储库后,运行: bundle install以下载构建所需的依赖项。 bundle exec jekyll serve在本地运行,或bundle exec jekyll build ./...
Ruby降价促销处理器 Discount是...用法RDiscount实现了RedCloth流行并被BlueCloth采用的基本协议: require 'rdiscount'markdown = RDiscount.new("Hello World!")puts markdown.to_html创建RDiscount对象时,可以打