git 入门操作
?從已有的GIT倉庫獲取最新代碼
git clone url
建立本地倉庫,并提交至git-hub
生成ssh的公鑰私鑰對:ssh-keygen
從pc端打開生成的公鑰,id_rsa.pub,復制并黏貼至git-hub的ssh-keys
cd至程序文件夾,輸入 git init
然后輸入git add .(.代表所有文件也可以輸入具體的單個文件名)
然后輸入git commit -m “任意注釋”
創建一個remote git remote add origin url(ssh、https、subversion)
最后提交 git push origin master
從remote獲取最新版本 git pull origin master
git log 獲取本地提交歷史
git revert 版本序列號
?
?注:遇到沖突時,先?git add .,然后commit,然后?pull,最新版本拿下來,然后手動調整下,然后?push。
注: git clone 已有laravel項目時,vendor文件夾是git不下來的,所以要自己配置這個文件夾。
注:要更新服務器的版本,就遠程到服務器,cd到Vtraining,打git pull origin master。
轉載于:https://www.cnblogs.com/ginikeer/p/3921483.html
總結
- 上一篇: Quartus II调用modelsim
- 下一篇: 哈希表的实现(取余法)