The problem is likely with "REFACTOR traccar to newname".
Still no success.
Steps:
I loaded traccar manager latest version in Android Studio (latest version)
I changed the package name from "org.traccar.manager" to "org.newname.manager" in:
StartFragment
MainActivity
MainFragment
SecurityManager
build.gradle(applicationId and namespace)
Updated buildscript
buildscript {
ext.kotlin_version = '1.9.24'
repositories {
Google()
mavenCentral()
}
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
classpath 'com.android.tools.build:gradle:8.5.1'
classpath 'com.google.gms:google-services:4.4.2'
classpath 'com.google.firebase:firebase-crashlytics-gradle:3.0.2'
}
}
SYNC PROJECT
BUILD CLEAN PROJECT [SUCCESS]
BUILD REBUILD PROJECT [SUCCESS]
Successfully generated REGULARRELEASE
When trying to generate GOOGLERELEASE
Why would you rename everything? That's exactly the problem.
Hello, I won't give up so easily.
Steps:
Open original project
Manually renamed package in:
ManagerMessagimService
GoogleMainApplication
MainActivity
MainFragment
StartFragment
Renamed with REFACTOR just TRACCAR folder to new name
Renamed package in build.gradle app: applicationID
Clean Project (SUCCESS)
Rebuild Project (presents problem with REFERENCE R (here I have a question. Is it normal for this problem to appear and then I have to import these classes and move on? Or have I already done something wrong in these steps I took?
Remembering that my objective is just to rename the package and get a GOOGLE RELEASE
You should not need to rename anything in the code. You just change app id.
Thank you very much Anton
I'll move on.
To resolve the "Unresolved reference" error in Android Studio when generating Google Release in Traccar Manager, follow these steps:
In Android Studio:
1 REFACTOR traccar to newname
2 FILE / SYNC PROJECT WITH GRADLE FILES (sucess)
3 new file google-services.json (corresponding to the new package)
4 TOOLS / FIREBASE - CLOUD MESSAGE (success)
5 GRADLE SCRIPTS - updated successfully.
6 BUILD / REBUILD PROJECT (success)
When trying to generate Google Release the following errors occur (any tips to fix it?):