2017-05-29 16:02:09 +01:00
|
|
|
# gist
|
|
|
|
|
|
|
|
> Upload code to https://gist.github.com.
|
2019-06-07 11:58:24 +01:00
|
|
|
> More information: <https://github.com/defunkt/gist>.
|
2017-05-29 16:02:09 +01:00
|
|
|
|
2021-05-14 01:42:15 +01:00
|
|
|
- Log in in gist on this computer:
|
2017-08-25 12:53:33 +01:00
|
|
|
|
|
|
|
`gist --login`
|
|
|
|
|
2017-05-29 16:02:09 +01:00
|
|
|
- Create a gist from any number of text files:
|
|
|
|
|
|
|
|
`gist {{file.txt}} {{file2.txt}}`
|
|
|
|
|
|
|
|
- Create a private gist with a description:
|
|
|
|
|
2021-04-02 17:59:30 +01:00
|
|
|
`gist --private --description "{{A meaningful description}}" {{file.txt}} `
|
2017-05-29 16:02:09 +01:00
|
|
|
|
2021-01-31 17:05:18 +00:00
|
|
|
- Read contents from stdin and create a gist from it:
|
2017-05-29 16:02:09 +01:00
|
|
|
|
|
|
|
`{{echo "hello world"}} | gist`
|
|
|
|
|
|
|
|
- List your public and private gists:
|
|
|
|
|
2021-04-02 17:59:30 +01:00
|
|
|
`gist --list`
|
2017-05-29 16:02:09 +01:00
|
|
|
|
2021-04-02 17:59:30 +01:00
|
|
|
- List all public gists for any user:
|
2017-08-25 12:53:33 +01:00
|
|
|
|
2021-04-02 17:59:30 +01:00
|
|
|
`gist --list {{username}}`
|
2017-08-25 12:53:33 +01:00
|
|
|
|
2021-08-15 18:59:09 +01:00
|
|
|
- Update a gist using the ID from URL:
|
2017-05-29 16:02:09 +01:00
|
|
|
|
2021-04-02 17:59:30 +01:00
|
|
|
`gist --update {{GIST_ID}} {{file.txt}}`
|