Skip to content

Instantly share code, notes, and snippets.

@frekele
frekele / Jenkinsfile
Created August 4, 2016 06:18
Jenkinsfile pipelineTriggers - TimerTrigger periodic run the aws-update-my-dynamic-ip.sh script.
#!groovy
MAIL_FROM = 'noreply-jenkins@myhost.io'
MAIL_TO = 'jenkins@myhost.io'
GITHUB_PROTOCOL = 'https'
GITHUB_USER_NAME = 'my-github-user'
GITHUB_USER_EMAIL = 'jenkins@myhost.io'
GITHUB_REPO = 'github.com/my-user/my-repository'
GITHUB_PROJECT_URL = "${GITHUB_PROTOCOL}://${GITHUB_REPO}"
@tjmehta
tjmehta / dataview-polyfill.js
Created April 5, 2016 00:05
DataView (and ArrayBuffer) polyfill that works in any engine (including old IE).
void function(global){
if ('DataView' in global && 'ArrayBuffer' in global) {
return;
}
var hide = (function(){
// check if we're in ES5
if (typeof Object.getOwnPropertyNames === 'function' && !('prototype' in Object.getOwnPropertyNames)) {
var hidden = { enumerable: false };
anonymous
anonymous / O2minipop.ino
Created March 17, 2016 21:24
// O2 Minipops rhythm box (c) DSP Synthesizers 2016
// Free for non commercial use
// http://janostman.wordpress.com
#include <avr/interrupt.h>
#include <avr/io.h>
#include <avr/pgmspace.h>
@zchee
zchee / actionlist.vim
Last active April 19, 2024 13:22
IdeaVim actionlist
--- Actions ---
$Copy <M-C>
$Cut <M-X> <S-Del>
$Delete <Del> <BS> <M-BS>
$LRU
$Paste <M-V>
$Redo <M-S-Z> <A-S-BS>
$SearchWeb <A-S-G>
$SelectAll <M-A>
$Undo <M-Z>
@WebReflection
WebReflection / Object.extra.js
Created August 16, 2012 20:42
Object.getPropertyDescriptor and Object.getPropertyNames
!function(Object, getPropertyDescriptor, getPropertyNames){
// (C) WebReflection - Mit Style License
if (!(getPropertyDescriptor in Object)) {
var getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;
Object[getPropertyDescriptor] = function getPropertyDescriptor(o, name) {
var proto = o, descriptor;
while (proto && !(
descriptor = getOwnPropertyDescriptor(proto, name))
) proto = proto.__proto__;
return descriptor;
@MohamedAlaa
MohamedAlaa / tmux-cheatsheet.markdown
Last active May 8, 2024 07:49
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@borismus
borismus / gist:1032746
Created June 18, 2011 02:46
Convert a base64 string into a binary Uint8 Array
var BASE64_MARKER = ';base64,';
function convertDataURIToBinary(dataURI) {
var base64Index = dataURI.indexOf(BASE64_MARKER) + BASE64_MARKER.length;
var base64 = dataURI.substring(base64Index);
var raw = window.atob(base64);
var rawLength = raw.length;
var array = new Uint8Array(new ArrayBuffer(rawLength));
for(i = 0; i < rawLength; i++) {