Skip to content
UNixize Filename -- replace annoying anti-unix characters in filenames
Branch: master
Clone or download
Latest commit ef523ef Jun 14, 2019
Type Name Latest commit message Commit time
Failed to load latest commit information.
src properly handle symlinks Jun 13, 2019
.gitignore initial commit Apr 24, 2019
Cargo.lock update Cargo.lock Jun 13, 2019
Cargo.toml release version 0.1.1 Jun 13, 2019
LICENSE add MIT license Apr 25, 2019 remove --dryrun flag Jun 13, 2019


UNixize Filename -- replace annoying anti-unix characters in filenames


Certain characters in filenames are problematic for command-line users. For example, spaces and parentheses are treated specially by the shell. unf renames these files, so you no longer have to be annoyed when your Windows-using friend sends you an irritatingly-named zip file.


Using cargo

cargo install unf

This installs to ~/.cargo/bin, so make sure that's in your PATH.

Arch Linux

Install unf from the AUR.


unf [FLAGS] <PATH>...

<PATH>...: The paths of filenames to unixize

-r --recursive: Recursively unixize filenames in directories. If some of the specified paths are directories, unf will operate recursively on their contents

-s --follow-symlinks: Follow symbolic links

-f --force Do not interactively prompt to rename each file


$ unf 🤔😀😃😄😁😆😅emojis.txt
rename '🤔😀😃😄😁😆😅emojis.txt' -> 'emojis.txt'? (y/N): y
$ unf -f 'Game (Not Pirated 😉).rar'
rename 'Game (Not Pirated 😉).rar' -> 'Game_Not_Pirated.rar'
$ unf -rf My\ Files/ My\ Folder
rename 'My Files/Passwords :) .txt' -> 'My Files/Passwords.txt'
rename 'My Files/Another Cool Photo.JPG' -> 'My Files/Another_Cool_Photo.JPG'
rename 'My Files/Wow Cool Photo.JPG' -> 'My Files/Wow_Cool_Photo.JPG'
rename 'My Files/Cool Photo.JPG' -> 'My Files/Cool_Photo.JPG'
rename 'My Files/' -> 'My_Files'
rename 'My Folder' -> 'My_Folder'
You can’t perform that action at this time.