Skip to content

Instantly share code, notes, and snippets.

Avatar

Jesse Riddle bitmvr

View GitHub Profile
@bitmvr
bitmvr / generate-join-wifi-qrcode.md
Last active Jul 18, 2021
Generate Wi-Fi Config QR Code
View generate-join-wifi-qrcode.md

Generate Wi-Fi Card on macOS

Create ./generate-wifi-config.sh

  1. Copy the contents of the code block below.
  2. Paste it into a file
  3. Save it as generate-wifi-config.sh
  4. Execute: chmod +x ./generate-wifi-config.sh to make it executable.

Note: Upon execution, your operating system is going to ask for your machine password. It does this because the script obtains your Wi-Fi password that is stored in the macOS Keychain.

@bitmvr
bitmvr / chipr.sh
Created Mar 23, 2021
chipr.sh - Delete merged branches from local and remote.
View chipr.sh
#!/usr/bin/env bash
# set -x
if [ $# -eq 0 ]; then
echo "ERROR: Please provide the MAIN branch for this project in order to exclude it."
exit 1
fi
readonly MAIN_BRANCH="$1"
@bitmvr
bitmvr / install-xpdf-japanese-language-package.md
Last active Mar 21, 2021
Install xpdf Japanese Language package
View install-xpdf-japanese-language-package.md

Install XPDF Japanese Language Package

Step 1: Download the Japanese Language Package

curl -sL https://dl.xpdfreader.com/xpdf-japanese.tar.gz -o "$HOME/Downloads/xpdf-japanese.tar.gz"

Step 2: Create the required directories and files.

@bitmvr
bitmvr / raspbian-buster-matrix-synapse-install.md
Last active Jan 31, 2021
Installing Matrix-Synapse on Raspbian Buster
View raspbian-buster-matrix-synapse-install.md

Install Synapse on Raspbian GNU/Linux 10 (buster)

A step-by-step guide for installing Synapse on Raspbian Buster.

Pre-requisites

Install Software

  1. Execute: sudo apt-get install build-essential
  2. Execute: sudo apt-get install python3-dev
  3. Execute: sudo apt-get install libffi-dev
@bitmvr
bitmvr / get_participants_from_google_meet.js
Last active Jan 26, 2021
getParticipantsFromGoogleMeet - Javascript to return a list of all users from a Google Meet Participants
View get_participants_from_google_meet.js
let scrubParticipants = function(participant) {
if ( participant.includes('You') || participant.includes('Presentation')) {
participant = participant.replace('(You)','');
participant = participant.replace('Presentation','');
participant = participant.replace('\n','');
}
return participant;
}
@bitmvr
bitmvr / hackn.sh
Last active Dec 13, 2020
hackn - A lightweight hacker news CLI tool.
View hackn.sh
#!/usr/bin/env bash
NUM_OF_STORIES="$1"
getTopStoryIds(){
curl -sL "https://hacker-news.firebaseio.com/v0/topstories.json" | tr -d '[]' | tr ',' '\n'
}
getStoryData(){
storyID="$1"
@bitmvr
bitmvr / chipr.sh
Last active Nov 19, 2020
Chipr cleans up remote branches from your projects remote repository.
View chipr.sh
#!/usr/bin/env bash
# set -x
if [ $# -eq 0 ]; then
echo "ERROR: Please provide the MAIN branch for this project in order to exclude it."
exit 1
fi
readonly MAIN_BRANCH="$1"
@bitmvr
bitmvr / calpoc.sh
Created Sep 4, 2020
Calculate Percentage of Change
View calpoc.sh
#!/usr/bin/env bash
usage(){
echo "$(basename "$0") start_value end_value"
}
# Check if any flags or values were passed
if [ "$#" -eq 0 ]; then
usage
exit
View covid-national-data-notes.txt
# For the national data, add NULL_FIELD to 'empty' columns so that the cut is performed correctly
# sed -i -- "s/,,/,NULL_FIELD,/g" ts-covid-us-null-filled.csv
# cat ./ts-covid-us.csv | cut -d ',' -f6-7,12- > ./filtered.csv
@bitmvr
bitmvr / istioctl-installer.sh
Last active Apr 23, 2020
An istioctl installer - Easily install istioctl
View istioctl-installer.sh
#!/bin/sh
__getLatestVersion(){
request="$(curl -sI https://github.com/istio/istio/releases/latest | grep "^location")"
request="${request##*/}"
echo "$request" | tr -d '\r'
}
__getOperatingSystem(){
get_system_name="$(uname | tr '[:upper:]' '[:lower:]')"