Skip to content

Instantly share code, notes, and snippets.

@wk8
wk8 / sy.sh
Created March 19, 2020 17:23
sy
#!/bin/bash
## Wrapper around rsync or unison
## Assumes the target has the relevant bits installed
POST_SYNC_SCRIPT_NAME='.sy/post.sh'
POST_SYNC_WIN_SCRIPT_NAME='.sy/post.ps1'
POST_SYNC_LINUX_SCRIPT_NAME='.sy/post.sh'
SYNC_CONFIG_NAME='.sy/config.json'

Keybase proof

I hereby claim:

  • I am wk8 on github.
  • I am wk8 (https://keybase.io/wk8) on keybase.
  • I have a public key whose fingerprint is 4E26 28D8 4F64 6857 B284 ED02 3B00 6F4A E174 FF0B

To claim this, I am signing this object:

@wk8
wk8 / readline.patch
Last active August 29, 2015 14:00
Minimal patch to get ruby 2.1.1 to compile with readline 6.3.x (?) on Mac OS X. Usage: curl -L https://gist.github.com/wk8/fef2479af6b16a9cac71/raw | ruby-build 2.1.1 --patch or curl -L https://gist.github.com/wk8/fef2479af6b16a9cac71/raw | rbenv install --patch 2.1.1, depending on what you're using.
--- ext/readline/readline.c
+++ ext/readline/readline.c
@@ -1974,7 +1974,7 @@ Init_readline()
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
#ifdef HAVE_RL_CATCH_SIGNALS