GitHub Setup
GitHub works for VRChat projects but needs extra setup for large files like textures and models using Git LFS.
Setup for GitHub
Step 1: Create Accounts
- Go to github.com
- Sign up for free accounts (all collaborators)
Step 2: Install Git and Git LFS
- Download Git from git-scm.com
- Install it on all computers
- Download Git LFS from git-lfs.github.com
- Install Git LFS and run:
git lfs installin a terminal
Step 3: Install GitHub Desktop (Easier Option)
- Download GitHub Desktop from desktop.github.com
- Install and sign in with your GitHub account
- Much easier than using command line!
Step 4: Create the Repository (Project Owner)
- Open GitHub Desktop
- Click "File" → "New Repository"
- Name it (e.g., "my-vrchat-project")
- Choose your Unity project folder as the location
- Check "Initialize with README"
- Click "Create Repository"
Step 5: Set Up Git LFS (IMPORTANT!)
You need to tell Git to use LFS for large files:
- Open GitHub Desktop
- Click "Repository" → "Open in Terminal" (or Command Prompt)
- Type these commands one at a time:
git lfs track "*.psd"
git lfs track "*.png"
git lfs track "*.jpg"
git lfs track "*.jpeg"
git lfs track "*.tga"
git lfs track "*.tif"
git lfs track "*.tiff"
git lfs track "*.fbx"
git lfs track "*.obj"
git lfs track "*.wav"
git lfs track "*.mp3"
git lfs track "*.ogg"
git lfs track "*.mp4"
git lfs track "*.mov"
git lfs track "*.blend"
git lfs track "*.prefab"
git lfs track "*.unity"
git lfs track "*.asset"
git lfs track "*.controller"
git lfs track "*.mat"
Step 6: Create .gitignore File
- In your project folder, create a file called
.gitignore(yes, with the dot at the start) - Add these lines:
[Ll]ibrary/
[Tt]emp/
[Oo]bj/
[Ll]ogs/
*.csproj
*.unityproj
*.sln
*.user
*.userprefs
*.pidb
*.booproj
[Uu]ser[Ss]ettings/
.vs/
.vscode/
Step 7: First Commit (Project Owner)
- In GitHub Desktop, you'll see all your files
- Write a summary like "Initial project setup"
- Click "Commit to main"
- Click "Publish repository"
- Choose "Private" to keep it secret
- Click "Publish Repository"
Step 8: Add Collaborator (Project Owner)
- Go to github.com and sign in
- Find your repository
- Click "Settings" → "Collaborators"
- Click "Add people"
- Enter your collaborators' GitHub usernames
- They'll get email invitations
Step 9: Clone the Project (Collaborators Do This)
- Open GitHub Desktop
- Click "File" → "Clone Repository"
- Find the shared repository in the list
- Choose where to save it on your computer
- Click "Clone"
- Wait for everything to download (might take a while!)
Daily Workflow with GitHub
Before You Start Working:
- Open GitHub Desktop
- Click "Fetch origin" then "Pull origin"
- This downloads any changes your collaborators made
After Making Changes:
- Open GitHub Desktop
- You'll see all changed files listed
- Write a summary of what you changed (e.g., "Updated world lighting")
- Click "Commit to main"
- Click "Push origin" to upload your changes
If There's a Conflict:
If multiple people changed the same file:
- GitHub Desktop will warn you about conflicts
- Click "Open in [your editor]"
- Look for sections marked with
<<<<<<<and>>>>>>> - Decide which version to keep
- Save the file, then commit again
Troubleshooting
"Files are too large" (GitHub)
- Make sure Git LFS is installed and tracking the file types
- Run
git lfs track "*.fileextension"for new file types - Check
.gitattributesfile exists
"Stuck on 'Updating' or 'Fetching'"
- Check your internet connection
- Large files take time to upload/download
- Be patient, especially the first time
Quick Reference
GitHub Desktop Commands
- Fetch/Pull = Download collaborators' changes
- Commit = Save your changes locally
- Push = Upload your changes to GitHub