Skip to content

Ruby#Creating a gem

Samuel Kerr edited this page Feb 7, 2016 · 3 revisions

Creating a rubygem

foo.gemspec

require File.expand_path("../lib/foodie/version", __FILE__)

Gem::Specification.new do |s| s.name = "foodie" s.version = Foodie::VERSION s.platform = Gem::Platform::RUBY s.authors = [] s.email = [] s.homepage = "http://rubygems.org/gems/foodie" s.summary = "TODO: Write a gem summary" s.description = "TODO: Write a gem description"

s.required_rubygems_version = ">= 1.3.6" s.rubyforge_project = "foodie"

s.add_development_dependency "bundler", ">= 1.0.0"

s.files = git ls-files.split("\n") s.executables = git ls-files.split("\n").map{|f| f =~ /^bin\/(.*)/ ? : nil}.compact s.require_path = 'lib' end

Clone this wiki locally