BLCL的博客小馆

标签 · windows

首页

关于

归档

loading..
pwshpowerhshellwindowsnssmwinsw

将 powershell 脚本添加为开机启动项

本质上是将 powershell 脚本添加为 windows 服务, windows 服务即可设置为开机启动并支持其他管理操作. 一般有两种方式, nssm 和 WinSW假设 powershell 脚本绝对路径为 C:\1.ps1假设服务名称为 PicBackNssmpowershell 执行: nssm install PicBack在弹出的页面填写 Path, StartUp directory, Arguments, Service NamePath 部分必须填: powershellNssm 安装的服务默认是开机启动点击 Install Service 即可任务管理器 → 服务, 搜索即可看到刚刚安装的服务.服务异常日志可在 Windows 事件管理器中查看WinSW编写 .xml 文件, 假..

更多