My question is a simple one which I'm not sure how to tackle.
When compiling libraries in gradle, I use the code shown below:
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:cardview-v7:21.0.+'
compile 'com.android.support:recyclerview-v7:21.0.+'
compile 'com.android.support:design:22.2.+'
compile 'com.android.support:appcompat-v7:22.2.+'
}
This gives me the what I want and I have no issues whatsoever. I'm guessing the code above makes sure that the latest version of each dependency is compiled when the app is built (hence the "+" sign at the end of each statement). However, I've seen in many places online where the same lines of code are as shown below without the "+" sign:
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:cardview-v7:21.0.0'
compile 'com.android.support:recyclerview-v7:21.0.0'
compile 'com.android.support:design:22.2.0'
compile 'com.android.support:appcompat-v7:22.2.0'
}
There is no discernible difference and both work fine the same. But as a developer with intentions to have long term support for the app, which should I use? With or without the appended "+" sign. What are the possible benefits or issues from using one over the other? Any feedback would be highly appreciated.