Import an existing git project into GitLab?

前端 未结 10 499
南旧
南旧 2020-12-07 06:50

I have an account of a Gitlab installation where I created the repository \"ffki-startseite\"

Now I want to clone the repository git://freifunk.in-kiel.de/ffki

10条回答
  •  遥遥无期
    2020-12-07 07:21

    You create an empty project in gitlab then on your local terminal follow one of these:

    Push an existing folder

    cd existing_folder
    git init
    git remote add origin git@gitlab.com:GITLABUSERNAME/YOURGITPROJECTNAME.git
    git add .
    git commit -m "Initial commit"
    git push -u origin master
    

    Push an existing Git repository

    cd existing_repo
    git remote rename origin old-origin
    git remote add origin git@gitlab.com:GITLABUSERNAME/YOURGITPROJECTNAME.git
    git push -u origin --all
    git push -u origin --tags
    

提交回复
热议问题