Skip to content

Instantly share code, notes, and snippets.


Henrik Lissner hlissner

View GitHub Profile
hlissner / repeat-match.vim
Created Sep 6, 2014
Using . to repeat last f/F/t/T match in vim
View repeat-match.vim
" I remap the leader/localleader, and ; to alias :, but what if I like , and ;?
let mapleader = ','
noremap ; :
" Makes f, F, t and T repeat the search. Support repeating with .
nnoremap <Plug>NextMatch ;
nnoremap <silent> f :<C-u>call repeat#set("\<lt>Plug>NextMatch")<CR>f
nnoremap <silent> F :<C-u>call repeat#set("\<lt>Plug>NextMatch")<CR>F
nnoremap <silent> t :<C-u>call repeat#set("\<lt>Plug>NextMatch")<CR>t
nnoremap <silent> T :<C-u>call repeat#set("\<lt>Plug>NextMatch")<CR>T
hlissner /
Created Dec 23, 2015
Steps to set up a linode-based dyndns
# This is not a script! These are notes!
# Getting the domain ID$KEY&api_action=domain.list
# Getting the resource ID

Keybase proof

I hereby claim:

  • I am hlissner on github.
  • I am hlissner ( on keybase.
  • I have a public key whose fingerprint is 0ABF F606 54D7 AEAF C9CC 27CE 5F6C 0EA1 6055 7395

To claim this, I am signing this object:

hlissner / evil-ex-replace-special-filenames.el
Last active May 8, 2017
A simple hack to add several substitutions to evil-mode's :ex mode, other than % and #...
View evil-ex-replace-special-filenames.el
;; A hack to add vim file modifiers to evil-mode's ex commandline:
;; Requires projectile ( for
;; project-awareness, and f.el ( for file
;; functions.
(defun +evil*ex-replace-special-filenames (file-name)
"Replace special symbols in FILE-NAME. Modified to include other substitution
flags. See"
(let* (case-fold-search
(regexp (concat "\\(?:^\\|[^\\\\]\\)"
hlissner / hs-special-modes-alist.el
Created Jun 21, 2018
Adds hideshow folding rules for yaml-mode and ruby-mode
View hs-special-modes-alist.el
(defun +data-hideshow-forward-sexp (arg)
(let ((start (current-indentation)))
(unless (= start (current-indentation))
(require 'evil-indent-plus)
(let ((range (evil-indent-plus--same-indent-range)))
(goto-char (cadr range))
(map-put hs-special-modes-alist
hlissner / ace-jump-two-char.el
Last active Sep 20, 2018
Make ace-jump do a two-char search (like vim-sneak)
View ace-jump-two-char.el
;; Thanks to:
(defun ace-jump-two-chars-mode (&optional query-char query-char-2)
"AceJump two chars mode"
(setq query-char (or query-char (read-char ">")))
(setq query-char-2 (or query-char-2 (read-char (concat ">" (string query-char)))))
(if (eq (ace-jump-char-category query-char) 'other)
hlissner / lb6.js
Last active Mar 14, 2019
LaunchBar 6 API stubs (for ternjs)
View lb6.js
* LaunchBar Javascript API (see
* For use with auto-completion libraries.
// Included to hide "unused function" warnings
hlissner /
Created Apr 4, 2019
Some literature on touch-bending in Unity or HLSL
hlissner /
Last active Apr 18, 2019
Iptables default rules
#### IPS ######
# Get server public ip
SERVER_IP=$(ifconfig eth0 | grep 'inet addr:' | awk -F'inet addr:' '{ print $2}' | awk '{ print $1}')
#### FILES #####
hlissner /
Last active May 16, 2019
Install pacaur on Arch Linux
if ! command -v pacaur >/dev/null; then
tmp=$(mktemp -d)
function finish {
rm -rf "$tmp"
trap finish EXIT
pushd $tmp
for pkg in cower pacaur; do
curl -o PKGBUILD$pkg && \
You can’t perform that action at this time.