Skip to content

Instantly share code, notes, and snippets.

@sde1000
sde1000 / flacsplit.py
Created October 17, 2013 10:01
Script to split flac files with embedded cue sheet and tags into mp3s
#!/usr/bin/env python
"""Split a flac file with cuesheet and embedded tags into multiple
files, optionally re-encoded as mp3.
"""
version="0.1"
import os,subprocess,re,os.path,sys
@arunoda
arunoda / gist:7790979
Last active February 16, 2024 14:05
Installing SSHPass

Installing SSHPASS

SSHPass is a tiny utility, which allows you to provide the ssh password without using the prompt. This will very helpful for scripting. SSHPass is not good to use in multi-user environment. If you use SSHPass on your development machine, it don't do anything evil.

Installing on Ubuntu

apt-get install sshpass

Installing on OS X

@wbroek
wbroek / genymotionwithplay.txt
Last active February 12, 2024 03:22
Genymotion with Google Play Services for ARM
NOTE: Easier way is the X86 way, described on https://www.genymotion.com/help/desktop/faq/#google-play-services
Download the following ZIPs:
ARM Translation Installer v1.1 (http://www.mirrorcreator.com/files/0ZIO8PME/Genymotion-ARM-Translation_v1.1.zip_links)
Download the correct GApps for your Android version:
Google Apps for Android 6.0 (https://www.androidfilehost.com/?fid=24052804347835438 - benzo-gapps-M-20151011-signed-chroma-r3.zip)
Google Apps for Android 5.1 (https://www.androidfilehost.com/?fid=96042739161891406 - gapps-L-4-21-15.zip)
Google Apps for Android 5.0 (https://www.androidfilehost.com/?fid=95784891001614559 - gapps-lp-20141109-signed.zip)
@koron
koron / jquery.gc-helper.js
Last active December 17, 2015 11:05
Remove jQuery related objects when remove elements by DOM API
// jQuery GC Helper - v0.9.5
//
// Copyright (C) 2014 MURAOKA Taro
// Licensed under the MIT license.
(function(global, jQuery) {
var observer;
function callback(mutations) {
@yasainet
yasainet / ubuntu_nginx_basic.md
Last active January 21, 2021 03:19
ubuntu nginx basic認証を特定のパスにかける
  1. */etc/nginx/*に移動する
  2. 出力先のディレクトリオーナーがrootになっているのでteeコマンドを使ってリダイレクトする

$ cd /etc/nginx/

$ print "USER:$(openssl passwd -crypt PASSWORD)\n" | sudo tee .htpasswd

  1. .confファイルに.htpasswdへのパスを指定
@bancek
bancek / cue_to_mp3.py
Last active May 22, 2024 11:11
CUE splitter using ffmpeg (to mp3)
cue_file = 'file.cue'
d = open(cue_file).read().splitlines()
general = {}
tracks = []
current_file = None
@ItsAdventureTime
ItsAdventureTime / .rtorrent.rc
Created August 8, 2014 20:03
This an optimized version of the rTorrent configuration file.
#
#
# The Seedbox From Scratch Script
# By Notos ---> https://github.com/Notos/
#
#
######################################################################
#
# Copyright (c) 2013 Notos (https://github.com/Notos/)
#
@taufik-nurrohman
taufik-nurrohman / php-html-css-js-minifier.php
Last active February 23, 2024 04:30
PHP Function to Minify HTML, CSS and JavaScript
<?php
// Based on <https://github.com/mecha-cms/x.minify>
namespace x\minify\_ { // start namespace
$n = __NAMESPACE__;
\define($n . "\\token_boolean", '\b(?:true|false)\b');
\define($n . "\\token_number", '-?(?:(?:\d+)?\.)?\d+');
@soramugi
soramugi / radiko.sh
Last active April 13, 2024 06:17
radikoをlinuxで聞いたり録音したりするやつ
#!/bin/bash
# https://mtunn.wordpress.com/odroid-u2★セットアップ/radikoの録音・再生(archlinux)/
pid=$$
wkdir='/var/tmp'
playerurl=http://radiko.jp/player/swf/player_3.0.0.01.swf
playerfile="${wkdir}/player.swf"
keyfile="${wkdir}/authkey.png"
auth1_fms="${wkdir}/auth1_fms_${pid}"
auth2_fms="${wkdir}/auth2_fms_${pid}"
@ailispaw
ailispaw / patch.fix.tumblr.getTumblelogs.tbrl.js
Last active December 28, 2021 04:33
Fix Tumblr.getTumblelogs 2021.10
// ==Taberareloo==
// {
// "name" : "Fix Tumblr.getTumblelogs 2021.12"
// , "description" : "Fix Tumblr.getTumblelogs 2021.12"
// , "include" : ["background"]
// , "version" : "0.5.2"
// , "downloadURL" : "https://gist.githubusercontent.com/ailispaw/3aef8857c274e22f2b41/raw/patch.fix.tumblr.getTumblelogs.tbrl.js"
// }
// ==/Taberareloo==