Skip to content

Instantly share code, notes, and snippets.

View ConnerWill's full-sized avatar
👽
These pretzels are making me thirsty

ConnerWill

👽
These pretzels are making me thirsty
View GitHub Profile
@ConnerWill
ConnerWill / connect-wireguard-vpn.sh
Created November 7, 2023 16:11
Script to connect to Wireguard VPN
#!/usr/bin/env bash
die() {
echo "[-] Error: $1" >&2
exit 1
}
PROGRAM="${0##*/}"
ARGS=( "$@" )
SELF="${BASH_SOURCE[0]}"
@ConnerWill
ConnerWill / TEMPLATE-bash-very-nice.sh
Created November 7, 2023 15:44
Bash Script Template
#!/usr/bin/env bash
die() {
echo "[-] Error: $1" >&2
exit 1
}
PROGRAM="${0##*/}"
ARGS=( "$@" )
SELF="${BASH_SOURCE[0]}"
@ConnerWill
ConnerWill / clone-all-my-repos.sh
Created August 11, 2023 20:28
Bash script to clone all of your repos
#!/usr/bin/env bash
while IFS= read -r line; do
git clone "https://github.com/${line}"
done <<< "$(gh repo list | cut -f1)"
@ConnerWill
ConnerWill / goaccess-nginx
Created June 5, 2023 18:40
Helper script to start nginx log analyzer goaccess
#!/bin/bash
## Function to simply pipe nginx logs to goaccess
function _goaccessnginx(){
user_input="${1}"
[[ "${user_input}" == "html" ]]
@ConnerWill
ConnerWill / Jira-Dark-Theme.user.js
Created April 13, 2023 20:49
Dark Mode Theme For Jira/Bitbucket
// ==UserScript==
// @name Jira Dark Theme
// @version 1.0.0
// @description Dark Theme For Jira
// @author @ConnerWill
// @include *ENTER-URL-HERE*
// @icon https://www.google.com/s2/favicons?sz=64&domain=atlassian.net
// @grant GM_addStyle
// @run-at document-start
// ==/UserScript==
@ConnerWill
ConnerWill / rsync-remote-server.sh
Last active March 6, 2023 21:58
bash function to backup a remote server with rsync
#!/bin/env bash
###
#
# Here's what the function does:
#
# Defines variables for the remote server's username, hostname, directory to be backed up, and the local directory where the backup will be stored.
#
# It also defines a variable for the path to a file containing any files or directories to be excluded from the backup.
#
@ConnerWill
ConnerWill / zsh-list-keybindings.zsh
Created November 26, 2022 22:56
List all current ZSH keybindings
# shellcheck disable=2148,2296,2154
zsh-list-keybindings(){
typeset -A Zcolors
# Regular Colors
Zcolors[Color_Off]=''
Zcolors[Black]=''
Zcolors[Red]=''
Zcolors[Green]=''
@ConnerWill
ConnerWill / Convert-ImageToAsciiArt.ps1
Last active December 20, 2023 20:07
Convert-ImageToAsciiArt - PowerShell function to convert an image to ascii art
# NOTICE: This project has been moved to its own repository https://github.com/ConnerWill/Convert-ImageToASCIIArt
function Convert-ImageToAsciiArt {
<#
.SYNOPSIS
Function to convert an image to ascii art.
.DESCRIPTION
The function Convert-ImageToAsciiArt takes an image file path and converts the image to ASCII art.
The ASCII art is created by replacing each pixel in the image with an ASCII character based on the brightness of the pixel.
@ConnerWill
ConnerWill / Ctrl+Alt+Del_over_RDP.md
Created November 10, 2022 17:38
How to trigger a 'CTR + ALT + DEL' in an Windows Remote Desktop Protocol (RDP) session.

Press CTRL+ALT+DELETE in an RDP session

There are multiple ways to trigger CTR+ALT+DEL over an RDP session.


@ConnerWill
ConnerWill / issue.net
Created November 6, 2022 13:52
/etc/issue.net warning messege to be shown when attempting to connect over SSH
┌────────────────────────────────────────────────────────────────────────┐
│ ██ ██ ██ ███████ ████ ██ ██ ████ ██ ████████ │
│░██ ░██ ████ ░██░░░░██ ░██░██ ░██░██░██░██ ░██ ██░░░░░░██│
│░██ █ ░██ ██░░██ ░██ ░██ ░██░░██ ░██░██░██░░██ ░██ ██ ░░ │
│░██ ███ ░██ ██ ░░██ ░███████ ░██ ░░██ ░██░██░██ ░░██ ░██░██ │
│░██ ██░██░██ ██████████░██░░░██ ░██ ░░██░██░██░██ ░░██░██░██ █████│
│░████ ░░████░██░░░░░░██░██ ░░██ ░██ ░░████░██░██ ░░████░░██ ░░░░██│
│░██░ ░░░██░██ ░██░██ ░░██░██ ░░███░██░██ ░░███ ░░████████ │
│░░ ░░ ░░ ░░ ░░ ░░ ░░ ░░░ ░░ ░░ ░░░ ░░░░░░░░ │
┌──────────────────────┴────────────────────────────────────────────────────────────────────────┴──────────────────────────────┐