Closed Marzio1 closed 10 years ago
I do not know why the copy paste some text was changed the font size I'm sorry,
Hi @Marzio1,
Yes other have been having the issue but we haven't had enough info to reproduce, I see you posted most of what your environment have and we do appreciate it, we will be working on reproducing with the information you pasted.
We'll get to you as soon as possible.
Hey @Marzio1
I finally found the issue based on the info you posted, btw.. thanks since this was hurting the project. The thing is you guys were copy pasting the code as it was on the Wiki.. and yes the code was not correctly rendered by Markdown so it was not showing the line breaks.
These two (shown in the code block below) should be in different lines and also apply plugin: 'android'
is already added by your code template, so you just have to add the repository part.
apply plugin: 'android' <- This is already in you gradle.build file
repositories { <- You will add from this line below.
maven {
url 'file://' + new File(System.getProperty('user.home'), '.m2/repository').absolutePath
}
}
If you fix that your project should sync successfully.
I also fixed the wiki page so it reflects the right way to do it. Thanks!
Please let us know how did it go
Thank You I made the corrections Now I go to rename the Package Name in the file AndroidManifest.xml but I only rename the package to the third row, or all the "com.baker.abaker"?
In the AndroidManifest.xml file there are three lines to check:
Other than that as you follow the guide there are some other customisation tasks to be done. :) glad you were able to solve the repositories issue.
Now I have 3 red error in the Main Activity:
Cannot resolve R symbol .... R.layout....
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); }
And one red error in Manifest:
android:label="@string/app_name" >
Hi, for the Main activity try this https://github.com/bakerframework/baker-android/wiki/Creating-your-own-Baker-Android-Project#cannot-find-symbol-variable-activity_main
For the Manifest.. should be solved when you finish the customisation, since you have to replace the current string resources of the project with the ones form baker which includes the app_name
Ok finally the synchronization is successful Now proceed to the customization and if I doubt I will alert you
Sorry but before customizing, following the tutorial I should run my project But how should I start the project? Run App or run App engine or Run My Project run engine? And with what configuration?
I started again from the beginning and I got to the point 13 Launching APP start the home of simulator but without the App Baker I copied the folders red and assets (Point 1 and 2 customization) Then I launched the app again, to see the result with documents demo of Baker,
Error:Execution failed for task ':app:compileDebugJava'.
Compilation failed; see the compiler error output for details. /Users/----------/App_Android/baker-android-master/---------/app/src/main/java/--/----/----/----/---/MainActivity.java Error:(14, 32) error: cannot find symbol variable activity_main
Error:(22,41) error: cannot find symbol variable main
Checking the code I found the red error still: ...... In file AndroidManifest.xml android:label="@string/app_name" > ----Header expected Manifest file doesn't end with a final newline less... (⌘F1) Checks whether a manifest file ends with a final newline (as required by the JAR file specification). ---- ........ in file MainActivity setContentView(R.layout.activity_main); --- Cannot resolve symbol activity_main --- getMenuInflater().inflate(R.menu.main, menu); --- Cannot resolve symbol main ---
Hi @Marzio1
You are still having issues with the default main activity created by AS.. please check this again https://github.com/bakerframework/baker-android/wiki/Creating-your-own-Baker-Android-Project#cannot-find-symbol-variable-activity_main
Ok I go to delete all projects and Baker master and i restart
What went wrong: A problem occurred evaluating project ':ABaker'.
SDK location not found. Define location with sdk.dir in the local.properties file or with an ANDROID_HOME environment variable.
Try:
I managed to solve, but perhaps incorrectly you have a better method?
local.properties is a file that define values for your local environment only, if AS does not creates it... you can feel free to do it yourself.
What this is pointing, is that you need to define sdk.dir (path where your SDK is located) into your local properties so it can be found when sync.
But where is this file?
The file should be in your module root directory. Example (module name 'test') /project folder/test/local.properties
As a guidance you can find in
Ok thank you. The ./gradlew install is correct Now I go to create my project
Hello I got to the point 13 and I always have a red error in the file AndroidManifest.xml android:label="@string/app_name" > However,, the project ends successfully the run but in the simulator the Baker app does not appear
I see.. as seems there is an issue with the docs.. since you should not be able to run the project until you finish the "Customising your Baker Android Project" steps.
In the tutorial: Sync your gradle files. Run your project
I proceed with the customization and see what happens
I copied Assets and Res by Baker to My Project with the settings Baker
Error:Execution failed for task ':app:compileDebugJava'.
Compilation failed; see the compiler error output for details. /Users/xxxxxxxx/App_Android/baker-android-master/yyyyyyyyyy/app/src/main/java/it/edimg/cxauto/app/MainActivity.java Error:(14, 32) error: cannot find symbol variable activity_main
Error:(22, 41) error: cannot find symbol variable main
I'm a little disheartened If you want and if it helps I can provide a link to download the entire zipped project to analyze the errors
From what you've done I see you reach the same point when you need to update your main class as this suggest https://github.com/bakerframework/baker-android/wiki/Creating-your-own-Baker-Android-Project#cannot-find-symbol-variable-activity_main
I'm sorry the wiki is not good enough yet to help you build the project successfully but we have been updating it as people ask questions about how to build it.
I can surely check your project if you provide a link to download it, it is important to us you can build your project and verify our wiki to make things go smoother. Let me know.
Hello I started everything from the beginning , uninstalling and reinstalling Android Studio I then created a new project Baker following the new tutorial (with the Create Activity unchecked) I kept for the moment configurations Baker to try if it works with the demo publications As a first consideration it seems to me that the libraries proposed in the tutorials are not enough Certainly, the project required the library 11, but for safety I installed all the libraries and all the extras
Finally, in the project remains one red error in AndroidManifest.xml Always the same: android:label="@string/app_name" ALERT: Header expected - Manifest file doesn't and with a final newline Checks whether a manifest file with a final newline (as required by JAR file specification)
Waiting for device. "/Applications/Android Studio.app/sdk/tools/emulator" -avd MonoForAndroid_API_12 -netspeed full -netdelay none
Device connected: emulator-5554 Device is online: emulator-5554 Target device: MonoForAndroid_API_12 [emulator-5554] Uploading file local path: /Users/xxxxxxxxxxx/App_Android/baker-android-master/yyyyyyy/app/build/apk/app-debug-unaligned.apk remote path: /data/local/tmp/it.kkkkkkkk.zzzzzzz.app Installing it.kkkkkkkk.zzzzzzz.app DEVICE SHELL COMMAND: pm install -r "/data/local/tmp/it.kkkkkkkk.zzzzzzz.app" Error: Could not access the Package Manager. Is the system running?
I hope I was helpful
For the problem android:label="@string/app_name" The bulb of Android Studio suggest:
Hi @Marzio1 Im goin to publish a Video Tutorial today... mostly later tomorrow.. I hope it helps you solve this issue.
thanks I hope so too, because I want to finish soon I have not been able to verify the reading of the documents, but I hope it can be used the same shelf.json of iOS version
Hi @Marzio1 I published one of the videos on the wiki, you can find it on youtube here https://www.youtube.com/watch?v=hCMs80I1cx8
Hello Francisco
the video is perfect, and little different from the Text tutorial Now I created a new project following step by step exactly the video Tutorila and finally it work. The only little problem is that it is always a red warning in the AndroidManifest.xml file, at line android:label="@string/app_name" > But with emulator work Now I go to test all performances comparing with the iOS version
Thank You Very much
See... if rebuilding the project helps.. Let me know if we can close this ticket.
The project now works with the emulator. I have no chance to test it with an device, because I just iOS What leaves me doubtful is that persistent red error that could possibly create problems during compilation and inclusion in GooglePlay. I want to know if it happens only to me or not. But I hope you can solve this problem We can close this ticket. I bother you with new tickets for individual requests or problems using the app
Thanks that issue is common with Android Studio.. I have seen it .. and is just that sometimes its not able to find some resources for editing propose... I don't think it will cause any issue.
Either way let us know. Regards
I'm working and studying Baker Project to publish on iOS and GooglePlay Android For iOS I arrived at a good point and I've almost solved all the major problems.
For Android instead I started over again from the beginning, following the tutorial, but I was always stopped by the synchronization Gradle and I can not finish the setting of the project.
My system is: Mac OSX 10.9.2 Maverick Android 0.5.2 Study
JAVA JDK 1.7.0 or 1.8.0
This a Maven Version xxxxxxxxxxxxxxxx$ mvn --version Apache Maven 3.2.1 (ea8b2b07643dbb1b84b6d16e1f08391b666bc1e9; 2014-02-14T18:37:52+01:00) Maven home: /usr/local/Cellar/maven/3.2.1/libexec Java version: 1.8.0_05, vendor: Oracle Corporation Java home: /Library/Java/JavaVirtualMachines/jdk1.8.0_05.jdk/Contents/Home/jre Default locale: it_IT, platform encoding: UTF-8
OS name: "mac os x", version: "10.9.2", arch: "x86_64", family: "mac"
This is result ./gradlew install BUILD SUCCESSFUL
Total time: 38.998 secs
This is the error of Gradle
Gradle 'XXXXX' project refresh failed: Cannot invoke method repositories() on null object Gradle settings
BUILD .GRADLE file apply plugin: 'android'
android { compileSdkVersion 19 buildToolsVersion "19.0.3"
}
dependencies { compile 'com.android.support:appcompat-v7:+' compile fileTree(dir: 'libs', include: ['*.jar']) compile 'com.baker:ABaker:1.1' }
apply plugin: 'android' repositories { maven { url 'file://' + new File(System.getProperty('user.home'), '.m2/repository').absolutePath }
}
In the MAIN.ACTIVITY file some red errors the first error is import android.support.v7.app.ActionBarActivity;
with ActionActibity in red
In the ANDROIDManifest.xml after copy from Baker and replacement name package some red errors the first erro is: android:value="@integer/google_play_services_version" />
with @integer/google_play_services_version in red
I've seen that others have the same problem, so I think it is necessary to explain how to intervene to resolve
thank you very much