Skip to content

Instantly share code, notes, and snippets.

View RedcoatAsher's full-sized avatar
📍
🇬🇧+ 🇺🇸

Asher Peruscini RedcoatAsher

📍
🇬🇧+ 🇺🇸
View GitHub Profile
@RedcoatAsher
RedcoatAsher / gmail-hide-ads.js
Created April 18, 2025 17:36
Arc Boost JS to hide Google "sponsored" emails
function hideTRWithClasses() {
document.querySelectorAll("tr").forEach(tr => {
const classAttr = tr.getAttribute("class"); // safely get class as string
if (!classAttr) return; // skip if there's no class
const classes = classAttr.trim().split(/\s+/); // Split classes into an array
// Check if the <tr> has both zA and zE classes
const hasClasses = classes.includes("zA") && classes.includes("zE");
@RedcoatAsher
RedcoatAsher / Installation.md
Last active September 13, 2023 11:59 — forked from albertbori/Installation.md
Automatically disable Wifi when an Ethernet connection (cable) is plugged in on a Mac

Overview

This is a bash script that will automatically turn your wifi off if you connect your computer to an ethernet connection and turn wifi back on when you unplug your ethernet cable/adapter. If you decide to turn wifi on for whatever reason, it will remember that choice. This was improvised from this mac hint to work with Yosemite, and without hard-coding the adapter names. It's supposed to support growl, but I didn't check that part. I did, however, add OSX notification center support. Feel free to fork and fix any issues you encounter.

Most the credit for these changes go to Dave Holland.

Requirements

  • Mac OSX 10+
  • Administrator privileges
@RedcoatAsher
RedcoatAsher / install_apps_mas.sh
Last active May 25, 2023 12:40
work_macOS_install.bash
B="brew"
I="install"
M="mas"
# MacOS App Store
$B $I mas-cli/tap/mas
$B $I $M
$M update
$M $I 937984704 # Amphetamine
$M $I 1569813296 # 1Password for Safari
@RedcoatAsher
RedcoatAsher / toggle-pip.applescript
Created February 13, 2023 16:47 — forked from danielrotaermel/toggle-pip.applescript
Applescript to toggle picture-in-picture globally - I assign this to a keyboard shortcut with better touch tool (cmd+ctrl+p). Make sure "Developer > Allow JavaScript from Apple Events" is enabled in Safari. Download BTT preset -> https://share.folivora.ai/sharedPreset/caa1198d-36dd-4aeb-89de-142bf39cc336
(*
Description: Applescript to open/close picture-in-picture in Safari
Supported Applications: Safari, IINA
Author: Daniel Rotärmel
Source: https://gist.github.com/danielrotaermel/201f549d5755ea886eb78bb660133722
Instructions:
Assign this to a global keyboard shortcut with better touch tool / hammerspoon etc. - suggested: cmd+ctrl+p.
Make sure "Developer > Allow JavaScript from Apple Events" is enabled in Safari.
Download the BTT preset here -> https://share.folivora.ai/sharedPreset/caa1198d-36dd-4aeb-89de-142bf39cc336
*)
# install Homebrew
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
(echo; echo 'eval "$(/opt/homebrew/bin/brew shellenv)"') >> /Users/asherperuscini/.zprofile
eval "$(/opt/homebrew/bin/brew shellenv)"
B="brew"
I="install"
M="mas"
B="brew"
I="install"
M="mas"
# APPS CORE
$B $I --cask iterm2
$B $I --cask tunnelblick
# $B $I openvpn
# $B $I --cask openvpn-connect
$B $I --cask slack
@RedcoatAsher
RedcoatAsher / work_macOS.zshrc
Last active December 15, 2024 13:22
bark install script
export CLICOLOR=1
export TERM='xterm-vt220'
alias c='clear'
alias cc='clear'
alias ll='c; ls -l'
alias lla='c; ls -la'
alias lsa='c; ls -a'
@RedcoatAsher
RedcoatAsher / tails_install.bash
Last active July 20, 2021 17:19
tails/linux Install Script
cd ~/Downloads
#tails update/upgrade
sudo apt update
sudo apt -y upgrade
#clock sync
sudo apt install -y ntpd
sudo apt install -y hwclock
sudo ntpd -qg
@RedcoatAsher
RedcoatAsher / simplify-gmail_inbox-theme
Last active July 2, 2020 22:40
[Stylus CSS] A Google Inbox-like theme for use w/ the Simplify Gmail Extension
.asl,
.ar6,
.ar8,
.ar9,
.bAP,
.asf,
.aos,
.brW,
.Vj,
.ase,
@RedcoatAsher
RedcoatAsher / index.md
Last active April 4, 2020 22:08 — forked from ubergesundheit/index.md
ngrok on raspberrypi on systemd
  • Download ngrok binary
  • Create /etc/systemd/system/ngrok.service
  • Create /opt/ngrok/ngrok.yml