Nginx 跨域(不安全,但快捷)
1 | add_header Access-Control-Allow-Origin *; |
更改 npm 源
1 | npm config set registry https://registry.npm.taobao.org |
docker 加速
1 | sudo mkdir -p /etc/docker |
Clion 无法使用 Ctrl+左键进行代码跳转
右键项目根目录,点击Mark Directory as
->Projects Sources and Headers
Git 配置使用 Clash 本地 proxy
git 出现unable to access https://github.com/XXX.git
时,可以配置本地 proxy,当然也可以开启系统的全局 proxy
添加 proxy:git config --global http.proxy 127.0.0.1:7890
解除 proxy:git config --global --unset http.proxy
QT 国内源
1 | https://mirrors.tuna.tsinghua.edu.cn/qt/online/qtsdkrepository/windows_x86/root/qt/ |
Linux 上使用 awk 或者 tr 更换换行符后结果消失
检查换行符是否为 LF(\n),若是 CR(\r)或者 CRLF(\r\n)请更换为 LF。
Windows clone linux 源码报错 invalid path XXX/aux.c'
在项目目录执行:
1 | git config core.protectNTFS false |
VMware 和 wsl2 的 hyper-v 冲突问题
启用 VMware
bcdedit /set hypervisorlaunchtype off
启用 WSL
bcdedit /set hypervisorlaunchtype auto
VMware 对 Ubuntu 磁盘扩容
-
虚拟机关机后选中磁盘,选择
扩展
; -
安装 gparted 对指定磁盘进行 Resize:
apt install gparted
; -
使用
df -lh
查看磁盘容量。
Ubuntu Network Manager Bug Fix
1 | sudo touch /etc/NetworkManager/conf.d/10-globally-managed-devices.conf |