A small utility for making gists
Project description
mkgist
A small utility for making gists. When I need to share code snippets online, the formatting always ends up totally messed up when I copy-paste manually. This alleviates that.
Setup
With pip
The easiest way to get a copy is through pip3
:
pip3 install mkgist
Annoying things happen, at least on my system, without pip3
. I'll look into it at some point.
Manual
To install dependencies, run pip install -r requirements.txt
after installing. I don't use this within a virtual environment, but doing so would look something like this:
virtualenv -p $(which python3) $HOME/virtualenv/mkgist
source $HOME/virtualenv/mkgist/bin/activate
Usage
mkgist filenames [-d "description"] [--public] [--raw] [--nocopy]
- If no filenames are entered, the contents of the gist are read from STDIN.
- The location of the created gist is printed to stdout.
- Gists are secret by default, but can be made public with
--public
. (Secret gists aren't indexed by search engines) --raw
returns a link to the raw hosted file, which you can then get withcurl
orwget
. If multiple files are created with this flag, the URLs are always printed to stdout.- By default, the URL of the created Gist is copied to the clipboard.
--nocopy
prints the link to stdout instead, not overwriting the clipboard.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
mkgist-3.5.tar.gz
(3.7 kB
view details)
Built Distribution
mkgist-3.5-py3-none-any.whl
(4.8 kB
view details)
File details
Details for the file mkgist-3.5.tar.gz
.
File metadata
- Download URL: mkgist-3.5.tar.gz
- Upload date:
- Size: 3.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 058f6e15dc7f370123f103760d1e8441b9ea2a95bbfd4a67f3fce8b8e2bf0a8f |
|
MD5 | 681df7251d86f71101c80d25025d0de8 |
|
BLAKE2b-256 | b678f3e41ebbac5c4dc06c7c3ad96d0d44991abf4cd74714aaad41304cffaa98 |
File details
Details for the file mkgist-3.5-py3-none-any.whl
.
File metadata
- Download URL: mkgist-3.5-py3-none-any.whl
- Upload date:
- Size: 4.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f26a6d76b232e8d31e8ee211af534a6e9f9ad7279a576df422389e078b3e869c |
|
MD5 | bd454e24d621a02323c6a95ea30ce27c |
|
BLAKE2b-256 | b9dade5bdf29f437996bbe08b47733636827987afbc6decd0bfb07084f9bb620 |