Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
有没有办法配置应用程序快捷方式,以便在启动应用程序之前运行 Windows shell 脚本?就我而言,我想在应用程序运行之前备份一些文件。
谢谢!
您可以更改应用程序快捷方式以实际运行 shell 脚本,只需在脚本末尾添加一个 START 命令,以便它在完成后运行程序。
IE:将记事本快捷方式从 %SYSTEMROOT%\Windows\Notepad.exe 更改为 c:\launchNotepad.bat 并让 launchnotepad.bat 类似于
COPY importantfile.txt importantfile.txt.bak START %SYSTEMROOT%\Windows\Notepad.exe importantfile.txt