Using GitHub for Projects

If you are interested in having your project backed up and hosted for free you can use GitHub to do this. It's a bit complicated, and will require setting up a free GitHub account.

In order to use this, you'll need a few things:

 

 

 

Using Git Large File Storage for files over 100 MB (With GitHub Desktop)

 

·         Open PowerShell.

o   Change your current working directory to the root of your project folder (using cd).

o   Initialize the repository:

§  git init

o   Run the following command to find all files over 100MB in size:

§  Get-ChildItem -recurse | where-object {$_.length -gt 104857600 } | Sort-Object length | ft fullname, length -auto

o   Any files that show up will need to their filetype flagged to be stored using Git LFS

§  Initialize git LFS:

§  Enter the command: git lfs install

§  You should see the message:   Git LFS initialized.

§  If you don't see a message indicating that git lfs install was successful, close the powershell session, open a new one, then try again.

o   To associate a file type in your repository with Git LFS, enter git lfs track followed by the name of the file extension you want to automatically upload to Git LFS.

§  For example, to associate a .dylib file, enter the following command:

·         git lfs track "*.dylib"

§  You should see the reply: Tracking "*.dylib"

o   The changes that you are making are stored in a .gitattributes file.

§  Git add .gitattributes

o   You are now ready to do your commit and publish in GitHub Desktop

 

·         Open GitHub Desktop, and go into the File Menu -> Add local repository

o   The Local path should point to your project folder

§  Click "Add Repository"

§  You will now do your first local commit

o   Fill out the summary message and then click "commit to master"

§  Wait for the Commit to full finish (spinning wheel stops)

o   You are now ready to publish your branch to GitHub.

§  If you are already signed in to your GitHub account, click "Publish branch"

§  If not, you will probably be prompted to enter your information

o   When the Publish finishes, you can check your online repository

§  Go to the Repository menu, and select "View on GitHub"