Skip to content

Instantly share code, notes, and snippets.

View toyg's full-sized avatar
👔
c#-ing and python-ing

Giacomo Lacava toyg

👔
c#-ing and python-ing
View GitHub Profile
@toyg
toyg / Synopsifier.user.js
Last active June 25, 2018 14:39
Synopsifier.user.js
// ==UserScript==
// @name Synopsifier
// @namespace http://pythonaro.com/
// @version 1.0
// @description add movie details when browsing directories.
// @author toyg
// @match http://mc1.dl3enter.in/*
// @grant GM_xmlhttpRequest
// @connect themoviedb.org
// ==/UserScript==
@toyg
toyg / set_login_background.sh
Last active May 25, 2016 16:05
Change Login background image in OSX. Execute with sudo; takes 1 parameter, the path to your new file (must be a PNG image).
#!/bin/bash
chflags nouchg /Library/Caches/com.apple.desktop.admin.png
cp /Library/Caches/com.apple.desktop.admin.png /Library/Caches/com.apple.desktop.admin.BACKUP.png
cp $1 /Library/Caches/com.apple.desktop.admin.png
chflags uchg /Library/Caches/com.apple.desktop.admin.png
@toyg
toyg / 0_reuse_code.js
Created February 11, 2016 16:30
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
from sqlalchemy import create_engine, MetaData, Table, PrimaryKeyConstraint
from sqlalchemy.ext.declarative import declarative_base
from sqlalchemy.orm import sessionmaker
from sqlalchemy.dialects.oracle import RAW, NUMBER
from sqlalchemy.ext.compiler import compiles
from sqlalchemy.types import BINARY
@compiles(RAW, "oracle")
def compile_raw_oracle(type_, compiler, **kw):