Skip to content

Instantly share code, notes, and snippets.

View GeoZac's full-sized avatar

George Zacharia GeoZac

  • India
View GitHub Profile
@luukvbaal
luukvbaal / cacheremove.hook
Last active February 17, 2026 04:55
yay paccache hooks
[Trigger]
Operation = Remove
Type = Package
Target = *
[Action]
Description = Clearing cache...
When = PostTransaction
Exec = /home/<user>/.local/bin/tools/removehook
@jeromer
jeromer / compassbearing.py
Last active November 19, 2025 20:13
compass bearing between two points in Python
# LICENSE: public domain
def calculate_initial_compass_bearing(pointA, pointB):
"""
Calculates the bearing between two points.
The formulae used is the following:
θ = atan2(sin(Δlong).cos(lat2),
cos(lat1).sin(lat2) − sin(lat1).cos(lat2).cos(Δlong))