Skip to content
Newer
Older
100644 120 lines (73 sloc) 3.26 KB
94462d9 Partial gemification of CodeRippa
Benjamin Tan Wei Hao authored Mar 26, 2012
1 # CodeRippa
2
6138bfb added travis ci badge
Benjamin Tan Wei Hao authored Apr 1, 2012
3 [![Build Status](https://secure.travis-ci.org/benjamintanweihao/code_rippa.png)](http://travis-ci.org/benjamintanweihao/code_rippa)
4
33f2f8f updated readme file. Improved exit codes
Benjamin Tan Wei Hao authored Mar 26, 2012
5 CodeRippa takes your source code and turns it into a beautiful PDF file. Currently, it supports 150 languages and 15 themes, all of which are available in TextMate. More syntaxes and themes will be available soon.
94462d9 Partial gemification of CodeRippa
Benjamin Tan Wei Hao authored Mar 25, 2012
6
51a68c0 Themes! Glorious themes
Benjamin Tan Wei Hao authored Apr 5, 2012
7 ## Prerequisites
db39502 Long lines wrap nicely, using a method I stole from Gem::Command. Upd…
Benjamin Tan Wei Hao authored Apr 5, 2012
8
9 You will definitely need a TeX distribution installed. To check, simply type `pdflatex`.
10 In case your system doesn't have `pdflatex`, you should install a [LaTeX](http://www.tug.org/texlive/) distribution.
11
94462d9 Partial gemification of CodeRippa
Benjamin Tan Wei Hao authored Mar 25, 2012
12 ## Installation
13
33f2f8f updated readme file. Improved exit codes
Benjamin Tan Wei Hao authored Mar 26, 2012
14 $ gem install code_rippa
94462d9 Partial gemification of CodeRippa
Benjamin Tan Wei Hao authored Mar 25, 2012
15
16 ## Usage
17
33f2f8f updated readme file. Improved exit codes
Benjamin Tan Wei Hao authored Mar 26, 2012
18 ### Command line options
19
20 Usage: code_rippa [options] file_or_directory
21 -l, --list-themes List all available themes
22 -t, --theme THEME Selected theme
23 -n, --list-syntax List all available syntax
24 -s, --syntax SYNTAX Selected syntax
25 -x, --excluded-exts E1,E2,EN Exclude these extensions when processing
26 -h, --help Display this screen
27
032f3a3 updated test cases to reflect removal of moc
Benjamin Tan Wei Hao authored Apr 5, 2012
28 ### List all available themes (84 and counting!)
33f2f8f updated readme file. Improved exit codes
Benjamin Tan Wei Hao authored Mar 26, 2012
29
30 $ code_rippa -l
31
32 active4d
33 all_hallows_eve
34 amy
032f3a3 updated test cases to reflect removal of moc
Benjamin Tan Wei Hao authored Apr 5, 2012
35 made_of_code
33f2f8f updated readme file. Improved exit codes
Benjamin Tan Wei Hao authored Mar 26, 2012
36 twilight
37 zenburnesque
38 ... more themes omitted
39
032f3a3 updated test cases to reflect removal of moc
Benjamin Tan Wei Hao authored Apr 5, 2012
40 ### Themes Preview
41
42 Many of the themes found in CodeRippa can be found [here](http://wiki.macromates.com/Themes/UserSubmittedThemes)
43
33f2f8f updated readme file. Improved exit codes
Benjamin Tan Wei Hao authored Mar 26, 2012
44 ### List all supported syntax
45
46 $ code_rippa -n
47
48 actionscript
49 erlang
50 java
51 javascript
52 prolog
53 ruby
54 yaml
55 ... more syntaxes omitted
56
57 ### Producing PDF from a single file
58
59 Example:
60
61 $ code_rippa -s ruby -t zenburnesque path_to_single_file.rb
62
63 Note that the output file is saved as _out.tex_ in the current directory where _code_rippa_ was called from.
64
65 $ pdflatex out.tex # Saved as out.pdf
66
67 ### Producing PDF from a directory
68
69 Example:
70
032f3a3 updated test cases to reflect removal of moc
Benjamin Tan Wei Hao authored Apr 5, 2012
71 $ code_rippa -s java -t rubyblue path_to_directory
33f2f8f updated readme file. Improved exit codes
Benjamin Tan Wei Hao authored Mar 26, 2012
72
73 Note that the output file is saved as _out.tex_ in the current directory where _code_rippa_ was called from.
74
75 Then, you'll need to run _pdflatex_ __twice__. This is because LaTeX needs to generate the bookmarks.
76
77 $ pdflatex out.tex # Saved as out.pdf
78 $ pdflatex out.tex # Remember to run this twice!
79
80 ## Credits
81
d529423 removed dependency on linguist
Benjamin Tan Wei Hao authored Mar 27, 2012
82 None of this would be possible without the awesome [ultraviolet](https://github.com/giom/ultraviolet) and [spox-ultraviolet](https://github.com/spox/ultraviolet) gems. Props to [__lwheng__](https://github.com/lwheng) for providing most of the LaTeX help.
94462d9 Partial gemification of CodeRippa
Benjamin Tan Wei Hao authored Mar 25, 2012
83
84 ## Contributing
85
33f2f8f updated readme file. Improved exit codes
Benjamin Tan Wei Hao authored Mar 26, 2012
86 Currently this gem is in its infancy. Any bug reports and feature requests are very welcomed.
4364457 bumped up version number
Benjamin Tan Wei Hao authored Mar 27, 2012
87
88 ## Changelog
89
30bcac9 quickfix to avoid parsing files that take up a large amount of column…
Benjamin Tan Wei Hao authored Apr 5, 2012
90 ### 0.0.7.pre
91
51a68c0 Themes! Glorious themes
Benjamin Tan Wei Hao authored Apr 5, 2012
92 - Using [language_sniffer](https://github.com/grosser/language_sniffer) in place of Linguist for automated source code language detection
93 - Themes! Glorious themes! 77 themes to choose from! Props to [filmgirl](https://github.com/filmgirl/TextMate-Themes)
db39502 Long lines wrap nicely, using a method I stole from Gem::Command. Upd…
Benjamin Tan Wei Hao authored Apr 4, 2012
94 - Wrap lines of troublesome files such as minified javascript and parser generator outputs.
30bcac9 quickfix to avoid parsing files that take up a large amount of column…
Benjamin Tan Wei Hao authored Apr 4, 2012
95
96 #### TODO
97
db39502 Long lines wrap nicely, using a method I stole from Gem::Command. Upd…
Benjamin Tan Wei Hao authored Apr 4, 2012
98 - Sensible defaults, remove the need for inputting the syntax optional
99 - Generate warnings when syntax is not supported.
30bcac9 quickfix to avoid parsing files that take up a large amount of column…
Benjamin Tan Wei Hao authored Apr 4, 2012
100
136cf41 bumped up to 0.0.6
Benjamin Tan Wei Hao authored Apr 1, 2012
101 ### 0.0.6
102
103 - Include MiniTest specs
4ddd580 updated changelog
Benjamin Tan Wei Hao authored Mar 30, 2012
104
105 ### 0.0.5
106
107 - Better performance when parsing.
108 - Code documentation.
109
4364457 bumped up version number
Benjamin Tan Wei Hao authored Mar 27, 2012
110 ### 0.0.4
111
112 - Removed dependency on Linguist.
113 - Tidier code.
114
115 ### 0.0.1 - 0.0.3
116
117 - Initial gem push
118 - Fixed many stupid bugs along the way
119
Something went wrong with that request. Please try again.