Skip to content

Instantly share code, notes, and snippets.

View jwillikers's full-sized avatar

Jordan Williams jwillikers

View GitHub Profile
@jfcherng
jfcherng / st4-changelog.md
Last active April 20, 2024 00:25
Sublime Text 4 changelog just because it's not on the official website yet.
# OpenBSD dhcpcd configuration to get an IPv6 prefix delegation from a native-IPv6 ISP (e.g., Comcast).
#
# Here, 'axe0' is the interface connected to the cable modem, 'em0' is on the LAN.
# The configuration will ask for a /60, and will assign the /64 with subnet ID 1
# to em0.
# Use an IPv6 router advertisement daemon to advertise this to the rest of the network!
allowinterfaces axe0
ipv6only
nooption domain_name_servers
@afresh1
afresh1 / start_inet6.sh
Last active May 8, 2020 17:24
Find the default IPv6 gateway and start forwarding traffic on OpenBSD and Comcast (XFinity)
#!/bin/sh
egress=$1
internal=$2
# This should set up ipv6 on XFinity or Comcast on OpenBSD 6.1
# Stop everything
/usr/bin/pkill dhcp6c
route -qn delete -inet6 default
ifconfig $egress -inet6
@zlbruce
zlbruce / svg2icns
Created October 1, 2016 01:17
covert svg to icns (with imagemagick)
#!/bin/bash
echo "*** SVG 2 ICNS ***"
if [ $# -ne 1 ]; then
echo "Usage: svg2icns filename.svg"
exit 100
fi
filename="$1"
name=${filename%.*}
ext=${filename##*.}
echo "processing: $name"
@sebastianhaas
sebastianhaas / socketcan-interface.service
Created August 6, 2016 15:02
An example systemd unit file to setup a SocketCAN interface on startup
[Unit]
Description=SocketCAN interface can0 with a baudrate of 250000
After=multi-user.target
[Service]
Type=oneshot
RemainAfterExit=yes
ExecStart=/sbin/ip link set can0 type can bitrate 250000 ; /sbin/ifconfig can0 up
ExecReload=/sbin/ifconfig can0 down ; /sbin/ip link set can0 type can bitrate 250000 ; /sbin/ifconfig can0 up
ExecStop=/sbin/ifconfig can0 down
@steinwaywhw
steinwaywhw / One Liner to Download the Latest Release from Github Repo.md
Last active May 5, 2024 20:02
One Liner to Download the Latest Release from Github Repo
  • Use curl to get the JSON response for the latest release
  • Use grep to find the line containing file URL
  • Use cut and tr to extract the URL
  • Use wget to download it
curl -s https://api.github.com/repos/jgm/pandoc/releases/latest \
| grep "browser_download_url.*deb" \
| cut -d : -f 2,3 \
| tr -d \" \
@azam
azam / svg2ico.sh
Last active April 28, 2024 03:28
Convert SVG to ICO using ImageMagick, with transparent background and multi-size icons
convert -density 256x256 -background transparent favicon.svg -define icon:auto-resize -colors 256 favicon.ico