Search code examples
uploadgitlab

How to upload project from local file system to GitLab


I have locally developed an application using Laravel Framework and PhpStorm. So, in the file system of my pc I have the project that I want to upload in a repository created in GitLab.

I have to mention that for development purposes I am currently using Homestead in windows with Vagrant virtual machine.

I already have an account in GitLab and for now I have only created a README file.

What are the necessary steps in order to upload my project in GitLab?


Solution

  • you can create new project without Initialize repository with a README file.

    and follow "Push an existing folder" look like:

    Push an existing folder

    cd existing_folder
    git init --initial-branch=main
    git remote add origin git@gitlab.com:youraccount/project_name.git
    git add .
    git commit -m "Initial commit"
    git push -u origin main