windows11还原右键菜单
- 添加注册表
reg.exe add “HKCU\Software\Classes\CLSID\{86ca1aa0-34aa-4e8b-a509-50c905bae2a2}\InprocServer32” /f
- 重启资源管理器
- 打开任务管理器
- windows资源管理器=》结束任务
- 新建任务,输入
explorer.exe
windows配置服务
- winsw
- 配置redis服务
重命名WinSW.exe为redis.exe
新建redis.xml文件(同目录下)
xml<service> <id>Redis</id> <name>Redis</name> <description>Redis service</description> <executable>E:\scoop\apps\redis\current\redis-server.exe</executable> <arguments></arguments> <stopexecutable>E:\scoop\apps\redis\current\redis-cli.exe shutdown</stopexecutable> </service>
添加服务,执行
.\redis.exe install
取消服务,执行
.\redis.exe uninstall
启动服务(管理员权限)
net start Redis
,Start-Service -name Redis
停止服务(管理员权限)
net stop Redis
,Stop-Service -name Redis
重启服务(管理员权限)
Restart-Service -name Redis
websocket服务启动
新建console.js文件
jsvar i=0; setInterval(function(){ i++; console.log(i); }, 1000)
执行
.\websocketd.exe --port=8080 node console.js
windows ssh服务
- OpenSSH
- 解压并复制到
C:\Program Files\OpenSSH
- 进入文件夹,管理员执行
powershell.exe -ExecutionPolicy Bypass -File install-sshd.ps1
- 启动服务
net start sshd
- 卸载,进入文件夹,管理员执行
powershell.exe -ExecutionPolicy Bypass -File uninstall-sshd.ps1
- 设置服务自启
Set-Service sshd -StartupType Automatic
- 修改默认端口
- 打开文件
C:\ProgramData\ssh\sshd_config
- 修改Port的值
- 打开文件
powertoys Run命令
插件 | 直接激活命令 | 示例 |
---|---|---|
计算器 | = | = 2+2 |
Windows 搜索 | ? | ? road 用于查找“roadmap.txt” |
历史记录 | !! | !! car 用于从所有已启用的插件中查找过去曾选择的与“car”匹配的所有结果。 |
已安装的程序 | . | . code获取 Visual Studio Code。 (有关向程序启动添加参数的选项 请参阅程序参数。) |
OneNote | o: | o: powertoys 用于在本地 OneNote 笔记本中搜索包含“powertoys”的页面 |
注册表项 | : | : hkcu 用于搜索“HKEY_CURRENT_USER”注册表项。 |
Windows 服务 | ! | ! alg 用于搜索要启动或停止的“应用程序层网关”服务 !startup:auto 用于搜索自动启动的所有服务 !status:running 用于显示所有正在运行的服务 |
Shell 命令 | > | > ping localhost 用于执行 ping 查询。 |
时间和日期 | ) | ) time and date 用于以不同的格式显示当前时间和日期。 ) calendar week::04/01/2022 用于显示日期“2022/04/01”的日历周。 |
时区 | & | & Newfoundland 用于显示纽芬兰时区中的当前时间。 |
单位转换器 | %% | %% 10 ft in m 用于以 10 英尺为单位计算米数。 |
URI 处理程序 | // | // 用于启动默认浏览器。 // learn.microsoft.com 让默认浏览器转到 Microsoft Learn。 支持 mailto: 和 ms-settings: 链接。 |
Visual Studio Code | { | { powertoys 用于搜索其路径中包含“powertoys”的先前打开的工作区、远程计算机和容器。 |
Web 搜索 | ?? | ?? 用于启动默认浏览器的搜索页面。 ?? What is the answer to life使用默认浏览器的搜索引擎进行搜索。 |
Windows 设置 | $ | $ Add/Remove Programs 可启动用于管理已安装程序的 Windows 设置页面。 $ Device: 用于出其区域/类别名称中带有“device”的所有设置。 $ control>system>admin 用于显示路径“控制面板”>“系统和安全”>“管理工具”的所有设置。 |
Windows 终端配置文件 | _ | _ powershell 用于列出其名称中包含“powershell”的所有配置文件。 |
you-get
下载
scoop install ffmpeg
scoop install python
pip3 install you-get
升级
pip3 install --upgrade you-get
使用
you-get -i 'https://www.youtube.com/watch?v=jNQXAC9IVRw'
- 使用cookie
you-get --cookies=E:\program\you_get\cookie\cookie.txt 'https://www.youtube.com/watch?v=jNQXAC9IVRw'
cookie文件格式:
text
# This is an example of Netscape cookie file format
# Each line represents a single cookie with the following fields:
# domain flag path secure expiration name value
example.com TRUE / FALSE 1672531199 session_id abc123
每个cookie的字段解释如下:
domain:指定cookie所属的域,例如example.com。
flag:布尔值,用于表示是否只向指定的域发送cookie。通常写为TRUE或FALSE。
path:指定cookie在域下的路径,例如/表示在该域的所有路径下有效。
secure:布尔值,指示cookie是否仅通过HTTPS传输,TRUE表示只在安全连接上发送。
expiration:Unix时间戳,表示cookie过期的时间。设置为0表示会话cookie。
name:cookie的名称。
value:cookie的值。