Closed jamesdabbs closed 8 years ago
require 'httparty' require 'pry' require './token'
body = { state: "closed" }.to_json
body2 = { body: File.read(FILE) }.to_json
close_3 = HTTParty.patch( "https://api.github.com/repos/tiyd-ror-2016-06/class-notes/issues/3", headers: { "Authorization" => "token #{Token}", "User-Agent" => "goggle cromagnus" }, body: body )
comment_3 = HTTParty.post( "https://api.github.com/repos/tiyd-ror-2016-06/class-notes/issues/3/comments", headers: { "Authorization" => "token #{Token}", "User-Agent" => "goggle cromagnus" }, body: body2 )
binding.pry
Write (and run) a ruby script that
You'll probably want to use
File.read __FILE__
for the script to read its own contents.