This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ScrollLock:: Send {Media_Play_Pause} | |
Pause:: Send {Media_Next} | |
PrintScreen:: Send {Media_Prev} | |
NumpadAdd:: Send {Volume_Up} | |
NumpadSub:: Send {Volume_Down} | |
^E:: send, {END} | |
; Send delete back word | |
^BS:: send, ^+{left}{delete} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
command! HardTimeOn call HardTimeOn() | |
command! HardTimeOff call HardTimeOff() | |
fun! HardTimeOff() | |
silent! nunmap <buffer> h | |
silent! nunmap <buffer> j | |
silent! nunmap <buffer> k | |
silent! nunmap <buffer> l | |
silent! nunmap <buffer> - | |
silent! nunmap <buffer> + |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Contributor Ranking | |
# | |
# Author: Tom Cammann | |
# | |
function contrib_list { | |
# Find all email address names used to commit | |
authors=$( git log --format='%aE' | cut -d"@" -f1 | sort -u ) | |
# For each commit match no binary files that have changed and capture the number | |
# Only match java files |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let g:spotify_track_search_url = "http://ws.spotify.com/search/1/track.json?q=" | |
function! OpenUri(uri) | |
exec "silent !explorer " . a:uri | |
endfunction | |
function! OpenLine() | |
let uri = b:uris[line(".")-2] | |
call OpenUri(uri) | |
endfunction |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package fact; | |
import static java.lang.Math.PI; | |
import static java.lang.Math.exp; | |
import static java.lang.Math.log; | |
import static java.lang.Math.pow; | |
import static java.lang.Math.rint; | |
import static java.lang.Math.sqrt; | |
public class FactAndFib { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cowfortune() { | |
fortune | cowsay -f $(cowsay -l | sed -n '2,$s/ /\n/gp' | sort -R | head -n1) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
f() | |
{ | |
LAST=$(fc -l | tail -1 | sed 's/^\s*[0-9]\+\s\+//') | |
CMMD=${LAST%% *} | |
if [[ ${CMMD} == "mkdir" ]]; then | |
cd "${LAST#* }" | |
elif [[ ${CMDD} == "cd" ]]; then | |
cd - | |
elif [[ ${CMDD} == "fish" ]]; then | |
cd - |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/zsh | |
# Quick file finder. | |
# | |
# Search for whole term:- "*myterm*" | |
# $ fn search | |
# 0 search.py | |
# 1 dir/place/search-items.html | |
# 2 dir/my_search.lst | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function agv() | |
{ | |
command ag $@ | vim -c "setlocal buftype=nofile bufhidden=hide noswapfile" -c "let @/="'"'$@'"'" | set hls" - | |
} | |
# List files in git status using relative paths | |
function gip() | |
{ | |
# Can provide a matcher against the porcelain tags, i.e. "M ", "UU", etc | |
# If not provided return all files listed in git status |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -eu | |
if [[ ! -z "${DEBUG:-}" ]]; then | |
set -x | |
fi | |
function project_kube_check() { | |
PROJECT=${1:-$(gcloud config get-value project -q)} | |
ZONES=$(gcloud --project=$PROJECT --format='value[](zone)' container clusters list | uniq) |
OlderNewer