Pastie now auto-senses if line-wrap is a bad or good idea. Feedback?
## mark a section (Learn more)
## save to bulkedit.rb if ARGV.size < 5 puts "ruby bulkedit.rb MYTOKEN MYACCOUNT MYPROJECT QUERY COMMAND [MIGRATION_TOKEN]" puts puts "example: ruby bulk edit.rb 1sdfasd23rfSDfasdf shake-and-bake 1 \"milestone:\\\"1.0 Launch\\\" state:open\" \"milestone:next\"" puts puts "see also: http://help.lighthouseapp.com/faqs/ticket-workflow/ticket-keyword-updates" puts "problems? http://help.lighthouseapp.com" exit end token = ARGV.shift account = ARGV.shift project = ARGV.shift params = {'query' => ARGV.shift, 'command' => ARGV.shift, 'migration_token' => ARGV.shift} lh_domain = ENV['LH_DOMAIN'] || "lighthouseapp.com" require 'net/http' require 'uri' res = Net::HTTP.post_form URI.parse("http://#{token}:x@#{account}.#{lh_domain}/projects/#{project}/bulk_edit.json"), params if res.body == ' ' puts "Done!" else puts res.body end
This paste will be private.
From the Design Piracy series on my blog: