unity-jar-resolver
                                
                                 unity-jar-resolver copied to clipboard
                                
                                    unity-jar-resolver copied to clipboard
                            
                            
                            
                        Use android debugImplementation and releaseImplementation
Is there a way to specify debugImplementation and releaseImplementation for android dependencies?
For example, you can log useful debugging info inside myplugin-debug.aar. When building for release, proguard can strip these logs away.
// desired output to mainTemplate.gradle
debugImplementation files('./libs/myplugin-debug.aar')
releaseImplementation files('./libs/myplugin-release.aar')
At the moment I am constantly adding/removing Log.d calls used for debugging.
Thinking more about this, is it better to use a local file-system repository instead?
I didn't set up a local maven repo before.. would that allow choosing between debug and release binaries?
@troy-lamerton sounds like a neat idea for a feature.  Right now it's not possible to specify debug vs. release artifacts.  However, I could imagine that it would be possible to inject different dependencies based upon the Unity build settings, you would need to at least update https://github.com/googlesamples/unity-jar-resolver/blob/master/source/PlayServicesResolver/src/AndroidXmlDependencies.cs to support dependencies per build type, https://github.com/googlesamples/unity-jar-resolver/blob/master/source/JarResolverLib/src/Google.JarResolver/PlayServicesSupport.cs (in particular GetAllDependencies) to return the appropriate set of dependencies based upon the build configuration type, https://github.com/googlesamples/unity-jar-resolver/blob/master/source/PlayServicesResolver/src/PlayServicesResolver.cs AndroidBuildSystemSettings to track the build type and prompt for resolution if the build type changes.
Ok so what you described would solve the debug vs release question, that's great.
How best to use local aars though? The only reason I would make this feature is to use it with aars built from a local android gradle project.
@troy-lamerton if you want to use local AARs why not plumb them into the Gradle build in Unity via the mainTemplate.gradle file instead?  That would allow you to build the local AARs as part of your application's build process.
If you want to use local AARs you can do so already if you publish them to a local maven repo see https://github.com/googlesamples/unity-jar-resolver/blob/master/sample/Assets/PlayServicesResolver/Editor/SampleDependencies.xml#L10 . Repository references can be local paths relative to the Unity project, or any URI including file URIs.