Instantly share code, notes, and snippets.

View Dockerfile
FROM ruby:2.3.1-alpine
MAINTAINER Keifer Furzland <kfrz.code@gmail.com>
# Env
ENV REFRESHED_AT 2016-09-21
ENV REPO_DIR /home/ticketbuster/repo
ENV GEM_HOME /home/ticketbuster/gems
ENV ENV_FILE /home/ticketbuster/repo/.env
ENV BUILD_PACKAGES bash libffi-dev openssl-dev linux-headers zlib-dev readline-dev yaml-dev git curl-dev ruby-dev build-base
ENV RUBY_PACKAGES ruby-io-console ruby-bundler nodejs libxml2-dev mysql-dev mariadb-dev
View ffmpeg-cheatsheet.md

FFmpeg Cheat Sheet for 360º video

Brought to you by Headjack

 
FFmpeg is one of the most powerful tools for video transcoding and manipulation, but it's fairly complex and confusing to use. That's why I decided to create this cheat sheet which shows some of the most often used commands.

 
Let's start with some basics:

  • ffmpeg calls the FFmpeg application in the command line window, could also be the full path to the FFmpeg binary or .exe file
View ffmpeg.md

These are a few quick easy ffmpeg command lines that can be used to make oft-used video formats. I use them a lot so I wrote them down in a txt file but I converted it to markdown to upload here and access on all my pcs.

Feel free to use 'em. I've gathered them through superuser posts, wiki trawls, and personal experience.

General notes

  • Add -movflags faststart to make mp4 files have their headers at the beginning of the file, allowing them to be streamed (i.e. played even if only part of the file is downloaded).
  • mp4 container supports mp3 files, so if libfdk_aac isnt available (it's the only good aac enc) use libmp3lame.
  • For mp4 files, use -preset X to use mp4 enc presets, like slow or superfast. (veryfast or fast is ok)
  • c:v refers to the video codec used (codec: video). Likewise, c:a is audio. If you're using -map or something, this can be extended (-c:a:0: codec: audio: stream 0)
View PyTorStemPrivoxy.md

Crawling Anonymously with Tor in Python

adapted from the article "Crawling anonymously with Tor in Python" by S. Acharya, Nov 2, 2013.

The most common use-case is to be able to hide one's identity using TOR or being able to change identities programmatically, for example when you are crawling a website like Google and you don’t want to be rate-limited or blocked via IP address.

Tor

Install Tor.

View LICENCE SUBLIME TEXT
## Sublime Text 3 Serial key build is 3103
—– BEGIN LICENSE —–
Michael Barnes
Single User License
EA7E-821385
8A353C41 872A0D5C DF9B2950 AFF6F667
C458EA6D 8EA3C286 98D1D650 131A97AB
AA919AEC EF20E143 B361B1E7 4C8B7F04
B085E65E 2F5F5360 8489D422 FB8FC1AA
View error
*** Error in `appstreamcli': double free or corruption (fasttop): 0x000000000264d790 ***
======= Backtrace: =========
/lib/x86_64-linux-gnu/libc.so.6(+0x77725)[0x7f6c994f4725]
/lib/x86_64-linux-gnu/libc.so.6(+0x7ff4a)[0x7f6c994fcf4a]
/lib/x86_64-linux-gnu/libc.so.6(cfree+0x4c)[0x7f6c99500abc]
/usr/lib/x86_64-linux-gnu/libappstream.so.3(as_component_complete+0x439)[0x7f6c99878d19]
/usr/lib/x86_64-linux-gnu/libappstream.so.3(as_data_pool_update+0x44a)[0x7f6c99879f0a]
/usr/lib/x86_64-linux-gnu/libappstream.so.3(as_cache_builder_refresh+0x1c2)[0x7f6c9986f272]
appstreamcli(ascli_refresh_cache+0x12e)[0x4049de]
appstreamcli(as_client_run+0x6fb)[0x403ceb]
View Sublime Text License Key.md
View Sublime Text License Key.md
View Install php70 through brew on ubuntu or mint
Mint/Ubuntu - install php70 with brew
Cannot find /usr/sbin/apxs:
$ sudo apt-get install apache2-dev;
$ sudo ln -s /usr/bin/apxs /usr/sbin/apxs;
$ sudo ln -s /usr/bin/apxs2 /usr/sbin/apxs2;
configure: error: Cannot find sys/sdt.h which is required for DTrace support:
$ sudo apt-get install systemtap-sdt-dev;
View git-author-rewrite.sh
#!/bin/sh
git filter-branch --env-filter '
OLD_EMAIL="your-old-email@example.com"
CORRECT_NAME="Your Correct Name"
CORRECT_EMAIL="your-correct-email@example.com"
if [ "$GIT_COMMITTER_EMAIL" = "$OLD_EMAIL" ]
then