iconvlinux
本身沒有提供查看轉換進度的功能
progress
命令:在運行 iconv
命令時,添加 --progress
選項。這將顯示轉換進度。例如:
iconv -f input_encoding -t output_encoding input_file.txt --progress -o output_file.txt
tail
命令監控輸出文件:在另一個終端窗口中,使用 tail
命令實時查看輸出文件的變化。例如:
tail -f output_file.txt
這將顯示輸出文件的最后幾行,你可以觀察轉換進度。請注意,這種方法可能不是實時的,因為 iconv
可能需要一些時間來處理文件。
有一些第三方工具可以幫助你查看轉換進度,例如 progress
(https://github.com/juliomalegria/progress)或 progress-bar
(https://github.com/卜凡/progress-bar)。這些工具可以集成到你的腳本中,以便更好地監控轉換進度。