Skip to content

Instantly share code, notes, and snippets.

View yungztrunks's full-sized avatar

*yungztrunks yungztrunks

View GitHub Profile
@yungztrunks
yungztrunks / lottikarotti.md
Created March 17, 2025 10:27
git repo code leaderboard

leaderboard of who wrote the most lines of code in a git repo

git ls-tree --name-only -z -r HEAD | xargs -0 -n1 git blame --line-porcelain | grep "^author " | sort | uniq -c | sort -nr

the below can be used to filter by file extension

git ls-tree --name-only -z -r HEAD|egrep -z -Z -E '\.(cc|h|cpp|hpp|c|txt)$' \ |xargs -0 -n1 git blame --line-porcelain | grep "^author " | sort | uniq -c | sort -nr
@yungztrunks
yungztrunks / links.md
Created October 30, 2024 15:20
useful links
@yungztrunks
yungztrunks / color_of_the_supreme_king.py
Created September 24, 2024 11:43
Python colored print statements, various printed colors
PURPLE = "\033[95m"
CYAN = "\033[96m"
DARKCYAN = "\033[36m"
BLUE = "\033[94m"
GREEN = "\033[92m"
YELLOW = "\033[93m"
RED = "\033[91m"
BOLD = "\033[1m"
UNDERLINE = "\033[4m"
END = "\033[0m"
@yungztrunks
yungztrunks / gitstring_search.sh
Created September 23, 2024 08:47
search for specific strings across the entire git repo history using git commands
git rev-list --all | xargs -n 1 git grep 'rashford'
# the above now searchs through all commits in every file for the string "rashford"