常用apps配置

pip

  • 设置默认国内源 - Windows系统
1
2
3
pip config set global.index-url 'https://pypi.tuna.tsinghua.edu.cn/simple'

pip config list

git

1
2
3
4
5
6
7
8
9
git config --global user.name 'shenbo'
git config --global user.email 'shenbo@hotmail.com'

git config --global http.proxy 'http://127.0.0.1:9981'

git config -l

git config --global core.editor code
git config --global -e

scoop

  • 设置 aria2 下载
1
2
3
4
5
scoop config aria2-enabled true                   # default: true
scoop config aria2-retry-wait 8 # default: 2
scoop config aria2-split 8 # default: 5
scoop config aria2-max-connection-per-server 8 # default: 5
scoop config aria2-min-split-size] 2M # default: 5M
  • 设置 proxy
1
2
3
scoop config proxy 127.0.0.1:9981

scoop config

npm

  • 设置默认国内源
1
2
3
4
5
npm config set registry https://registry.npmmirror.com/

# 或用 nrm
npm install nrm -g
nrm use taobao
  • 设置 proxy
1
2
3
npm config set proxy http://127.0.0.1:9981

npm config list

ssh

  • 防止长时间无操作,连接断开

在 C:\Users\XXXX\.ssh\config,内容为:

1
ServerAliveInterval 60

youtube-dl

  • 设置默认下载目录
    linux 系统: 修改/新建文件 /etc/youtube-dl.conf,
    或 ~/.config/youtube-dl/config,内容为:
1
-o ~/Sync/ytb/%(title)s.%(ext)s

右键菜单

1
2
3
4
5
6
# 管理员运行运行后重启:
reg.exe add "HKCU\Software\Classes\CLSID\{86ca1aa0-34aa-4e8b-a509-50c905bae2a2}\InprocServer32" /f /ve

# 恢复默认:
# reg.exe delete "HKCU\Software\Classes\CLSID\{86ca1aa0-34aa-4e8b-a509-50c905bae2a2}" /f

文件夹禁用文件类型识别

1
2
3
4
5
6
7
8
9
# 文件夹启动时默认会识别该文件夹内的文件类型(比如图片、音乐、视频等媒体文件的信息),媒体文件过多时加载速度较慢。
# 可以禁用此功能。

# 管理员运行运行后重启:
reg add "HKCU\SOFTWARE\Classes\Local Settings\Software\Microsoft\Windows\Shell\Bags\AllFolders\Shell" /v "FolderType" /t REG_SZ /d "NotSpecified" /f

# 恢复默认:
# reg.exe delete "HKCU\SOFTWARE\Classes\Local Settings\Software\Microsoft\Windows\Shell\Bags\AllFolders\Shell" /f

MCNP 6

Environment::SetEnvironmentVariable(“PATH”, Environment::GetEnvironmentVariable(“PATH”,”Machine”) + “;C:\mcnp6", “User”)

scoop reset (EnvironmentVariable)

Environment::SetEnvironmentVariable(“PATH”, Environment::GetEnvironmentVariable(“PATH”,”Machine”) + “;C:\Users\shenb\scoop\shims", “Machine”)

Environment::SetEnvironmentVariable(“UV_DEFAULT_INDEX”, “https://pypi.tuna.tsinghua.edu.cn/simple“, “User”)
```