a. Download replace-text.sh
b. Clone the gist repo in the same directory as replace-text.sh
-
using SSH url:
git clone git@gist.github.com:<reponame (hash)>
-
using HTTPS url:
# Normalizes filenames and folders !! | |
# because fuck you HFS+ | |
# I hate you so | |
# so much | |
# Very WIP and probably abandoned because | |
# I dont feel like fixing the bugs and i'll just | |
# consider all this as wasted time and redo my | |
# rsync command with `--iconv=utf-8-mac,utf-8`, |
// ==UserScript== | |
// @name Blocket bostad Google Maps | |
// @namespace http://tampermonkey.net/ | |
// @version 0.2 | |
// @description try to take over the world! | |
// @author You | |
// @downloadURL https://gist.github.com/iwconfig/69c74cf7fa57ef9034c0b0dee7fa20e5/raw/blocket-bostad-google-maps.user.js | |
// @updateURL https://gist.github.com/iwconfig/69c74cf7fa57ef9034c0b0dee7fa20e5/raw/blocket-bostad-google-maps.user.js | |
// @supportURL https://gist.github.com/iwconfig/69c74cf7fa57ef9034c0b0dee7fa20e5 | |
// @match https://bostad.blocket.se/* |
#!/usr/bin/env bash | |
ryml () { local IFS=': ' ; read E C ;} | |
while ryml; do # alternatively: while IFS=': ' read E C; do | |
case $E in | |
parent) | |
parent=${E} ;; | |
child) | |
echo ${parent}.${E}: ${C} ;; |
#!/usr/bin/env bash | |
rdom () { local IFS=\> ; read -d \< E C ;} | |
while rdom; do # alternatively: while IFS=\> read -d \< E C; do | |
case $E in | |
tvshow|episodedetails) | |
parent=${E} ;; | |
title|showtitle|season|episode|plot|aired|thumb) | |
echo ${parent}.${E}: ${C} ;; |
// ==UserScript== | |
// @name för helvete biltema ge mig exakt lagerstatus | |
// @namespace https://github.com/iwconfig | |
// @version 0.3 | |
// @description 1337 st på lagret istället för (13+) | |
// @author iwconfig | |
// @updateURL https://gist.github.com/iwconfig/da9d124977802230732cac0679a3ecfa/raw/vafan-biltema-exakt-lagerstatus.user.js | |
// @match https://www.biltema.se/* | |
// @icon https://www.google.com/s2/favicons?domain=biltema.se | |
// @grant none |
""" | |
Add copy to clipboard from IPython! | |
To install, just copy it to your profile/startup directory, typically: | |
~/.ipython/profile_default/startup/ | |
Example usage: | |
%clip hello world | |
# will store "hello world" |
#!/usr/bin/env python3 | |
# This script is supposed to be used with a remote torrent client, | |
# such as transmission-remote-gtk. Add this script as a local command | |
# and it will check if the file/dir has been sorted by filebot and if | |
# so, open the sorted file path. If not, open the path to the unsorted | |
# path (i.e. file/dir in 'Downloads' folder). It translates the path | |
# to correspond to the local mount point (samba share).To parse the | |
# xml file from filebot I use the untangle package because I'm lazy | |
# and because it's so easy to use. Install it with pip. |
#!/usr/bin/env python3 | |
# Note: on synology, make sure your user is added to transmission | |
# group so you can have read and write access to the destination | |
# without sudo. | |
import subprocess, sys, pwd, grp, os | |
processed_path = '/tmp/filebot-output-dir' |
import threading, webbrowser | |
from http.server import BaseHTTPRequestHandler, HTTPServer | |
from urllib.parse import urlparse, parse_qs | |
class S(BaseHTTPRequestHandler): | |
def do_GET(self): | |
code = parse_qs(urlparse(self.path).query)['code'][0] | |
threading.Thread(target=httpd.shutdown, daemon=True).start() | |
def callback_server(server_class=HTTPServer, handler_class=S, port=8080): |