MicroPosts
- Clone and push to a GitHub gist
You need to "Clone via SSH" to be able to push to a GitHub gist:
- GitHub .diff and .patch URLs
Given a commit like https://github.com/3v0k4/hotdocs/commit/c6df526f432257cc1bd9bad86c4b57f948b33b11, you can see:
- The raw diff by appending .diff: https://github.com/3v0k4/hotdocs/commit/c6df526f432257cc1bd9bad86c4b57f948b33b11.diff
- The commit info (and raw diff) by appending .patch https://github.com/3v0k4/hotdocs/commit/c6df526f432257cc1bd9bad86c4b57f948b33b11.patch
- Tabs in GitHub textareas
You can use (Shift)+Tab to indent text on GitHub.
Useful when you paste some code like:
echo "indented"and want to de-indent it:
echo "ok" - Render Html, Css, and Js from a GitHub gist
You can use
https://gistpreview.github.io/?GIST_IDto render theindex.htmlfrom a gist:- https://gist.github.com/3v0k4/47fcdc2dfc1661cfb240748fc0d97f1b
- https://gistpreview.github.io/?47fcdc2dfc1661cfb240748fc0d97f1b
Use
https://gistpreview.github.io/?GIST_ID/FILE_NAMEfor any file:The raw content of a file (e.g., PNG) can be accessed with
https://gist.github.com/3v0k4/GIST_ID/raw/BLOB_ID/FILE_NAME. To get theBLOB_IDusegit ls-tree -r headin the cloned gist.