-
git拉取項目
git init 初始化倉庫
git clone (git地址)
圖片.png
刪除.idea配置
idea運行
-
先打開文件
圖片.png - 配置maven倉庫地址
-
將web變成web項目
圖片.png
圖片.png
圖片.png
圖片.png
圖片.png
圖片.png
圖片.png
圖片.png
圖片.png
圖片.png
-
如果運行項目報ideajava.lang.ClassNotFoundException: org.springframework.web.context.ContextLoa 代表lib依賴沒進去
在IDEA中點擊File > Project Structure > Artifacts > 在右側(cè)Output Layout右擊項目名丑婿,選擇Put into Output Root熊赖。
執(zhí)行后爹梁,在WEB-INF在增加了lib目錄斯碌,里面是項目引用的jar包迷殿,點擊OK呀洲。
圖片.png
再次啟動發(fā)現(xiàn)可以運行
web打成wer包
圖片.png
-
war包打成功后的路勁
圖片.png
上傳git
- 在git上新建一個倉庫
- 圖片.png
- 輸入個人信息(代碼提交者)
git config --global user.name "xxxx"
git config --global user.email xxxxx@qq.com
- 在本地項目目錄創(chuàng)建本地倉庫
git init
- 上傳所有代碼到本地倉庫
git add .
- 提交到本地倉庫
git commit -m "initial commit"
-上傳代碼到github 關(guān)聯(lián)本地倉庫并上傳代碼
git remote add origin https://github.com/Yanyf765/hr_sys.git(上步驟復(fù)制的地址)
- 推送到git
git push origin master
圖片.png