Skip to content

Instantly share code, notes, and snippets.

@maljub01
maljub01 / keybase.md
Created September 21, 2019 20:49
Keybase proof

Keybase proof

I hereby claim:

  • I am maljub01 on github.
  • I am maljub01 (https://keybase.io/maljub01) on keybase.
  • I have a public key ASBJvFWJ-crQWsLXQC0Ois76hyzqx6lcMdP4tlZYefijUwo

To claim this, I am signing this object:

@maljub01
maljub01 / ruby-2.0.0-p247.patch
Created December 22, 2014 12:33
Patch for building ruby 2.0.0-p247 on Ubuntu 14.04 (using rbenv & ruby-build)
diff -ur orig/ext/readline/readline.c fixed/ext/readline/readline.c
--- orig/ext/readline/readline.c 2014-03-18 13:53:31.866359527 +0100
+++ fixed/ext/readline/readline.c 2014-03-18 13:56:26.390247250 +0100
@@ -1883,7 +1883,7 @@
rl_attempted_completion_function = readline_attempted_completion_function;
#if defined(HAVE_RL_PRE_INPUT_HOOK)
- rl_pre_input_hook = (Function *)readline_pre_input_hook;
+ rl_pre_input_hook = (rl_hook_func_t *)readline_pre_input_hook;
#endif
@maljub01
maljub01 / v
Last active December 14, 2015 18:29
A shell function that allows reusing the same screen/tmux window for editing/viewing files with vim, inspired by the following question on superuser.com: http://superuser.com/questions/563448/screen-grouping-all-vim-invokation-under-one-window/563784
v () {
if [ $STY ]; then
# screen
local VIM_SERVER_NAME="VIM-SCREEN-$STY"
if [ "`vim --serverlist | grep -i $VIM_SERVER_NAME`" = "" ]; then
# No vim server, become the server
screen -X title vim
vim --servername $VIM_SERVER_NAME "$@"
screen -X title `basename $SHELL`