Skip to content

Instantly share code, notes, and snippets.

View aaronedev's full-sized avatar

Aaron aaronedev

View GitHub Profile
@aaronedev
aaronedev / zip-all.ps1
Last active January 25, 2025 21:24
zip all files in the current directory powershell
Get-ChildItem "." | ForEach-Object { Compress-Archive -path $_.Name -destinationPath "$($_.Name).zip"}
@aaronedev
aaronedev / show-drives.ps1
Last active August 14, 2024 11:05
show local drives information
# Get the list of all physical disks
$physicalDisks = Get-PhysicalDisk
# Loop through each physical disk and display its media type, drive letter, and device name
foreach ($disk in $physicalDisks) {
Write-Output "Device ID: $($disk.DeviceID)"
Write-Output "Friendly Name: $($disk.FriendlyName)"
Write-Output "Media Type: $($disk.MediaType)"
# Get the associated partitions
@aaronedev
aaronedev / .gitignore
Last active November 17, 2024 19:08
gitignore starter template windows linux macos kinda as a global ignore
# ======================================================================
# Windows Global Ignore List
# =====================================================================
# Windows thumbnail cache files
Thumbs.db
Thumbs.db:encryptable
ehthumbs.db
@aaronedev
aaronedev / restore_winxp-alt+tab.ps1
Last active February 27, 2025 19:50
Restores Alt+Tab functionality to show little icons no preview bs
Set-ItemProperty HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer AltTabSettings ([int]1)`
@aaronedev
aaronedev / disable_ipv6.ps1
Created October 23, 2024 05:45
powershell disable ipv6
Disable-NetAdapterBinding -Name "*" -ComponentID ms_tcpip6
@aaronedev
aaronedev / .editorconfig
Created January 30, 2025 04:27
editorconfig on arch linux btw
root = true
[*]
charset = utf-8
end_of_line = lf
column_width = 120
insert_final_newline = true
trim_trailing_whitespace = true
indent_style = space
indent_size = 2
@aaronedev
aaronedev / remove_emptyline_starship.sh
Created February 20, 2025 11:57
removing blank space at the top of the shell for bash when setting add_newline = false
#!/bin/sh
show_newline() {
if [ -z "$NEW_LINE_BEFORE_PROMPT" ]; then
NEW_LINE_BEFORE_PROMPT=1
elif [ "$NEW_LINE_BEFORE_PROMPT" -eq 1 ]; then
echo ""
fi
}
PROMPT_COMMAND="show_newline"
@aaronedev
aaronedev / uninstall_neovim.sh
Created February 20, 2025 13:32
uninstall neovim bash oneliner
#!/bin/sh
rm -rf ~/.local/share/nvim/ && rm -rf ~/.local/state/nvim/ && rm -rf ~/.config/nvim
@aaronedev
aaronedev / update-repos.sh
Last active April 11, 2025 06:58
Bash Script: Auto-Update Multiple Git Repositories | home git repository updater ✅
#!/bin/bash
# File: ~/.local/bin/update-repos.sh
# Make sure to chmod +x this script after creating it
# Define color variables for styling output
BLUE='\033[0;32m'
YELLOW='\033[1;33m'
RED='\033[0;31m'
BLUE='\033[1;34m'
MAGENTA='\033[1;35m'
#!/bin/bash
# new display select usb -d 90fps
scrcpy -d --legacy-paste --video-codec=h265 --max-fps=90 --shortcut-mod=ralt --mouse-bind=++bh:++sn --keyboard=uhid --new-display=1920x1080/180 &
# first scrcpy
scrcpy --video-codec=h265 --max-size=1920 --max-fps=60 --shortcut-mod=lctrl --mouse-bind=++bh:++sn --keyboard=uhid &
# second scrcpy
scrcpy --video-codec=h265 --max-fps=60 --shortcut-mod=rctrl --mouse-bind=++bh:++sn --keyboard=uhid --new-display=1920x1080 &