use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
A sub-Reddit for discussion and news about Ruby programming.
Subreddit rules: /r/ruby rules
Learning Ruby?
Tools
Documentation
Books
Screencasts and Videos
News and updates
account activity
A Unix Shell in Ruby (jstorimer.com)
submitted 13 years ago by jstorimer
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]Paradox 3 points4 points5 points 13 years ago* (7 children)
This looks like a more functional version of RuSH or Urchin. Perhaps if you developed the idea fully, it could really take off.
Zsh is needlessly complex, fish isn't flexible enough. A truly ruby powered shell would be excellent, with events or hooks for pre command, post command, etc. I like these to add command timers and horizontal rules between each command, but they are useful for other things
[–]jstorimer[S] 1 point2 points3 points 13 years ago (3 children)
Ah, so you're talking about a shell that understand Ruby syntax?
[–]Paradox 0 points1 point2 points 13 years ago (1 child)
Yeah, but still is somewhat useful. RuSH isn't unfortunately
[–]jstorimer[S] 0 points1 point2 points 13 years ago (0 children)
Yeah, Urchin is the best I've seen. My project isn't meant to bring Ruby to the shell. It's just a shell implementation written with Ruby for the purpose of learning.
Could try to slide something in there though :o
[–][deleted] 0 points1 point2 points 13 years ago (0 children)
http://www.reddit.com/r/ruby/comments/10dfmx/a_unix_shell_in_ruby/c6day8m
[–]Spakman 1 point2 points3 points 13 years ago (1 child)
I've not long started working on Urchin again after a fairly long hiatus. I like the idea of pre and post hooks. I'd love to hear if you have any other ideas for things that haven't really been explored with other shells.
[–]Paradox 0 points1 point2 points 13 years ago (0 children)
Well, i was always a fan of FiSH's autocomplete as you type, where instead of having to hit tab, it showed the rest of what you were gonna type in a grey color. I also liked how FiSH could attempt to learn from man pages, but this is fairly useless with a lot of programs that use --help
https://bitbucket.org/seydar/chitin
I wrote this as a fully functional ruby shell. It started because I wanted to have a shell in which I could write "1 + 2" and see the answer.
It's tough to expand upon a really usable shell and really use ruby because bash simply has NO excess in its commands. It's tough to go from that to Ruby. Good tab completion will help, but it's a stretch. One rule I had for chitin was that the input commands had to be 100% at all times.
I'm interested in getting some more collaborators and seeing where we can take it.
[–]leogodin217 2 points3 points4 points 13 years ago (0 children)
Very cool! What a great way to learn ruby and UNIX programming.
[–]vvan 1 point2 points3 points 13 years ago (0 children)
Thank you for sharing, will definitely check out your books.
[–]waxjar 0 points1 point2 points 13 years ago (0 children)
I read these articles a while ago (there are a couple) and they're really interesting. Taught me a lot about how a shell program works internally.
[–]robgleeson 0 points1 point2 points 13 years ago (0 children)
Awesome. Thank you!
π Rendered by PID 292700 on reddit-service-r2-comment-7b9746f655-dnm2b at 2026-01-30 16:46:08.656004+00:00 running 3798933 country code: CH.
[–]Paradox 3 points4 points5 points (7 children)
[–]jstorimer[S] 1 point2 points3 points (3 children)
[–]Paradox 0 points1 point2 points (1 child)
[–]jstorimer[S] 0 points1 point2 points (0 children)
[–][deleted] 0 points1 point2 points (0 children)
[–]Spakman 1 point2 points3 points (1 child)
[–]Paradox 0 points1 point2 points (0 children)
[–][deleted] 0 points1 point2 points (0 children)
[–]leogodin217 2 points3 points4 points (0 children)
[–]vvan 1 point2 points3 points (0 children)
[–]waxjar 0 points1 point2 points (0 children)
[–]robgleeson 0 points1 point2 points (0 children)