RubyFlow The Ruby and Rails community linklog

Use Ruby as your shell

with fresh, the Fresh Ruby Enhanced Shell. Using a regex, it determines, whether you want to evaluate Ruby or call a system command. Example session.

Comments

seems like scanning the directories in $PATH or even the standard set of /bin, /usr/bin, /usr/local/bin, etc. would be a good way to populate the set of words recognized as system commands.

Thanks for the idea. I think, I’ll do it that way.

There was also rush which I believe is was more comprehensive than this.

rush feels different. It’s a cool project, but it goes another way. In fresh, not every command you are writing is Ruby and has to obey its syntax - so you can, for example, call system commands with their string arguments, without using commas or quotes. However, rush has a much better interaction between the system calls and Ruby manipulation of those.

I’ve also been working on a Unix shell in Ruby - Urchin.

Post a comment

You can use basic HTML markup (e.g. <a>) or Markdown.

As you are not logged in, you will be
directed via GitHub to signup or sign in