lab 21 More Structure
NOTE: the content of the Rakefile is a script for running the Ruby code, you just need to copy it's content. Also no need to run 'rake'.
Goals
- Add another file to our repository
Now add a Rakefile 01
Let’s add a Rakefile to our repository. The following one will do nicely.
File: Rakefile
#!/usr/bin/ruby -wKU task :default => :run task :run do require './lib/hello' end
Add and commit the change.
Execute:
git add Rakefile git commit -m "Added a Rakefile."
You should be able to use Rake to run your hello program now.
Execute (optianal):
rake
Output:
$ rake Hello, World!