Skip to content

Instantly share code, notes, and snippets.

@dswwsd
dswwsd / generate-dropbear-key.sh
Last active August 9, 2022 03:44 — forked from hongkongkiwi/generate-dropbear-key
Generate SSH Key in Dropbear
#!/bin/bash
KEY_DIR="~/.ssh"
# Make directories
mkdir -p "$KEY_DIR"
# Generate an RSA key using dropbear
dropbearkey -t rsa -f "${KEY_DIR}/id_rsa"
@dswwsd
dswwsd / distance.js
Last active December 14, 2017 06:23 — forked from clauswitt/distance.js
Get the distance between two (world) coordinates - a nodejs module
/* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
/* */
/* Simple node js module to get distance between two coordinates. */
/* */
/* Code transformed from Chris Veness example code - please refer to his website for licensing */
/* questions. */
/* */
/* */
/* Latitude/longitude spherical geodesy formulae & scripts (c) Chris Veness 2002-2011 */
/* - www.movable-type.co.uk/scripts/latlong.html */