Download the inspect-registers.vim file from this gist. Open the file in Vim, launching with no vimrc:
vim -Nu NONE inspect-registers.vim
Source the file:
:source %
Insert text on line one:
Download the inspect-registers.vim file from this gist. Open the file in Vim, launching with no vimrc:
vim -Nu NONE inspect-registers.vim
Source the file:
:source %
Insert text on line one:
| # Complete words from tmux pane(s) {{{1 | |
| # Source: http://blog.plenz.com/2012-01/zsh-complete-words-from-tmux-pane.html | |
| # Gist: https://gist.github.com/blueyed/6856354 | |
| _tmux_pane_words() { | |
| local expl | |
| local -a w | |
| if [[ -z "$TMUX_PANE" ]]; then | |
| _message "not running inside tmux!" | |
| return 1 | |
| fi |
| #!/usr/bin/env sh | |
| ioreg -l | grep -i capacity | tr '\n' ' | ' | awk '{printf("%.2f%%\n", $10/$5 * 100)}' |
| function _common_section | |
| printf $c1 | |
| printf $argv[1] | |
| printf $c0 | |
| printf ":" | |
| printf $c2 | |
| printf $argv[2] | |
| printf $argv[3] | |
| printf $c0 | |
| printf ", " |
| // gcc grab.c -o grab -lX11 | |
| // ugly hack to catch windows key before application and change i3 workspace if windows+[0-9] is pressed | |
| // usage: grab winid_1 winid_2 ... | |
| // example: | |
| // grab `xwininfo -root -tree -int |grep " - Oracle VM VirtualBox" | awk '{print $1}'` | |
| #include <X11/X.h> | |
| #include <X11/Xlib.h> |
| <?php | |
| class InitialDbMigrationCommand extends CConsoleCommand | |
| { | |
| public function run($args) { | |
| $schema = $args[0]; | |
| $tables = Yii::app()->db->schema->getTables($schema); | |
| $addForeignKeys = ''; | |
| $dropForeignKeys = ''; |
| #!/usr/bin/env zsh | |
| # This script prints a bell character when a command finishes | |
| # if it has been running for longer than $zbell_duration seconds. | |
| # If there are programs that you know run long that you don't | |
| # want to bell after, then add them to $zbell_ignore. | |
| # | |
| # This script uses only zsh builtins so its fast, there's no needless | |
| # forking, and its only dependency is zsh and its standard modules | |
| # |
Some scripts/configurations that greatly improve tmux/vim workflows. The shell scripts target zsh but should be adaptable without much effort for other unix shells.
Features:
'vim-tmux-move.zsh', '.vimrc' and '.tmux.conf' cooperate so you can move transparently between tmux panes and vim windows using ALT + (arrow keys or jkhl). It was based on this gist
Tested against the WebKit git repo by entering the repo with 1 file dirty.
git diff --quiet --ignore-submodules HEAD # Will tell if there are any uncomitted changes, staged or not.
0.6 sec
git diff-index --quiet HEAD # Only tracked
2 sec