Seamlessly convert between Linux and Windows UNC paths. Convert local Linux path to Windows/Linux UNC and vice versa.
Convert between Linux and Windows UNC:
unctool convert 'smb://mynas.local/some/path' -t windows
# \\mynas.local\some\path
unctool convert '\\mynas.local\some\path' -t linux
# smb://mynas.local/some/pathConvert to remote UNC:
unctool remote-path /mnt/mynas.local/some/path -t windows
# \\mynas.local\some\path
unctool remote-path /mnt/mynas.local/some/path -t linux
# smb://mynas.local/some/pathConvert from remote UNC:
unctool local-path '\\mynas.local\some\path'
# /mnt/mynas.local/some/path
unctool local-path 'smb://mynas.local/some/path'
# /mnt/mynas.local/some/pathRun without arguments to open input window:
unctool-guiOr use unctool-like CLI interface to go straight to results in GUI:
unctool-gui <command> [-t windows|linux]Install unctool CLI:
cargo install unctool-cliInstall unctool GUI:
cargo install unctool-guiInstall unctool library:
cargo install unctoolInstall unctool CLI:
curl -sL -o unctool https://github.com/poul1x/unctool/releases/latest/download/unctool-cli-x64
chmod +x unctool
sudo mv unctool /usr/local/bin
# Test run
unctool --helpInstall unctool GUI:
curl -sL -o unctool-gui https://github.com/poul1x/unctool/releases/latest/download/unctool-gui-x64
chmod +x unctool-gui
sudo mv unctool-gui /usr/local/bin
# Test run
unctool-gui --helpUNC Tool CLI:
git clone https://github.com/poul1x/unctool.git
cd unctool
rustup target add x86_64-unknown-linux-musl
cargo build --release --target x86_64-unknown-linux-musl
cp ./target/x86_64-unknown-linux-musl/release/unctool-cli unctool-cli
chmod +x ./unctool-cli
# Test run
./unctool-cli --helpUNC Tool GUI:
git clone https://github.com/poul1x/unctool.git
cd unctool
rustup target add x86_64-unknown-linux-gnu
cargo build --release --target x86_64-unknown-linux-gnu
cp ./target/x86_64-unknown-linux-gnu/release/unctool-gui unctool-gui
chmod +x ./unctool-gui
# Test run
./unctool-gui --helpUnctool can be integrated into a file manager. I tested it only with double commander and vifm, but other file managers should work too.
- Open Configuration → Options
- Go to Toolbar and insert new button
- Configure:
- Button type:
External command - Command:
unctool-gui - Parameters:
remote-path %fs -t windows
- Button type:
- Apply (Press
OK)
Now you can select any file in a mounted network share and get its Windows UNC path with one click!


