Skip to content

Instantly share code, notes, and snippets.


Nathaniel nathanielks

View GitHub Profile
frank-dspeed / get-es-path.mjs
Created Jan 23, 2020
Method to get Current File Path inside ESM
View get-es-path.mjs
function getPath(url) {
let result = new URL(import.meta.url)
let pathname = result.pathname
let pathArray = pathname.split('/')
let basename = pathArray.pop()
let dirname = pathArray.join('/')
return { pathname, dirname,basename}
webframp /
Created Jul 25, 2017
Signing git commits on github using gpg key

Probably one of the easiest things you'll ever do with gpg

Install Keybase: and Ensure the keybase cli is in your PATH

First get the public key

keybase pgp export | gpg --import

Next get the private key

euank / Dockerfile
Last active Aug 30, 2017
ECS / EC2 Metadata entrypoint example
View Dockerfile
FROM golang:1.4
COPY main.go main.go
RUN go build -o main main.go
RUN chmod +x /
CMD ["./main"]
acdvorak /
Last active Aug 6, 2021 — forked from yubink/
tmux: run a command in all panes
# Runs the specified command (provided by the first argument) in all tmux panes
# in every window. If an application is currently running in a given pane
# (e.g., vim), it is suspended and then resumed so the command can be run.
all-panes-bg_ "$1" &
Rarst / r-debug.php
Last active Nov 7, 2022
R Debug (set of dump helpers for debug)
View r-debug.php
Plugin Name: R Debug
Description: Set of dump helpers for debug.
Author: Andrey "Rarst" Savchenko
Author URI:
License: MIT