Skip to content

Instantly share code, notes, and snippets.

gstash() {
local out k reflog
out=(
$(git stash list --pretty='%C(yellow)%gd %>(14)%Cgreen%cr %C(blue)%gs' |
fzf --ansi --no-sort --header='enter:show, ctrl-d:diff, ctrl-o:pop, ctrl-y:apply, ctrl-x:drop' \
--preview='git stash show --color=always -p $(cut -d" " -f1 <<< {}) | head -'$LINES \
--preview-window=down:50% --reverse \
--bind='enter:execute(git stash show --color=always -p $(cut -d" " -f1 <<< {}) | less -r > /dev/tty)' \
--bind='ctrl-d:execute(git diff --color=always $(cut -d" " -f1 <<< {}) | less -r > /dev/tty)' \
--expect=ctrl-o,ctrl-y,ctrl-x))
@robertknight
robertknight / Build.md
Last active July 8, 2022 01:32
Minimal Webpack DllPlugin example

Compile with:

webpack --config vendor.webpack.config.js
webpack --config app.webpack.config.js

Use with the following index.html

@AWMooreCO
AWMooreCO / AdvancedWindowSnap.ahk
Last active April 6, 2024 01:29
Advanced Window Snap is a script for AutoHotKey that expands upon Windows built-in window-snapping hotkeys.
/**
* Advanced Window Snap
* Snaps the Active Window to one of nine different window positions.
*
* @author Andrew Moore <andrew+github@awmoore.com>
* @version 1.0
*/
/**
* SnapActiveWindow resizes and moves (snaps) the active window to a given position.
@louischan
louischan / firefox-gestures.md
Last active March 1, 2022 16:53
Enable Multi-touch Gestures in Firefox
  1. Open about:config in Firefox
  2. Set the following values
  3. Restart Firefox
browser.snapshots.limit           5
browser.gesture.pinch.in          cmd_fullZoomReduce
browser.gesture.pinch.out         cmd_fullZoomEnlarge
browser.gesture.pinch.latched     false
browser.gesture.pinch.threshold 35
@kafene
kafene / cb-aerosnap
Created July 22, 2014 20:48
A script for adding aero style window snapping to Openbox.
#!/usr/bin/env python
# cb-aerosnap:
# A script for adding aero style window snapping to Openbox.
# Written for CrunchBang Linux <http://crunchbang.org/>
# by Philip Newborough <corenominal@corenominal.org>
# ----------------------------------------------------------------------
# License:
# DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
# Version 2, December 2004
#
@TaurusOlson
TaurusOlson / minimal_statusline.vim
Created February 19, 2014 12:22
A minimal statusline for Vim
hi default link User1 Error
set statusline =
set statusline +=[%n] " buffer number
set statusline +=\ %F " Full path to file
set statusline +=\ %1*%m%0* " modified flag
set statusline +=\ %=%-20.30{tagbar#currenttag('%s','')} " Current function
set statusline +=\ %h " [help]
set statusline +=%r " read only flag
set statusline +=%w " preview window flag
set statusline +=%=%-14.(%l,%c%V%) " Line, column-virtual column"
@XVilka
XVilka / TrueColour.md
Last active April 8, 2024 14:02
True Colour (16 million colours) support in various terminal applications and terminals

THIS GIST WAS MOVED TO TERMSTANDARD/COLORS REPOSITORY.

PLEASE ASK YOUR QUESTIONS OR ADD ANY SUGGESTIONS AS A REPOSITORY ISSUES OR PULL REQUESTS INSTEAD!