npm init -y
npm install blocksmd fs-extra live-server
create a directory named src
and add a file named index.md
with the following contents:
<script> | |
import { onMount } from "svelte"; | |
import { writable } from "svelte/store"; | |
const messages = writable([]); | |
let width = 1000; | |
let height = 200; | |
let gap = width / 100; |
<script> | |
import { onMount } from "svelte"; | |
import { writable } from "svelte/store"; | |
const theme = writable("light"); | |
onMount(() => { | |
const storedTheme = localStorage.getItem("theme"); | |
if (storedTheme) theme.set(storedTheme); |
#!/usr/bin/env bash | |
# show pid and port from matcher | |
MATCHER=$1 | |
if [ -n "$MATCHER" ]; then | |
sudo lsof -aPn -i4 -cnode -u${USER} -sTCP:LISTEN | grep $MATCHER | awk '{print $2 "|" $9}'; | |
exit 0; | |
fi; | |
# show all ssh tunnel tcp connections |