Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Store GitHub credentials in a configuration file #61

Closed
sjackman opened this issue Jun 15, 2014 · 4 comments
Closed

Store GitHub credentials in a configuration file #61

sjackman opened this issue Jun 15, 2014 · 4 comments
Milestone

Comments

@sjackman
Copy link

I'm running grip --export from the command line, and the result is an HTML file composed of 403 Forbidden. Could a ~/.grip.conf file contain the username and GitHub API token?

See #48 Clarify 403 API "rate limit exceeded" errors in the application

@joeyespo joeyespo added this to the 2.1 milestone Jun 29, 2014
@joeyespo
Copy link
Owner

Do you mean API token, or user password as used with --pass.

Do you know how to set up an API token?

@joeyespo
Copy link
Owner

Fixed this with f712f86.

By fixed, I mean that you can add a settings.py file to your ~/.grip directory and settings can be read from there. You can add USERNAME and PASSWORD variables there.

If you really did mean "API token", let's open another issue for that, covering that feature across the entire app (as opposed to just in this new config file). That is, let's have it cover the CLI argument, configuration options, the actual token-sending functionality, and updating the docs. In the meantime, since this settings.py file is just a Python file, you can add code there to prompt for you password instead of storing it there.

Does this help?

@joeyespo joeyespo changed the title Store GitHub API token in a configuration file Store GitHub credentials in a configuration file Jul 21, 2014
@sjackman
Copy link
Author

The utility gist has a gist --login feature that works well. Perhaps grip could model its authentication after gist.

https://github.com/defunkt/gist#login

@joeyespo
Copy link
Owner

I like that. Good find!

Grip does allow you to use OAuth now, but I'll open a new issue for improving the configuration experience like Gist.

Thanks for sharing, @sjackman!

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

No branches or pull requests

2 participants