git 操作文档

This commit is contained in:
unknown 2023-09-19 17:40:07 +08:00
parent 70fdd6cc24
commit d255419f3b
2 changed files with 29 additions and 1 deletions

View File

@ -0,0 +1,25 @@
```shell
sudo vim /usr/lib/systemd/system/openvpnclient.service
[Unit]
Description=OpenVPNClient
[Service]
Type=simple
ExecStart=openvpn /etc/openvpn/client/server001.ovpn
ExecStop=/usr/bin/killall openvpn
Restart=always
User=root
[Install]
WantedBy=multi-user.target
##刷新
sudo systemctl daemon-reload
```

View File

@ -864,10 +864,13 @@ $ git update-ref refs/tags/<tag_name> <hash>
(main)$ git mv --force myfile MyFile
```
### 我想从 Git 删除一个文件,但保留该文件
### 我想从 Git 删除一个文件(取消一个文件的版本控制),但保留该文件
```sh
(main)$ git rm --cached log.txt
## 文件夹操作
(main)$ git rm -r --cached log.txt
```
配置 (Configuration)