Sha256: 1c8c43ae5dca291a98b345067b986fdaa2866e3f91123b8991ada79c26f1058f
Contents?: true
Size: 704 Bytes
Versions: 2
Compression:
Stored size: 704 Bytes
Contents
require 'pathname' require 'rubygems' require 'rake' require 'rake/clean' require 'fileutils' require 'echoe' version = YAML.load_file(Pathname(__FILE__).dirname + 'VERSION.yml').join('.') rescue nil echoe = Echoe.new('random_text', version) do |p| p.author = 'toy' p.summary = 'A library to generate random strings.' p.project = 'toytoy' end desc "Replace system gem with symlink to this folder" task 'ghost' do gem_path = Pathname(Gem.searcher.find(echoe.name).full_gem_path) current_path = Pathname('.').expand_path cmd = gem_path.writable? && gem_path.parent.writable? ? %w() : %w(sudo) system(*cmd + %W[rm -r #{gem_path}]) system(*cmd + %W[ln -s #{current_path} #{gem_path}]) end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
random_text-1.0.1 | Rakefile |
random_text-1.0.0 | Rakefile |