UPDATE 2023-01-22 21:34:33
This guide was last tested on an Intel MacBook 2017. Since then it's unmaintained and won't be updated (I quit the game and bought a life-time crossover licence).
This has been forked from https://gist.github.com/Alex4386/4cce275760367e9f5e90e2553d655309
For the latest discussion, see the comments there.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| # Recursively remove all special characters from filenames by renaming them to their ASCII normalized forms. | |
| # | |
| # By default it does a dry run, to actually move the files uncomment the `mv -vi ...` line. | |
| # | |
| # This is useful for cleaning up network shares that will be shared via SMB/NFS between Unix/macOS/Windows | |
| # where non-ASCII filenames can sometimes cause "file does not exist" errors when trying to access the files. | |
| # | |
| # This script removes leading/trailing whitespace in filenames and replaces accents and non-english | |
| # characters with their ASCII equivalent, if no ASCII equivalent exists, it removes the character e.g.: |
Save these files as ~/.config/systemd/user/some-service-name.*
Run this now and after any modifications: systemctl --user daemon-reload
Try out the service (oneshot): systemctl --user start some-service-name
Check logs if something is wrong: journalctl -u --user-unit some-service-name
Start the timer after this user logs in: systemctl --user enable --now some-service-name.timer
