Skip to content

Instantly share code, notes, and snippets.

View TylerCode's full-sized avatar
:octocat:
Spaghetti or not, here I come!

Tyler C TylerCode

:octocat:
Spaghetti or not, here I come!
View GitHub Profile
@TylerCode
TylerCode / install_xcpguest.sh
Last active November 25, 2024 21:50
installs the guest tools on Ubuntu for XCP-NG
#!/bin/bash
# Check if script is run as root
if [ "$EUID" -ne 0 ]; then
echo "Please run as root"
exit 1
fi
# Common CD/DVD device locations
DEVICE_LOCATIONS=(
@TylerCode
TylerCode / text_to_csv_money.py
Created April 15, 2025 17:04
Takes a text file, removes lines that don't start with $, and makes a new CSV of only the $ entries.
def process_bonk_file(input_file="bonk.txt", output_file="bonk_fixed.csv"):
try:
with open(input_file, 'r') as f:
lines = f.readlines()
except FileNotFoundError:
print(f"Error: Could not find {input_file}")
return
except Exception as e:
print(f"Error reading file: {e}")
return