Skip to content

Instantly share code, notes, and snippets.

View defjaf's full-sized avatar

Andrew Jaffe defjaf

View GitHub Profile
@defjaf
defjaf / json_feed.mtml
Last active February 5, 2019 09:46 — forked from walt/json_feed.mtml
JSON Feed template for Movable Type
{
"version": "https://jsonfeed.org/version/1",
"title": "<$mt:BlogName smarty_pants="1" remove_html="1" escape_for_json="1"$>",
"home_page_url": "<$mt:BlogURL$>",
"feed_url": "<$mt:BlogURL$>feed.json",
"description": "<$mt:BlogDescription smarty_pants="1" remove_html="1" escape_for_json="1"$>",
"favicon": "<$mt:BlogURL$>favicon.ico",
"items": [
<mt:Entries lastn="5">
{
@defjaf
defjaf / upgrade_pip_packages.py
Last active April 2, 2020 17:16 — forked from serafeimgr/upgrade_pip_packages.py
A python script to upgrade all outdated python packages.
#!/usr/bin/env python2
"""
This script upgrades all outdated python packages.
"""
## based on https://gist.github.com/serafeimgr/b4ca5d0de63950cc5349d4802d22f3f0
## __author__ = "serafeimgr"
## modified by AHJ to allow different pip executables (pip2, pip3, etc)
## do we really want to do this with multiprocessing, or just a single giant call to pip?
## does the parsing really work given the new-style headers in the formatting?
## -- no: needed to add --format legacy; could also use freeze (split with "==")