Scala on Android using Netbeans (preferably 6.8) - android

I have tried Scala on Android using various suggestions found on the Internet. However, I have never been able to get a "one-click" solution for Netbeans. Eventually I settled for Java + Eclipse. However, the urge to create Scala programs on Android persists.
Has anyone successfully used Netbeans IDE for Scala development for the Android platform? And that too using the IDE's build tools?
Ideally the following features are needed:
Scala code completion, syntax highlighting, error checking (as in NB-6.8 + Scala 2.8)
Automatic deployment on Android using one-click
No messing around with Proguard config
No messing around with signing of the jars/apks
Please post a step-by-step guide if this is possible, or please link to an external page giving details.

Have you tried the new eclipse plugin? Those are a major improvement from a few month ago. There should be versions for 2.9.1 and (if you need scala 2.8 ) Scala 2.8.2 see www.scala-ide.org

Related

Is it possible to run the same source code in eclipse and android studio?

I am new to android development, So I am not sure if this question is very silly
I was wondering if the same source code can run in both eclipse and android studio
If this is possible how to do it, and what points should be considered?
If not what are the road blocks to accomplish this.
Simple answer: Yes, you can "write" (not run) in both IDE's.
Aside: You really don't even need an IDE. If using Gradle, you can write code using any text-editor, then compile, build, test, and install all using Gradle.
If this is possible how to do it?
Well, Android Studio can import Eclipse projects. That is pretty well documented.
Eclipse (unofficially) has an Andmore project and also supports Gradle projects.
what are the road blocks to accomplish this
If using Eclipse, it's not supported by the Android team anymore, and you'll likely be missing out on features that are actively added to Android Studio.

How to use Android Studio with Cocos2d-x

I work as an android programmer for just under a year now, and I just started to learn about android game development. The framework I choose to work with is Cocos2d-x.
I have seen guides and tutorials on how to use Cocos2d-x with eclipse, but I'd really like to know if it's possible to be used with Android Studio.
From what I've read, it is now possible to build NDK projects with gradle in Android Studio, which is good news. Nevertheless, I have yet to find any information about C++ programming using Android Studio. Eclipse uses the CDC ( https://www.eclipse.org/cdt/ ) plugin to achieve this.
Is there anything similar to be used with Android Studio? I have found some C/C++ enabling plugins for the IntelliJ Platform, but they were no longer updated.
Has anyone else tried this before? Did it work? Can you provide a step-by-step guide, for a newbie like me, who's dealing with this kind of problems for the first time?
Thank you for you time,
haxm
Android Studio currently isn't well set-up for native programming. While the build system supports the NDK, there's no editor support for C++ files (it's not as if it won't work, but the IDE won't give you any editing assistance), and neither is there any debugging support. JetBrains has announced that they're working on new C++ support for IntelliJ, and this is something we're looking at for Android Studio, but it's not on the roadmap yet.
Recent version of cocos2dx v3 (from github for example)
have proj.android-studio project
At this moment I have no success to build it but maybe in future it will be fixed
I just went through the setup for this example code. The project compiles and has a ton of sample code. Scott Barta's answer still stands as an important caveat, but wanted to share the link in case it was useful.
I also found this useful for some NDK background/how-to.

How to install new Android Studio extensions to IntelliJ IDEA

Is it possible at the moment to add the Android Studio extensions to a current IntelliJ IDEA installation?
Xavier Ducrohet and Tor Norbye mentioned in their talk, that Android Studio is an extension to the Community Edition of IntelliJ IDEA and that it's not a fork. So it should be possible to add the extension.
Is there an easy way to do so and probably to revert?
They also mentioned in their talk, that Android Studio uses Gradle as default build system. This should break the builds of current modules. Is this correct?
Thanks for the answers, but I finally found the corresponding statement by JetBrains: http://blog.jetbrains.com/blog/2013/05/15/intellij-idea-is-the-base-for-android-studio-the-new-ide-for-android-developers/
You can upgrade by hitting help -> Checking for updates and then choose Early Access Program as channel in the Update settings. You should receive a notification, that version 13 is available.
This EAP version contains almost all Android Studio features except the new Project Wizard and the App Engine Cloud Endpoints, but they will come soon. The reason for the delay is the Google IO, in the future new Android Studio and IntelliJ versions will be synced (mentioned in the comments of the blog post).
I guess it will be at androidstudio but the project is currently empty.
The installation page is here: Android Studio.
From what I understand in the download page & from what they said in the conference, it's a stand alone IDE based on the intelliJ, but i'm skeptical to whether one can get it as an extension to an already installed intelliJ IDEA.
About the build - in Migrating from Eclipse page they explain how to generate Gradle build files for your projects in Eclipse and then import those projects to Android Studio. It's pretty simple and straight forward.

Scala, Android and Eclipse

I've started learning Scala, and I... I think I'm in love. I've only coded small test snippets so far, but since I currently working in Android development, what I really want to do is try my hand at writing Android applications in Scala.
I've found articles and questions on the matter, but mostly referring to older versions of the three tools (Android SDK/Scala/Eclipse), so the general question is:
Is anybody coding Android apps in Scala right now, with the latest SDK, Scala 2.9 and Eclipse Indigo? How viable is it?
And, in particular:
How's the interaction/integration between Scala's features and the Android library?
What's the state of the Scala plugin for Eclipse? I've read all the features you'd expect are there, but I'd like to know first-hand stories, specially about the debugger.
How well does the build process (scala to java to dalvik, ant, proguard, etc.) automate?
Thanks!
We are using Scala heavily to test our Android code - you can read a writeup of how we're doing so here. We use Ant or SBT to compile - there's an excellent SBT plugin for Android development.
Having said all of that, I'm not sure that I would recommend Scala for production Android development. In particular Scala 2.9.x is basically unusable as there is no good way to get the libraries to work on Android. You can read about the issue here.
It's a real pity, as Android development would benefit considerably from Scala if we could get it working properly.
Solution found here to use the latest Android SDK, with Eclipse 3.7.2 and Scala 2.9 :
https://stackoverflow.com/a/11084146/1287856
It completely handles the android library
You can make Android Library out of scala projects as usual
The build process is completely automated, including proguard-ing and exporting the project with the regulard Android tools.
I started to implement the android application (a twitter client) from the book "Learning Android" with Scala 2.9.0-1 a while ago.
In my opinion you can use it. I had only one problem with the parameter list at AsyncTask (see this link, problem #3).
If you want to checkout out the project, you can find it here.
This video from ScalaDays 2011 may be hepful:
Scala on Android: Real-world Experience at Bump Technologies by Michael Galpin
EDIT:
If you really really want to run Scala code on Android (and not really make an app, but for yourself), then I have an easier solution. It depends on if your phone supports the procedure. In summary the steps are:
Install Ubuntu on your device (as described here). This will not affect the Android installation.
Boot Ubuntu, install JDK, Scala, etc, copy your Scala jars and run from there.

android scala and eclipse

I tried following the instructions here link text to make a scala application. However when I run the "ant install" command I get the following error
aaptexec doesn't support the "basename" attribute
I read this is because of the new sdk 7 version here. However noone on that thread seems to offer any solution.
Has anyone tried to do this with the new sdk?
Thanks in advance
You may take a look at Building Android apps in Scala with sbt, I found it is much easier to use SBT to build Scala/Andoird application than Eclipse.
You should also use https://github.com/steve918/android-plugin instead of the plug-in describe at the page if you want use latest Android SDK.
http://code.google.com/p/treeshaker/ may be what you're looking for.
It's a build step for Eclipse which, used together with Scala IDE, will enable you to use Scala on Android.
Solution found here to use the latest Android SDK, with Eclipse 3.7.2 and Scala 2.9 :
https://stackoverflow.com/a/11084146/1287856
It compiles under Android SDK 18
It does not have the strange side-effects of Treeshaker like forgetting to include some classes.

Categories

Resources