Reputation: 25028
I am committing my first Android project to GitHub by following this video. I know that the bin
and gen
folders must be ignored. Using Eclipse, I did add them to the ignore file.
Now when I
Right Click on Project - Team - Commit
The window that comes up shows me the files in "bin" and "res" also. I can uncheck them, that is fine, but will I have to do this silly exercise again and again or maybe I am not understanding something.
Upvotes: 0
Views: 56
Reputation: 820
Use this for your Android projects. Taken from github gitignore page
# Built application files
*.apk
*.ap_
# Files for the Dalvik VM
*.dex
# Java class files
*.class
# Generated files
bin/
gen/
# Gradle files
.gradle/
build/
# Local configuration file (sdk path, etc)
local.properties
# Proguard folder generated by Eclipse
proguard/
# Log Files
*.log
Upvotes: 1
Reputation: 100448
Copy and paste this into your .gitignore
file:
.settings/org.eclipse.jdt.core.prefs
*/.settings/org.eclipse.jdt.core.prefs
**/bin/*
**/gen/*
**/build/*
**/.idea/*
**/*.iml
.gradle
/local.properties
/.idea/workspace.xml
.DS_Store
.metadata/*
This setup will ignore the irrelevant files and folders. If you have already committed some of these files, take a look at Ignore files that have already been committed to a Git repository.
Upvotes: 1