改執行檔不是好方法... 不小心更新到就要再改一次.
直接找個能自行決定要不要產生 BOM 的 editor 比較快, 然後加個 registry 直接取代系統的 notepad.exe
代碼:
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\notepad.exe]
"Debugger"="\"C:\\Editor\\notepad.exe\""
只要系統要執行 notepad.exe 就會執行所指定的執行檔.