i3-focus highlights the current window with focus. By default it shows a blue 8px inset border. Works only on linux (timerfd) and with i3 running.
./i3focus.py setup install
- pytimerfd
- xcffib
pip3 install pytimerfd xcffib
Proof of concept line by line python profiler.
It naively rewrites the input file by inserting begin and end statements around every line.
Simple statements (x = a + b
) have a large 3x overhead,
but overal it gives a good idea where performance issues are located.
Requires Python 3.5.
./lineprof.py /script/to/profile.py
- astunparse (optional)
Parse a vim undo file and transform it into a set of git commits.
usage: git-vim-read-undofile [-h] -f FILE [-u FILE] [-n NAME]
[--blobs | --trees] [-q]
import a vim undofile in git
optional arguments:
-h, --help show this help message and exit
-f FILE, --file FILE path to file
-u FILE, --undo FILE path to undofile
-n NAME, --name NAME filename in git
--blobs write only blobs
--trees write only blobs and trees
-q, --quiet show only last commmit hash
Export all the objects in a git repository in DOT format.
git dot [--show] [--commits] [--trees] [--refs] [--heads]
--show do not write to stdout; render to temporary file as svg
and show using default viewer
turn on filtering and enable: (multiple allowed)
--commits commit objects
--trees commit objects and tree objects
--refs refs ($GIT_DIR/refs)
--heads heads ($GIT_DIR/*HEAD)
$ install git-dot /usr/bin
$ touch file-a file-b
$ git init
$ git add file-a && git commit -m a
$ git branch branch-a
$ git add file-b && git commit -m b
$ git dot --show
$ git checkout HEAD^
...
You are in 'detached HEAD' state.
...
$ git dot --show
Minimal vi clone in python when no editor is available (like a microcontroller). Depends on Python 3 or MicroPython.
Simple data conversion for tab or space separated text files.
Arguments are of the form <key>
of <src>:<dst>
where the column <key>
is extracted as is and <src>
is extracted and renamed to <dst>
.
Only support for the most simple use cases is implemented.
Its main purpose is fast dataconversion of large files
between different bioinformatics tools.
$ cc -O3 dconv.c -o dconv
$ ./dconv.c x y << EOF
x y z
0 1 2
3 4 5
6 7 8
EOF
x y
0 1
3 4
6 7
$ ./dconv.c src:dst << EOF
src
1
EOF
dst
1
Fast navigation to definitions in Emacs when pressing Ctrl-L.