A very basic regex-based Markdown parser. Supports the
following elements (and can be extended via Slimdown::add_rule()
):
- Headers
- Links
- Bold
- Emphasis
- Deletions
#!/usr/bin/gawk -f | |
#FUNCTIONS | |
function printRecords(array) { | |
if( array[0] != "" ) { | |
asort(array); | |
for( j = length(array); j >= 1 ; j-- ) { | |
lastChar = ""; | |
if (j > 1) { | |
lastChar = ","; | |
} |
#!/usr/bin/env bash | |
function sql() { | |
local sql=$1 | |
sqlite3 photo.db "$sql" | |
} | |
function go_to_current_directory() { | |
cd "$(dirname "$0")" | |
} |
describe('transformToLessOperations', function() { | |
eval('var transformToLessOperations = require("..").transformToLessOperations'); | |
var cm = require("color-model"); | |
var cm = require("../../nodejs-color-model"); | |
eval('var AbstractModel = cm.AbstractModel'); | |
eval('var HexRgb = cm.HexRgb'); | |
eval('var Hsl = cm.Hsl'); | |
eval('var Rgb = cm.Rgb'); | |
describe('extreme cases', function() { |
describe('transformToLessOperations', function() { | |
eval('var transformToLessOperations = require("..").transformToLessOperations'); | |
var cm = require("color-model"); | |
var cm = require("../../nodejs-color-model"); | |
eval('var AbstractModel = cm.AbstractModel'); | |
eval('var HexRgb = cm.HexRgb'); | |
eval('var Hsl = cm.Hsl'); | |
eval('var Rgb = cm.Rgb'); | |
/* |
#!/bin/bash | |
function log { | |
echo | |
echo "-- $1 --" | |
} | |
function run { | |
echo "# $1" | |
sh -c "$1" |
#!/usr/bin/env bash | |
touch /tmp/powned |
var bodyHtml = document.body.innerHTML; | |
function a() { | |
var date = Date.now(); | |
document.body.innerHTML = Math.random().toString() + 'test'; | |
console.log('render ' + (Date.now() - date) + 'ms'); | |
setTimeout(a, 0); | |
} | |
function b() { | |
var date = Date.now(); | |
document.body.innerHTML = bodyHtml; |
package orthodox; | |
public class Polyshit { | |
public static void main(String[] args) { | |
Polyshit me = new Polyshit(); | |
Number integerAsNumber = new Integer(1); | |
Integer integer = new Integer(1); |
#!/usr/bin/env bash | |
START_COMMIT=${1:-develop} | |
END_COMMIT=${2:-HEAD} | |
range=$START_COMMIT..$END_COMMIT | |
echo 'Commits count: ' $(git log --oneline $range | wc -l) | |
GIT_PAGER=cat git log --reverse --no-merges --format='format:[%h] %s' --name-status $range |