Skip to content

Instantly share code, notes, and snippets.

@vernalkick
Last active August 29, 2015 14:11
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 vernalkick/9ce9d678c258b5af5a9f to your computer and use it in GitHub Desktop.
Save vernalkick/9ce9d678c258b5af5a9f to your computer and use it in GitHub Desktop.
require 'rest_client'
params = {
:path => "test.txt",
:message => "Test Commit",
:committer => {
:name => "Kevin Clark",
:email => "kevin@kevinclark.ca"
},
:content => "bXkgbmV3IGZpbGUgY29udGVudHM="
}
header = {
:Authorization => "token <TOKEN>"
}
RestClient.put "https://api.github.com/repos/vernalkick/kevinclark/contents/test.txt", params, header
@vernalkick
Copy link
Author

This gives me a

404 Resource Not Found: {"message":"Not Found","documentation_url":"https://developer.github.com/v3/repos/contents/"}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment