Skip to content

Instantly share code, notes, and snippets.

View lindeskar's full-sized avatar

Alexander Lindeskär lindeskar

View GitHub Profile
cat <<'EOF' | gh gist create -w -f "filename.sh" -p
<add code here>
EOF
kubectl run temp-$(date +%s) --rm -it --restart=Never --image=busybox -- /bin/sh
docker context create rancher-desktop --docker host=unix://$HOME/.rd/docker.sock --description "Rancher Desktop"
docker context list
docker context use rancher-desktop
[google-cloud-cli]
name=Google Cloud CLI
baseurl=https://packages.cloud.google.com/yum/repos/cloud-sdk-el8-x86_64
enabled=1
gpgcheck=1
repo_gpgcheck=0
gpgkey=https://packages.cloud.google.com/yum/doc/yum-key.gpg https://packages.cloud.google.com/yum/doc/rpm-package-key.gpg
@lindeskar
lindeskar / safari-history.sh
Last active February 16, 2024 11:39
macOS 10.13 Safari browser history with timestamp
sqlite3 $HOME/Library/Safari/History.db "select datetime(visit_time + 978307200, 'unixepoch', 'localtime') as date, title from history_visits order by visit_time asc"

Keybase proof

I hereby claim:

  • I am lindeskar on github.
  • I am lindeskar (https://keybase.io/lindeskar) on keybase.
  • I have a public key ASDWdoyXkJbFdW4LIGwitrS0bsGUB_n_aMo0eHdNu_hRrAo

To claim this, I am signing this object:

@lindeskar
lindeskar / openVPNreconnect
Last active January 21, 2017 10:40 — forked from aelveborn/vpn-status.sh
My edits of the Synology VPN reconnection script by aelveborn.
#!/bin/sh
# Replace o1234567890 with your VPN id. To get your id, start the VPN and run: sudo ps aux | grep client_o
# Replace home with the name of your VPN profile in DSM admin panel.
vpnId="o1234567890"
vpnName="home"
vpnProtocol="openvpn"
# You should not need to change the following variables
vpncFile="/usr/syno/etc/synovpnclient/vpnc_connecting"