Simplicity [mailto:firstname.lastname@example.org] wrote last Tuesday, April 04, 2006 3:24 PM:
#I suppose anyone can make something complex or messy, no
#matter what the language or tool. Agree?
yes, but why care/think about that (and worst, aim for it??) ?
programmers solve (people's) problems. it is not easy solving problems. Ergo, the humble programmer must find ways that will make his life happy... On my case, I found ruby, and it has lesser "abstraction impedance", and it has made me happy. Agree?
kind regards -botp
I think this may be more of a unix question than a Ruby question...
If I create a test script:
echo "echo hello world" > test_script
On "source" this from the unix command line:
...and I get the expected result.
I can also run it from the unix command line:
chmod 755 ./test_script
...again, I get the expected result.
However, if I now dive in to irb and try to run the script...
It comes back with:
(irb):1: command not found: ./test_script
However, if I ammend test_script by adding a sh'bang line at the start,
so that it now reads...
echo hello world
And run it from irb, it will "do the right thing". I'm just wondering
Thankyou for any elucidation,
I'm not sure people purposely aim for complexity, it is something that
many people, in my experience, just do naturally. Don't know why.
Maybe, it's an attempt to create something better than it needs to be,
but resulting in something more complex than necessary.
I agree. We all want to get home early, enjoy the family, and have a
life. Work smarter, not longer. Choosing the right tools for the job
is a smart thing.
It's because your shell is made to read shell scripts. Ruby needs to
know what to use if it's a different syntax than ruby.