Skip to content
/ gst Public

Painless CLI gist creator

License

Notifications You must be signed in to change notification settings

edvb/gst

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

gst - painless gist creator

Easy way to create GitHub Gists through the command line. Simply give it the files to upload and gst will return the URL to the new gist.

Options

-e ID

Edit previously created gist specified with ID

-d DESCRIPTION

Set gist description

-D FILE

Delete FILE from gist being edited

-f FILENAME

Set file name when reading from stdin

-g URL

Change the GitHub API URL (default: https://api.github.com/gists)

-p

Make gist private

-P

Make gist public (default)

-u USER[:PASSWORD]

Change the GitHub account the gist will be posted under. A password can given as well with a separating colon, a prompt is provided if not.

-U

Post gist anonymously (default)

-h

Print help and exit

-v

Print version info and exit

Usage

Create a new gist of file.txt:

$ gst file.txt
https://gist.github.com/<new-id>

There is also support for multiple files in a single gist:

$ gst README.md Makefile prog.c
https://gist.github.com/<new-id>

Specify the gist's description:

$ gst -d 'a cool shell script' script.sh
https://gist.github.com/<new-id>

The gist's URL can be piped to other programs, for example to your clipboard to