npm install caller errio eventemitter3
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const {inspect} = require('util') | |
const DEFAULT = { | |
defaultValue: undefined, | |
dictionary: undefined, | |
value: undefined | |
} | |
function EnumFlag (enumFlag) { | |
const index = getDictionaryIndex(enumFlag.dictionary) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const {sep: platformSep} = require('path') | |
const {inspect} = require('util') | |
const POSIX_SEP = '/' | |
const WIN32_SEP = '\\' | |
const PATH_SEPARATORS = { | |
'aix': POSIX_SEP, | |
'darwin': POSIX_SEP, | |
'freebsd': POSIX_SEP, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function nextify (middlewares, callback) { | |
return (...args) => { | |
middlewares.slice(0).reverse().reduce((next, fn) => { | |
return () => fn(...args, (err) => { | |
if (err) { | |
return callback(err) | |
} | |
next() | |
}) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module.exports = [] | |
.concat([ | |
'reset', | |
'bold', | |
'dim', | |
'italic', | |
'underline', | |
'blink', | |
, | |
'inverse', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const nodeNotifier = require('node-notifier') | |
const { | |
format, | |
inspect | |
} = require('util') | |
const CONSOLE = Object.assign({}, console) | |
const DEFAULT = { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var wcf = require('wcf') | |
var {basename, resolve} = require('path') | |
// mocks > | |
var globSync = () => [] | |
var happyPackPlugin = (x) => x | |
// < mocks | |
var f = wcf.create() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for i in $(git status | grep modified | awk -F " " '{print $2}'); | |
do cat $i | tr -d '\r' > $i.tmp; mv $i.tmp $i; | |
done |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
REPO=git remote -v | grep -e push | awk '{print $2}' | sed 's/https:\/\/github.com\///g' | sed 's/.git//g' | |
REPOUSER=$(echo $REPO | awk -F '/' '{print $1}') | |
REPONAME=$(echo $REPO | awk -F '/' '{print $2}') | |
echo "https://$REPOUSER.github.io/$REPONAME" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# contributors: Generate MAINTAINERS content from git commits | |
# | |
# Author: Steven Enten <[email protected]> | |
# License : MIT | |
# Requirements: dirname cat echo eval grep read readlink shift tail | |
# Site: https//github.com/enten/losh | |
set -u |