A small ruby library and executable to create pic scripts suitable to be printed as graphics
Add this line to your application's Gemfile:
And then execute:
Or install it yourself as:
$ gem install csgraph
Once installed, you can use
csgraph as specified below.
If you have a
simple.csg file like so:
instr 1 do line p2, p2+p3, p5, p5 end
simple.sco file like so:
i1 3.2 3 -8 600 i1 0 3 -8 500 i1 6.4 3 -8 700
then you can write on your terminal:
csgraph -f simple.csg simple.sco | groff -p -P-l -rN2 | ps2pdf - simple.pdf
simple.pdf will be something like:
This is a work in progress. Please come back often for more info. If you wish to help, check us out on Gitter! You will be most welcome.
After checking out the repo, run
bin/setup to install dependencies. Then, run
bin/console for an interactive prompt that will allow you to experiment. Run
bundle exec csgraph to use the code located in this directory, ignoring other installed copies of this gem.
To install this gem onto your local machine, run
bundle exec rake install. To release a new version, update the version number in
version.rb, and then run
bundle exec rake release to create a git tag for the version, push git commits and tags, and push the
.gem file to rubygems.org.
- Fork it ( https://github.com/[my-github-username]/csgraph/fork )
- Create your feature branch (
git checkout -b my-new-feature)
- Commit your changes (
git commit -am 'Add some feature')
- Push to the branch (
git push origin my-new-feature)
- Create a new Pull Request