banner



How To Upload Files To Github Repository Windows

This commodity is solely for newbies in Github regarding how to push big files to your Github repository.

GitHub does not allow u.s. to upload files larger than 25 megabytes through the browser. If y'all endeavor yous may get an mistake as follows.

Github error message when try to upload large files

Effigy 01: Fault message (Image source: Screenshot by the Author)

Nevertheless, you tin can push larger files into your GitHub repository using the git bash concluding every bit follows, in just 8 steps.

Stride 01

Download and install Git on your pc.

Download link:- https://git-scm.com/downloads

Step 02

Then download and install GitLFS on your pc.

Download link: https://git-lfs.github.com/

Step 03

Now clone your GitHub repository to your local motorcar.

For this,

Beginning go to your repository and copy the 'clone/download' URL.

Copy the clone or download URL

Figure02: Copy the clone or download URL (Image source: Screenshot by the Writer)

Next, create a new folder in your pc wherever you prefer: this is to clone the copy of your GitHub repository to your pc.

Then correct-click the background and click 'Git Bash Here' as follows.

Opening Git Bash terminal

Effigy 03: Opening Git Bash (Image source: Screenshot by the Writer)

So run the following command in the bash terminal opened.

                      $            git            clone                          link you copied                    Eg:- $ git clone https://github.com/Newuser/NewRepository.git        

Shut the fustigate terminal and, now you have successfully cloned your GitHub repository to your local machine.

The repository named NewRepository has cloned successfully

Effigy 04: The repository named NewRepository has cloned to the local machine (Prototype source: Screenshot past the Author)

Step 04

Go to inside the cloned repository. (If you lot desire to upload the file to some other folder already created within the repository, then become to that folder)

Right-click the background and over again click 'Git Fustigate Here'.

Run the following command

                      $            git lfs track            ".fileextension"          Eg: If I want to upload a pdf file, and so
$ git lfs track ".pdf"

Step 05

So copy the file you lot desire to upload, into repository or folder in the repository.

Step 06

Then run the command,

                      $            git add            filename.fileextension                    Eg:- $ git add            TheGuid.pdf                  

Stride 07

Nosotros should log into GitHub to push the file to the repository, run the post-obit commands.

                      $            git config --global user.email            "you@instance.com"          Eg:- $ git config --global user.email "123abc@gmail.com"        

For this use your email address used in Github account.

                      $            git config --global user.name            "your proper name"          Eg:- $ git config --global user.proper name "George Bernard"        

For this utilize your name in Github business relationship. You tin observe your email and name in the settings of the Github business relationship.

Then a window will pop out asking your Github electronic mail/user proper noun and password. Enter the credentials and submit them.

Step 08

Now run the following command.

                      $            git commit -m            "commit bulletin"          Eg:- $ git commit -m "add TheGuid.pdf"        

Next run,

                      $            git button origin master                    This command will start the uploading the file.        

You volition find the progress of the uploading in the bash last every bit follows

progress of file upload shown in bash terminal

Figure 05: Progress of file upload (Image source: Screenshot by the Author)

Subsequently uploading is finished, you may discover the file is uploaded to your GitHub repository, successfully.

Source: https://medium.com/linkit-intecs/how-to-upload-large-files-to-github-repository-2b1e03723d2

Posted by: brownvesect1978.blogspot.com

0 Response to "How To Upload Files To Github Repository Windows"

Post a Comment

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel