Rebase
git rebase -i --root
Repeat N times
git --amend --no-edit --reset-author && git rebase --continue
export const Hook = < | |
F extends (...args: [...any]) => any, | |
Args extends Parameters<F>, | |
Returns extends ReturnType<F>, | |
CallableChild extends (returns: Returns) => ReactElement | |
>({ | |
f, | |
args, | |
children, | |
}: Args extends [] |
mod test { | |
use std::time::Instant; | |
// ... | |
fn my_function() { | |
let now = Instant::now(); | |
// do something here | |
let elapsed = now.elapsed(); |
'use strict'; | |
let conversion = require('phantom-html-to-pdf')(); | |
let fs = require('fs'); | |
let jsdom = require('jsdom'); | |
let domString = fs.readFileSync('my.html'); | |
let selectComponent = function (url, selector, cb) { | |
jsdom.env( |
#!/bin/sh | |
ID=`xinput list --id-only "ThinkPad Keyboard"` || (echo "Failed to find ThinkPad Keyboard"; exit 1;) | |
echo "Found ThinkPad Keyboard ID: $ID" | |
echo "Setting Evdev Wheel Emulation ... "; | |
# Originally 0 | |
EVDEV_WHEEL_EMULATION=1 | |
xinput set-prop $ID "Evdev Wheel Emulation" $EVDEV_WHEEL_EMULATION |
ID=`xinput list --id-only "pointer:Lite-On Technology Corp. ThinkPad USB Keyboard with TrackPoint"` | |
xinput set-float-prop $ID "Device Accel Velocity Scaling" 500 | |
xset mouse 15 15 |
#!/bin/sh | |
dbus-monitor "interface='com.ubuntu.Upstart0_6',member='EmitEvent'" | ( | |
while true; do | |
read X; | |
if [ "$X" = "string \"desktop-unlock\"" ]; then | |
xmodmap $HOME/.Xmodmap; | |
echo 1 $X; | |
else | |
echo 0 $X; |
Array.prototype.wrap = function (first, last) { | |
return [first].concat(this).concat([last || first]); | |
}; | |
Array.prototype.fill = function (filler) { | |
return this.map(function () { | |
return filler; | |
}); | |
}; | |
var filledArray = function (filler, length) { | |
return range(1, length).fill(filler); |
keycode 105 = Hangul_Hanja NoSymbol Hangul_Hanja | |
keycode 108 = Hangul NoSymbol Hangul | |
keycode 130 = Hangul NoSymbol Hangul | |
keycode 131 = Hangul_Hanja NoSymbol Hangul_Hanja |
http://www.thinkwiki.org/wiki/How_to_configure_the_TrackPoint |