Skip to content

Instantly share code, notes, and snippets.

View berceanu's full-sized avatar
:octocat:
long long ago; /* in a galaxy far far away */

Andrei Berceanu berceanu

:octocat:
long long ago; /* in a galaxy far far away */
View GitHub Profile

Uninstall brew package and dependencies

Remove package's dependencies (does not remove package):

brew deps [FORMULA] | xargs brew remove --ignore-dependencies

Remove package:

@berceanu
berceanu / pypi-release-checklist.md
Last active October 11, 2023 10:19 — forked from audreyfeldroy/pypi-release-checklist.md
My PyPI Release Checklist
  • Update HISTORY.rst
  • Commit the changes:
git add HISTORY.rst
git commit -m "Changelog for upcoming release 0.1.1."
  • Update version number (can also be minor or major)
bumpversion patch
@berceanu
berceanu / YT.ipynb
Created February 18, 2018 17:11 — forked from C0nsultant/YT.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@berceanu
berceanu / extract_emails_from_text.py
Created February 18, 2018 17:09 — forked from dideler/example.md
A python script for extracting email addresses from text files. You can pass it multiple files. It prints the email addresses to stdout, one address per line. For ease of use, remove the .py extension and place it in your $PATH (e.g. /usr/local/bin/) to run it like a built-in command.
#!/usr/bin/env python
#
# Extracts email addresses from one or more plain text files.
#
# Notes:
# - Does not save to file (pipe the output to a file if you want it saved).
# - Does not check for duplicates (which can easily be done in the terminal).
#
# (c) 2013 Dennis Ideler <ideler.dennis@gmail.com>
@berceanu
berceanu / imshow_slices.py
Created February 18, 2018 17:01 — forked from afvincent/imshow_slices.py
Display slices of a picture
import matplotlib.pyplot as plt
import numpy as np
from matplotlib.gridspec import GridSpec # only for Method 2
# A lot of information about GridSpec can be found here:
# https://matplotlib.org/tutorials/intermediate/gridspec.html
# Dummy data
uu = np.linspace(0, np.pi, 128)
data = np.cos(uu - 0.5) * np.cos(uu.reshape((-1, 1)) - 1.0)