View rebase.py
#!/usr/bin/env python3 | |
# -*- coding: utf-8 -*- | |
import re | |
import subprocess | |
""" GIT LOG EXAMPLE: | |
0eccd52 (HEAD -> froga) 02 # <- COUNT: FROM THIS | |
67239d6 01 | |
fb3c480 12 |
View gist:10cd50e62d181615bf696520c8a9b159
#!/bin/bash | |
ffmpeg -i input.mp4 -vf eq=brightness=0.08 -c:a copy output.mp4 |
View temp.sh
#!/bin/bash | |
# Script: my-pi-temp.sh | |
# Purpose: Display the ARM CPU and GPU temperature of Raspberry Pi 2/3 | |
# Author: Vivek Gite <www.cyberciti.biz> under GPL v2.x+ | |
# ------------------------------------------------------- | |
cpu=$(</sys/class/thermal/thermal_zone0/temp) | |
gpu=$(/opt/vc/bin/vcgencmd measure_temp) | |
gpu=${gpu/temp=/} | |
gpu=${gpu/\'C/} | |
echo "$(date) @ $(hostname)" |
View Xwrapper.config
# /etc/X11/Xwrapper.config | |
allowed_users = anybody |
View 000-default.conf
VirtualHost *:80> | |
ServerAdmin zital@riseup.net | |
ServerName zital-pi.no-ip.org | |
<Directory "/var/www/html"> | |
Require all denied | |
</Directory> | |
RewriteEngine on | |
RewriteRule "^/bermiotarra$" "/bermiotarra/" [L,R=301] |
View TwitterRemoveFavRT.js
// ==UserScript== | |
// @name TwitterRemoveFavRT | |
// @namespace TwitterRemoveFavRT | |
// @description Twitter-eko FAV, RT eta SUSTATU-tako txiuek kenduteko script-tsue | |
// @include https://*.twitter.com/* | |
// @grant none | |
// @version 1 | |
// @license AGPL v3 | |
// ==/UserScript== |
View clean_words_merged.py
#!/usr/bin/python3 | |
# -*- coding: utf-8 -*- | |
from lxml import etree | |
import re | |
file = open("words_merged.xml", "r") | |
dom = etree.parse(file) | |
wl = dom.xpath('//wordlist/w') |
View random-near-numbers.js
class RandomNearNumbersClass | |
{ | |
_random(min, max) | |
{ | |
return Math.floor(Math.random() * (max - min + 1) ) + min; | |
} | |
_getMinMax(value, amount, min, max) | |
{ | |
let _min = value - amount; |
View 01.sh
mkdir -p /home/projects/lit/src/components | |
cd /home/projects/lit | |
npm init -y | |
npm install lit-element webpack webpack-cli --save-dev | |
touch index.html | |
touch src/index.js | |
touch src/components/progress-bar.js |
View polymer_cli_install.sh
npm install -g polymer-cli --unsafe-perm |
NewerOlder