Cov txheej txheem:

Kuv yuav ntxiv ib qhov project rau kuv qhov chaw khaws cia Git li cas?
Kuv yuav ntxiv ib qhov project rau kuv qhov chaw khaws cia Git li cas?

Video: Kuv yuav ntxiv ib qhov project rau kuv qhov chaw khaws cia Git li cas?

Video: Kuv yuav ntxiv ib qhov project rau kuv qhov chaw khaws cia Git li cas?
Video: Tsis Deev Koj Thiaj Tsis Seev BY Aka 2024, Hlis ntuj nqeg
Anonim

Ntxiv qhov project uas twb muaj lawm rau GitHub siv kab hais kom ua

  1. Tsim ib new chaw cia khoom ntawm GitHub .
  2. Qhib Git Bash.
  3. Hloov tus tam sim no ua hauj lwm directory rau koj hauv zos qhov project .
  4. Pib pib tus local directory as a Git repository .
  5. Ntxiv cov cov ntaub ntawv hauv koj tshiab hauv zos chaw cia khoom .
  6. cog lus tus cov ntaub ntawv uas koj tau staged hauv koj hauv zos chaw cia khoom .
  7. Luam tus https url ntawm koj tsim tshiab rov .

Tsis tas li ntawd, kuv yuav thawb mus rau qhov chaw cia khoom uas twb muaj lawm?

1 Teb

  1. Ces rename lub repo nrog upstream siv: git tej thaj chaw deb rename keeb kwm ntws.
  2. Tom qab ntawd ntxiv koj qhov chaw khaws cia url rau koj cov chaw taws teeb siv: git chaw taws teeb ntxiv keeb kwm
  3. Tom qab ntawd thawb cov kev hloov pauv rau koj cov chaw taws teeb repo siv: git push origin master.
  4. Txhawm rau hloov kho thiab rub cov kev hloov pauv koj tuaj yeem ua:

Tsis tas li ntawd, kuv yuav ntxiv qhov project uas twb muaj lawm rau GitLab li cas? Koj tuaj yeem xa koj cov chaw khaws cia uas twb muaj lawm los ntawm kev muab Git URL:

  1. Los ntawm koj GitLab dashboard nyem New project.
  2. Hloov mus rau Import project tab.
  3. Nyem rau ntawm Repo los ntawm URL khawm.
  4. Sau rau hauv "Git repository URL" thiab cov haujlwm ua haujlwm ntxiv.
  5. Nyem Tsim qhov project los pib cov txheej txheem ntshuam.

Hauv qhov no, kuv yuav txuas mus rau Git repository uas twb muaj lawm li cas?

Hauv koj uas twb muaj lawm repository : git tej thaj chaw deb ntxiv REMOTENAME URL. Koj tuaj yeem sau npe rau cov chaw taws teeb github , piv txwv li, lossis lwm yam uas koj xav tau. Luam qhov URL los ntawm qhov GitHub paj la chaw cia khoom koj nyuam qhuav tsim. Push los ntawm koj uas twb muaj lawm repository : git thawb REMOTENAME BRANCHNAME.

Kuv yuav hloov Git repository li cas?

Yuav ua li cas hloov tej thaj chaw deb git repository

  1. Sau koj cov chaw taws teeb uas twb muaj lawm. Txhawm rau sau cov chaw taws teeb uas twb muaj lawm peb qhib lub davhlau ya nyob twg thiab ntaus hauv cov lus txib hauv qab no: $ git tej thaj chaw deb -v.
  2. Hloov qhov chaw khaws cia Git tej thaj chaw deb. Peb tuaj yeem hloov pauv qhov chaw cia chaw deb los ntawm kev siv git tej thaj chaw deb teeb-url hais kom ua: $ git tej thaj chaw deb teeb-url keeb kwm [email tiv thaiv]: user/repository2.git.

Pom zoo: