Skip to content

Instantly share code, notes, and snippets.

Peter Vermeulen peterver

Block or report user

Report or block peterver

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@peterver
peterver / example.test.js
Created Jul 29, 2018
Karma Setup with Chrome Headless + Jasmine + Webpack
View example.test.js
import { guid } from '../../src/hash';
describe("Hash - Guid", () => {
it ('should output a string value', () => {
let g = guid();
expect(g).toEqual(jasmine.any(String));
});
});
// Based on the tests for @valkyriestudios/utils (github.com/valkyriestudios/utils)
View valkyrie_rsa.pub
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDPfXhxTLH/A0oJUx8aczDZUVwrfyiUFNNTnc5GujAMCdzlDfpcJBwbRKSQtA6hkH/qMbZCWedwliKRat9Oy7Aonun43i4qgEADOpOIwHrUVY59myZDOtf5C5pjhRK706Giwzl1xZcDv48ru4usM1JdGF0yZVx2QMz8+otJ4FL1RKDxoWblIzMasAdfIEi/43Xo4eMEzHyTlFPiVoth+P7heuHAz2dzIK+F3x1duQ2NhNjpCZoaNM7rhWRZ+ExArEHZj4Fkar2ePBUr/8DzyUmUk13YglMbIZBzG6/SC1C600mxmx0fs/8kPH89kMXw2ONdvlnUOrV5tNnnBTvgjOoun2zoBFohWXUrTKHZt3OM3OdOjF+TXRUkKQz0p2quox8To5aPqaryc7qi1tGYnLgiCMJbtZ1zbrkMHTIo6hApqNkAEQzKm4NoVTpvlxlhq1vcU0Pg0Wa0gK7D42ljA6OhrAdMKG1y4cBUwPkgjDdyMswaxF1J5+5lmT0E8aAtAwxU7p2Qjq7BMZJheIX8QT6Nax2heiQYXJtsv1eaTXwDTPQYw3GKmo8ijHTBAnNHs6k+29RD6WOedhFHeX+yZSBbxWl+QI69zG7mmnmE1ud4EQXkSjpjHLgqkVh3VYtX0JalhbDJApF0EE1zM6nrKeADxsow6qt6TrKBncSPGOPIOQ== contact@valkyriestudios.be
View keybase.md

Keybase proof

I hereby claim:

To claim this, I am signing this object:

@peterver
peterver / exitstatus.sh
Last active Nov 12, 2017
Supress all output but still retrieve the exit code of a command
View exitstatus.sh
#!/bin/bash
rep=$(...INSERT_COMMAND_HERE... 2>&1 >/dev/null)
status=$?
echo "$status"
@peterver
peterver / isdockerlive.sh
Created Nov 11, 2017
A shell script that uses curl to see if docker is up and running
View isdockerlive.sh
#!/bin/bash
rep=$(curl -s --unix-socket /var/run/docker.sock http://ping > /dev/null)
status=$?
if [ "$status" == "7" ]; then
echo 'not connected'
exit 1
fi
@peterver
peterver / tslint.json
Last active Nov 17, 2016
Standard TSLint Configuration
View tslint.json
{
"rulesDirectory": "node_modules/tslint-eslint-rules/dist/rules",
"rules" : {
"align" : ["parameters", "arguments", "statements"],
"array-bracket-spacing" : [true, "never"],
"arrow-parens" : true,
"brace-style" : true,
"comment-format": [true, "check-space", "check-uppercase"],
"curly" : true,
"cyclomatic-complexity": [true, 15],
@peterver
peterver / .vimrc
Created Sep 27, 2016
Standard .vimrc
View .vimrc
set nocompatible
""""""""""""""""""""""""""""""""""""""""
" VUNDLE
""""""""""""""""""""""""""""""""""""""""
filetype off
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
@peterver
peterver / config
Created Sep 19, 2016
Default MOCP setup
View config
ReadTags = yes
Sort = FileName
ShowStreamErrors = no
MP3IgnoreCRCErrors = yes
Repeat = no
Shuffle = no
AutoNext = yes
@peterver
peterver / Detector.js
Created Sep 16, 2016
Detector of browser functions
View Detector.js
// Detect canvas support
const DETECTOR = Object.freeze({
CANVAS : (function () {
if (window.CanvasRenderingContext2D) {
return 'canvas';
}
return false;
})(),
CLASSLIST : (function () {
return ('classList' in document.createElement('a'));
@peterver
peterver / .editorconfig
Last active Dec 4, 2016
Standard editor config
View .editorconfig
root = true
[*.scss]
indent_style = space
indent_size = 4
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
[*.json]
You can’t perform that action at this time.