First, install the gist
command using brew install gist
, then add this to your .zshrc (or whatever).
By default this will:
- create all gists as secret (
-p
) - copy the gist url to the clipboard (
-c
) - open the browser to the gist (
-o
)
There are three modes for this CLI tool:
gist filename.json
will create a new gist from thefilename.json
with the namefilename.json
(basically the default usage of the normalgist
command)cat filename.json | gist
will create a new gist fromSTDIN
gist
will paste whatever's on the clipboard and create a new gist calledpaste.txt
so useful, thanks! 👍