Skip to content

Instantly share code, notes, and snippets.

View aaronzs's full-sized avatar
🦀

Aaron Sun aaronzs

🦀
View GitHub Profile
@aaronzs
aaronzs / upgrade_all_packages_with_pip.sh
Last active August 29, 2015 14:05
upgrade all packages with pip
# There isn't a built-in flag yet, but you can use
# Edit[0]: I've noticed that this fails when 'pip freeze' lists a package that cannot be installed from pypi anymore.
# Edit[1]: the command used to read "... | xargs echo pip install...", I've removed the "echo" so that the command actually performs the upgrade the install.
# Edit[2]: added a grep to skip "-e" package definitions, as suggested by @jawache
# Edit[3]: With newer versions of pip you can list outdated packages, though not in "requirements" format this possibility is actually built-in: pip list --outdated
# https://stackoverflow.com/questions/2720014/upgrading-all-packages-with-pip
pip freeze --local | grep -v '^\-e' | cut -d = -f 1 | xargs pip install -U
sudo -H pip3 freeze | xargs sudo -H pip3 uninstall -y
@aaronzs
aaronzs / HHKB-Professional.kbd.json
Last active March 12, 2023 14:40
HHKB Professional
[
{
"name": "HHKB Professional"
},
[
{
"c": "#b8b8b8",
"a": 6,
"f": 4
},
@aaronzs
aaronzs / alfred_raycast_snippets_cvt.py
Created February 25, 2023 03:15
Convert Alfred snippets to Raycast snippets
"""
Preparation:
Export Alfred snippets collection by right-clicking on the collection
and select "Export...".
Usage:
python3 alfred_raycast_snippets_cvt.py <alfred_snippets> [--output <output>]
"""
import argparse
import json
import plistlib