View bitbucket.js
// remove all released branches (ahead = 0)
'git push origin :' + jQuery('#branch-list tbody tr')
.find('.last-updated-column')
.filter(function() {
return parseInt(this.textContent.match(/[\d]{4}/)) <= 2016;
})
.closest('tr')
.find('.ahead-graph.empty-count')
.closest('tr')
.find('.branch-name-column .line a')
View github-emoji.md

GitHub Emoji

This is a complete list of GitHub Emojis that you can use in your markdown file or html page.

length: 1451

Image Emoji HTML Entity
grinning 😀 :grinning: 😀 &#x1f600;
View primes.js
/**
* Get prime numbers from 1 to n
*
* from 1 to 1000000 there are 78498 prime numbers fetched in ~100ms
*/
function getPrimesLessThan( n ) {
var primeNumbers = [2];
var isPrime;
View copy-to-clipboard.js
function copyToClipboard( text ) {
var textarea = document.createElement('textarea');
textarea.innerText=text;
document.getElementsByTagName('body')[0].append(textarea);
textarea.select();
try {
var successful = document.execCommand('copy');
console.log('copied ' + (successful ? 'successfully' : 'unsuccessfully'));
View beep.js
var beep = function() {
var snd = new Audio("data:audio/wav;base64,//uQRAAAAWMSLwUIYAAsYkXgoQwAEaYLWfkWgAI0wWs/ItAAAGDgYtAgAyN+QWaAAihwMWm4G8QQRDiMcCBcH3Cc+CDv/7xA4Tvh9Rz/y8QADBwMWgQAZG/ILNAARQ4GLTcDeIIIhxGOBAuD7hOfBB3/94gcJ3w+o5/5eIAIAAAVwWgQAVQ2ORaIQwEMAJiDg95G4nQL7mQVWI6GwRcfsZAcsKkJvxgxEjzFUgfHoSQ9Qq7KNwqHwuB13MA4a1q/DmBrHgPcmjiGoh//EwC5nGPEmS4RcfkVKOhJf+WOgoxJclFz3kgn//dBA+ya1GhurNn8zb//9NNutNuhz31f////9vt///z+IdAEAAAK4LQIAKobHItEIYCGAExBwe8jcToF9zIKrEdDYIuP2MgOWFSE34wYiR5iqQPj0JIeoVdlG4VD4XA67mAcNa1fhzA1jwHuTRxDUQ//iYBczjHiTJcIuPyKlHQkv/LHQUYkuSi57yQT//uggfZNajQ3Vmz+Zt//+mm3Wm3Q576v////+32///5/EOgAAADVghQAAAAA//uQZAUAB1WI0PZugAAAAAoQwAAAEk3nRd2qAAAAACiDgAAAAAAABCqEEQRLCgwpBGMlJkIz8jKhGvj4k6jzRnqasNKIeoh5gI7BJaC1A1AoNBjJgbyApVS4IDlZgDU5WUAxEKDNmmALHzZp0Fkz1FMTmGFl1FMEyodIavcCAUHDWrKAIA4aa2oCgILEBupZgHvAhEBcZ6joQBxS76AgccrFlczBvKLC0QI2cBoCFvfTDAo7eoOQInqDPBtvrDEZBNYN5xwNwxQRfw8ZQ5wQVLvO8OYU+mHvFLlDh05Mdg7BT6YrRPpCBznMB2r//xKJjyyOh+cImr2/4doscwD6neZjuZR4AgAABYAAAABy1xcdQtxYBYYZdifkUDgzzXaXn98Z0oi9ILU5m
View mysqldump.sh
# usage: ./dump.sh
HOST=127.0.0.1
USER=root
DATABASE=database
OUTPUT=dump.sql.zip
EXCLUDED_TABLES=(
table1
table2
tableN
View .bash_completion_ssh.sh
# MIT License
#
# Copyright (c) 2016 Marco Montalbano
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
View webserver.js
/**
* name: Web Server for Node.js
* author: Marco Montalbano
* references: Node for Front-End Developers - Garann Means
*
* how to use
* ----------
* - install node.js (https://nodejs.org)
* - # node webserver.js
*