Skip to content

Instantly share code, notes, and snippets.

@rodreegez
Created May 28, 2013 18:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rodreegez/5664910 to your computer and use it in GitHub Desktop.
Save rodreegez/5664910 to your computer and use it in GitHub Desktop.
Create a Gemfile with the specified gems.
#!/bin/bash
# Usage:
#
# $ gemfile sinatra
# $ cat Gemfile
# source 'https://rubygems.org'
# gem 'sinatra'
function gemfile {
echo "source 'https://rubygems.org'" > './Gemfile'
for var in "$@"
do
echo "gem '"$var"'" >> './Gemfile'
done
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment