Skip to content

Instantly share code, notes, and snippets.

@evanslify
evanslify / bash_prompt.sh
Created October 19, 2016 07:26 — forked from blaze33/bash_prompt.sh
Set color bash prompt according to active virtualenv, git branch, mercurial branch and return status of last command. I won't maintain this fork anymore as I reused this script here: https://github.com/blaze33/effings
#!/bin/bash
#
# DESCRIPTION:
#
# Set the bash prompt according to:
# * the active virtualenv
# * the branch/status of the current git repository
# * the branch/status of the current mercurial repository
# * the return value of the previous command
#
#!/bin/bash
#
# DESCRIPTION:
#
# Set the bash prompt according to:
# * the active virtualenv
# * the branch/status of the current git repository
# * the return value of the previous command
# * the fact you just came from Windows and are used to having newlines in
# your prompts.
@evanslify
evanslify / kktix-clicker.js
Created July 9, 2016 04:43
This scripts helps you buy tickets on KKTIX by bypassing the alert box, and saves your mouse button / keyboard from overusing.
window.alert = function() {
console.log('alert');
};
var btn = $('#registrationsNewApp > div > div:nth-child(5) > div.form-actions.plain.align-center > button');
setInterval(function () {btn.click();}, 1000);
/*
* author: es <[email protected]>
* description:
* This script helps you battle with Allpay's CheckMacValue.
*/
const crypto = require('crypto');
String.prototype.allpayURLencode = function() {
var replace_map = {
' ': '+',
@evanslify
evanslify / convert.py
Created May 7, 2016 10:06
Snippet conversion from UltiSnips to Atom.
#!/usr/bin/env python
# encoding: utf-8
import re
import sys
def split_snippets(raw_string):
"""Split UltiSnip snippets to lists.