外部應用程式
外部应用程式
《FreeFileSync 使用者手冊》:快速入門 命令列 比較設定 日光節約時間 排除檔案 專家設定 外部應用程式 巨集 效能 即時同步 即時同步:以服務方式執行 排程批次作業 同步設定 (S)FTP 設定 訣竅與技巧 變動磁碟機代號 版本控制 磁碟區陰影複製
當您在主對話框中雙擊其中一行時,FreeFileSync 預設會打開作業系統的文件瀏覽器:
若要自訂此操作,或將其他外部應用程式整合到 FreeFileSync 中,請導覽至 功能表 → 工具 → 選項 → 自訂捷徑功能表 ,然後新增或取代命令。所有項目都可以透過按下相關的 數字鍵 0–9 或透過滑鼠右鍵按一下後顯示的內容功能表快速存取。 第一個項目 也可以透過 按兩下 項目來執行。除了一般的 **巨集** 之外,也提供下列特殊巨集:
外用藥劑
當您在主對話框中雙擊其中一行時,FreeFileSync 預設會打開作業系統的文件瀏覽器:
Windows: | explorer.exe /select, "%local _ path%" & exit 0 | |
macOS: | open -R "%local _ path%" | |
Linux: | xdg-open "$(dirname "%local _ path%")" |
Macro | Description | |||
%item _ path% | Full file or folder path | |||
%local _ path% | Creates a temporary local copy for files located on SFTP and MTP storage. Otherwise identical to %item _ path% for local files and network shares. | |||
%item _ name% | File or folder name | |||
%parent _ path% | Parent folder path |
- • To refer to the item on the opposite side, append " 2 " to the macro name:
%item _ path 2 %, %local _ path 2 %, %item _ name 2 %, %parent _ path 2 %. - • To generate a list including all selected items (separated by space), append " s " to the macro name:
%item _ path s %, %local _ path s %, %item _ name s %, %parent _ path s %.
Examples
- • Start a file content comparison tool:Windows: WinMerge "C: \ Program Files (x86) \ WinMerge \ WinMergeU.exe" "%local _ path%" "%local _ path2%"macOS: opendiff (requires Xcode)opendiff "%local _ path%" "%local _ path2%"Ubuntu: kompare (sudo apt install kompare)kompare "%local _ path%" "%local _ path2%"
- • Show file in Windows Explorer:explorer.exe /select, "%local _ path%" & exit 0 Note
Explorer.exe does not set an exit code, but FreeFileSync will show an error message if it does not find exit code = 0 ("Success"). To mitigate, append ( & ) command exit 0 to set the exit code explicitly. - • Open command prompt for the selected item:start cmd.exe /k cd /D "%parent _ path%" Note
FreeFileSync hides the console window, so start opens a new window. cmd.exe /k runs the following command without immediately exiting the console. cd navigates to the directory, even if it's on a different volume ( /D ). - • Copy item path to Clipboard (as alternative to CTRL + C)echo %item _ path%| clip
- • Write list of selected file paths to a text file:echo %item _ path% >> %csidl _ Desktop% \ file _ list.txt
- • Preview files using Quick Look on macOS:qlmanage -p "%local _ path%"
- • Pass a list of selected files to a script as command line arguments:C: \ my-script.cmd "%local _ path s %"