This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# $ ./make-it-root.sh with params <<<"and stdin" | |
set -e | |
# if not run as root, prompt user to allow this to run as root | |
# NOTE: Must use `whoami`, $USER won't be set when run this way, which will cause this to trigger recursively | |
if [[ "$(whoami)" != 'root' ]]; then | |
exec osascript - "$0" "$@" 3<&0 <<APPLESCRIPT |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[devshell] | |
packages = [ | |
# node | |
"nodejs-18_x", | |
# node canvas deps | |
"pkg-config", | |
"cairo", | |
"cairo.dev", | |
"pango", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[devshell] | |
packages = [ | |
"rustup", | |
] | |
[devshell.startup.rust] | |
text = """ | |
rustup default stable | |
rustup component add rust-src | |
""" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: build | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
matrix: | |
runs-on: ubuntu-latest | |
outputs: | |
packages: ${{ steps.set_packages.outputs.packages }} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Update yarn.lock | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
yarn.lock: | |
runs-on: ubuntu-latest | |
steps: | |
# setup |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
me | |
you | |
them |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# syntax=docker/dockerfile:1.0-experimental | |
FROM ubuntu | |
RUN apt update && apt install -y openssh-client | |
RUN --mount=type=ssh ssh-add -l > /tmp/ssh-working-agent.out |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# TODO: replace :token, :user, and :repo | |
curl -H "Authorization: token :token" \ | |
-H 'Accept: application/vnd.github.everest-preview+json' \ | |
"https://api.github.com/repos/:user/:repo/dispatches" \ | |
-d '{"event_type": "awesomeness", "client_payload": {"foo": "bar"}}' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
set -e # exit on failure | |
# set -x # print commands before executing them | |
arrayContains() | |
{ | |
declare e match="$1" | |
shift | |
for e; do |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import csv | |
import json | |
from os import path | |
KEEPASS_COLUMNS = [ | |
"Group","Title","Username","Password","URL","Notes" | |
] | |
ONE_PASSWORD_COLUMNS = [ | |
'title','website','username','password','notes','custom field 1' |