Skip to content

Instantly share code, notes, and snippets.

View 16patsle's full-sized avatar
⌨️
Testing out something new

Patrick Sletvold 16patsle

⌨️
Testing out something new
View GitHub Profile
@16patsle
16patsle / CHRISTMAS TREE.js
Last active December 6, 2018 14:12
Do you wanna build a Christmas tree? CHRISTMAS TREE.js
/**
* Generates a Christmas tree
* @param {number} [segments=10] - The number of tree segments, "levels", to generate. The height of the bottom of the tree is calculated based on this.
* @param {Boolean} [perfectNotRandom=false] - When decorating the tree, should it be decorated in a perfect diagonal line pattern?
* @returns {String} The tree represented as a string.
*/
function generateTree(segments = 10, perfectNotRandom = false) {
let size = segments * 2 - 1 + 2 + 1
let tree = ''
@16patsle
16patsle / Caddyfile
Last active July 26, 2018 11:39 — forked from abiosoft/Caddyfile
Caddy wordpress docker-compose
:80
root /usr/src/wordpress
gzip
fastcgi / wordpress:9000 php
rewrite {
if {path} not_match ^\/wp-admin
to {path} {path}/ /index.php?_url={uri}
}
log stdout
errors stderr
@16patsle
16patsle / keybase.md
Created October 29, 2017 10:09
keybase.md

Keybase proof

I hereby claim:

  • I am 16patsle on github.
  • I am 16patsle (https://keybase.io/16patsle) on keybase.
  • I have a public key ASAVOwTrzyQaIhNJIjprNAvFh9XRibaL5tmevRU2t2JIcQo

To claim this, I am signing this object: