How to Upload Flutter Project on GitHub | Bring Remote Repo Locally | A - Z | 2022

Last updated Jan 24, 2022

In this article i will teach you how to uload your flutter project on to github. This course we will cover

  • What is git?
  • What is github?
  • What are the benefits of using git/github?
  • How to use git/github?
  • How we can use git/github in our project?

 

What is git?

Git is a version control system. In short we can call it vcs. Without git, there are lot of vcs
they are svn, marcurial, gitlab, cvs and more. Git is a tool which will be used to host our projects remotely by writing few  comments so that anyone can access to clone it and download it. The purpose of hosting the project
remotely is to allow others to contribute to the open source project, suppose if we want to use the project for ourselves then we can host the project privately

To work with Git we need to install git in our local machines. Read about how to install git

What is github?

Github is a hosting service, where we'll host our Flutter project.

 

What are the benefits of using git/github?

1.fast
2. work offline
3. revise code/control version
4. team collaboration

 

How to use git/github?

To use git, must have to install in our operating sytem. You can download & install from here

 

To use github, must have to create a github account and logged in the account. Create account from here.

Now let's jump into the main topic, How we can use git/github in our project?
 

How to upload flutter project on github?
Step-1 Open Terminal

Step- 2 Step by step all commands to upload project remotely.
→ 1. git init
→ 2. git add .
→ 3. git commit -m "description"
→ 4. git branch -M branchName
→ 5. git remote add origin repoUrl
→ 6. git push -u origin branchName

 

 

Add modified files to that remote project;
Step-1 Step by step 3 commands to upload modified files/folders.
→ 1. git add .
→ 2. git commit -m "description"
→ 3. git push -u origin branchName

 

This way we can upload our project remotely.

Now we'll see how we can bring the repo locally in our system.

There are 2 ways; 

1. Git clone

2. Download zip 

 

How to upload flutter project to github


To clone repo : Github project → code → copy url → vs code → clone repo
To download zip : Github project → code → download zip


 

Article Contributed By :
https://www.rrtutors.com/site_assets/profile/assets/img/avataaars.svg

1098 Views