Skip to content

Instantly share code, notes, and snippets.

View smutch's full-sized avatar

Simon Mutch smutch

View GitHub Profile
@disnet
disnet / gist:4489250
Last active August 13, 2019 15:04
osx - force skim to always autoupdate
defaults write -app Skim SKAutoReloadFileUpdate -boolean true
@zenware
zenware / insta-vim-bookmark.js
Last active December 15, 2015 08:29
Instant Vim-Style Editor in any Browser.
data:text/html,
<html style="background:#002b36;font:13px monospace;padding:30px;">
<head>
<link rel="stylesheet" href="http://codemirror.net/lib/codemirror.css">
<style>.CodeMirror{height:100%}.CodeMirror.cm-keymap-fat-cursor div.CodeMirror-cursor{background:#93a1a1}.CodeMirror-linenumber{color:#b58900}.CodeMirror-gutters{background:#073642;border-color:#073642}</style>
<script src="http://codemirror.net/lib/codemirror.js"></script>
<script src="http://codemirror.net/keymap/vim.js"></script>
<body style="background:#073642;color:#93a1a1;max-width:600px;padding:10px 0;">
<textarea id="code"></textarea>
<script>
@brandonb927
brandonb927 / LICENSE.md
Last active October 11, 2020 09:13 — forked from valpackett/LICENSE.md
Use Markdown in Evernote with Marked.app
       DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
               Version 2, December 2004

Copyright (C) 2012 Brandon B. [email protected]

Everyone is permitted to copy and distribute verbatim or modified copies of this license document, and changing it is allowed as long as the name is changed.

DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE

@MSylvia
MSylvia / convert_itermcolors.py
Created June 14, 2014 14:29
Convert .itermcolors file to html hex
#!/usr/bin/env python
#
# Convert .itermcolors files to hex colors for html
import sys
import xml.etree.ElementTree as ET
def rgb_to_hex(rgb):
return '#%02x%02x%02x' % rgb
@ctechols
ctechols / Page.vim
Last active May 15, 2018 10:48
Capture output from a vim command (like :version or :messages) into a split scratch buffer.
"Examples:
":Page version
":Page messages
":Page ls
"It also works with the :!cmd command and Ex special characters like % (cmdline-special)
":Page !wc %
"Capture and return the long output of a verbose command.
function! s:Redir(cmd)
let output = ""
redir =>> output
@eteq
eteq / local_build.py
Last active July 3, 2018 14:49
Authorea script to build locally with LaTeX NOTE: updates at https://github.com/eteq/authorea-scripts
#!/usr/bin/env python
from __future__ import division, print_function
"""
This script generates a file to use for building authorea papers, and then runs
latex on them.
Requires python >= 2.6 (3.x should work, too)
The key assumptions are:
@shrayasr
shrayasr / pair-program-tmux.md
Last active March 29, 2022 13:58
Pair programming with Tmux

Pair programming with Tmux

Using the same user

User 1

  1. SSH into the box

     user1@user1-machine$ ssh user@host
    
@lazywei
lazywei / install_mosh_locally.sh
Created January 25, 2015 05:30 — forked from xiaom/install_mosh_locally.sh
Install mosh server without root permission
#!/bin/sh
# this script does absolutely ZERO error checking. however, it worked
# for me on a RHEL 6.3 machine on 2012-08-08. clearly, the version numbers
# and/or URLs should be made variables. cheers, [email protected]
mkdir mosh
cd mosh
@cszentkiralyi
cszentkiralyi / context_quick_scope.vim
Last active April 16, 2016 07:15
Only enable the quick-scope plugin's highlighting when using the f/F/t/T movements
" Insert into your .vimrc after quick-scope is loaded.
" Obviously depends on <https://github.com/unblevable/quick-scope> being installed.
" Thanks to @VanLaser for cleaning the code up and expanding capabilities to include e.g. `df`
let g:qs_enable = 0
let g:qs_enable_char_list = [ 'f', 'F', 't', 'T' ]
function! Quick_scope_selective(movement)
let needs_disabling = 0