Skip to content

Instantly share code, notes, and snippets.

View garrucho's full-sized avatar

Augusto M. Garrucho garrucho

View GitHub Profile
@pawelszydlo
pawelszydlo / clean_and_unmount.sh
Last active June 15, 2024 17:17
Script for cleaning MacOS related trash (dot files and folders) from a removable disk and unmounting that disk.
#!/bin/bash
# Script for cleaning MacOS related trash (dot files and folders)
# from a removable disk and unmounting that disk.
# Script does sanity checks, should be safe, but use at your own risk!
# Newest version can always be found at https://gist.github.com/pawelszydlo/5eacd49d7e57bce71e96171e9fad1cd2
# Display a dialog box.
@RichardBronosky
RichardBronosky / touchid_sudo.sh
Last active October 31, 2024 19:34
Use TouchID for sudo on modern MacBook Pro machines
#!/bin/bash
# curl -sL https://gist.githubusercontent.com/RichardBronosky/31660eb4b0f0ba5e673b9bc3c9148a70/raw/touchid_sudo.sh | bash
# This script is ready to copy-paste in whole, or just the line above (without the leading #)
# Use TouchID for sudo on modern MacBook Pro machines
# This script adds a single line to the top of the PAM configuration for sudo
# See: https://apple.stackexchange.com/q/259093/41827 for more info.
touchid_sudo(){