Skip to content

Instantly share code, notes, and snippets.

View therealmarv's full-sized avatar
:octocat:

therealmarv

:octocat:
View GitHub Profile
@therealmarv
therealmarv / instructions.md
Created March 19, 2019 18:57
Install easybake on macOS

How to install easybake with pip

  1. Install icu4c
brew install icu4c
  1. Install easybake

For Bash shell:

@therealmarv
therealmarv / output.html
Created March 18, 2019 17:18
output.xhtml
<body
data-cnxml-to-html-ver='v0.test'
xmlns='http://www.w3.org/1999/xhtml'
xmlns:bib='http://bibtexml.sf.net/'
xmlns:c='http://cnx.rice.edu/cnxml'
xmlns:data='http://www.w3.org/TR/html5/dom.html#custom-data-attribute'
xmlns:md='http://cnx.rice.edu/mdml'
xmlns:mod='http://cnx.rice.edu/#moduleIds'
xmlns:qml='http://cnx.rice.edu/qml/1.0'
>
@therealmarv
therealmarv / input.xml
Created March 18, 2019 17:16
input.cnxml
<?xml version="1.0"?>
<document xmlns="http://cnx.rice.edu/cnxml" xmlns:md="http://cnx.rice.edu/mdml" xmlns:bib="http://bibtexml.sf.net/" xmlns:m="http://www.w3.org/1998/Math/MathML" xmlns:q="http://cnx.rice.edu/qml/1.0" xmlns:data="http://www.w3.org/TR/html5/dom.html#custom-data-attribute" id="new" cnxml-version="0.7" module-id="new">
<title>Long Desc test</title>
<content>
<section id="eip-220"><media id="eip-idm1388625936" alt="An image comparing the functions of the parasympathetic nervous system to the central nervous system." longdesc="35-4-2-longdesc.txt">
<image mime-type="image/jpeg" src="Figure_35_04_02.jpg"/>
</media>
@therealmarv
therealmarv / init.lua
Created November 21, 2017 14:28
hammerspoon Umlaute
-- Umlaute
hs.hotkey.bind({'alt'}, 'u', function ()
hs.eventtap.keyStrokes('ü')
end)
hs.hotkey.bind({'shift', 'alt'}, 'u', function ()
hs.eventtap.keyStrokes('Ü')
end)
@therealmarv
therealmarv / travis submodule handling
Created November 19, 2016 19:12
travis submodule handling
git:
submodules: false
before_install:
- git submodule update --init --recursive
@therealmarv
therealmarv / fl
Last active March 29, 2024 22:26 — forked from McNull/fl
Open current directory in forklift
#!/bin/bash
# Open current directory in forklift 4
# Adapted from https://gist.github.com/elentok/6218781
# Adapted from comment https://gist.github.com/elentok/6218781#comment-891115
# Added optional path argument and removed using the clipboard buffer.
set -e
if [ -z "$@" ]; then
@therealmarv
therealmarv / pybossa-rewrite-apache.md
Last active August 29, 2015 14:24
PyBossa Rewrite Apache

Original nginx rewrite lines, just for reference!

location ~ /api/app {
        rewrite ^/api/app /api/project$1 permanent;
}

location ~ /app {
        rewrite ^/app(.*) /project$1 permanent;
}
@therealmarv
therealmarv / remove_jpg_if_raw_exists.py
Created April 2, 2015 06:01
Remove jpg when raw existing
#!/usr/bin/env python
# Script: remove_jpg_if_raw_exists.py
#
# Description: This script looks in all sub directories for
# pairs of JPG and RAW files.
# For each pair found the JPG is moved to a
# waste basket directory.
# Otherwise JPG is kept.
#
# Author: Thomas Dahlmann
  UPDATE `NEXUS 5`
     SET `VERSION`='5.1', `BUILD`='LMY47D', `RECOVERY`='CUSTOM', `ROOTED`=1
   WHERE `VERSION`='5.0.1' && `BUILD`='LRX22C' && `RECOVERY`='CUSTOM' && `ROOTED`=1
         && `WANNA_KEEP_USERDATA`=1;

This guide is forked and updated for Android 5.1 OTA from me. Big thanks to the original author eyecatchup and his guide from LRX21O to LRX22C here.

This guide also works without any problems for encrypted phones because data partition is not touched.

@therealmarv
therealmarv / pgbouncer
Created March 5, 2015 15:05
/etc/init.d/pgbouncer for Ubuntu 12.04
#!/bin/bash
### BEGIN INIT INFO
# Provides: pgbouncer
# Required-Start: $syslog $remote_fs
# Required-Stop: $syslog $remote_fs
# Should-Start: postgresql
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: start pgbouncer