Skip to content

Instantly share code, notes, and snippets.

@17500mph
17500mph / camera.py
Created August 27, 2021 05:19 — forked from cbednarski/camera.py
Webcam capture for python - Pops up a preview from your webcam and snaps a picture when you press 'q'
import cv2
# Windows dependencies
# - Python 2.7.6: http://www.python.org/download/
# - OpenCV: http://opencv.org/
# - Numpy -- get numpy from here because the official builds don't support x64:
# http://www.lfd.uci.edu/~gohlke/pythonlibs/#numpy
# Mac Dependencies
# - brew install python
@17500mph
17500mph / nginx_google_analytics
Created August 29, 2020 05:07 — forked from srstsavage/nginx_google_analytics
google analytics in nginx
# send logs for all traffic (including non-html) to google analytics
#
# in server block:
# set $google_analytics_id "UA-THECORRECT-ID";
# include /srv/nginx/google_analytics;
#
# in location blocks:
# post_action @ga;
#
# notes: post_action has been referred to by nginx devs as a "dirty hack" and this approach may stop working one day.
# Beets configuration --------------------------------------------------------
directory: /music/ORDERED
import:
# write metadata to music files
write: yes
# move imported files from source to the music directory
copy: no