Home Download Buy Blog Forum Support

SublimeAndroid

SublimeAndroid

Postby dskinner on Sun Dec 02, 2012 8:42 am

There's various plugins around related to android development in sublime. One thing that was seemingly lacking (or at least I hope I didn't overlook it) is xml autocompletion for android layouts. So that has been my main focus with https://github.com/dskinner/SublimeAndroid

I'm still fairly new to sublime (under a month of use) but some other things I'd like to add are sane defaults for external packages related solely to android projects along with standard build configurations (or push changes upstream to SuperAnt to catch targets included externally).

SublimeAndroid is not currently in PackageControl as I've only made my first commit, and only lightly tested on xml layouts. Assuming you've configured a project with:

Code: Select all
android update project -p ./


And the project root is one of your project folders, SublimeAndroid should be able to identify your sdk directory along with target sdk and provide tag, attribute, and value autocompletions. For example, `<Image` will suggest `ImageView`. `android:scale` will suggest `scaleType` and then further prompt for scaleType options such as `matrix`, `fitXY`, etc.

If you're bored and want to hack on something, feel free to hack on this :) Until then, I'll post another announcement once it's a little more feature-filled and in PackageControl.
dskinner
 
Posts: 9
Joined: Sat Nov 17, 2012 4:34 am

Re: SublimeAndroid

Postby dskinner on Wed Dec 05, 2012 12:01 pm

Latest Features:
    * XML Layout Autocompletion
    * Emulator/Device instance selection where applicable
    * Auto configure external plugins for android project, including:
      * SublimeJava
      * SublimeLinter
      * ADBView
    * Window Commands to build and run application
      * `Android: Build` command. Build standard ant targets listed in the sdk's build.xml and your own custom targets
      * `Android: Run` command that conveniently builds, deploys, and runs application on target device
    * Auto build project in background to keep classpaths fresh for autocomplete, autoimport, and lint
    * Settings to configure the above behaviour where applicable
dskinner
 
Posts: 9
Joined: Sat Nov 17, 2012 4:34 am

Re: SublimeAndroid

Postby tito on Thu Dec 06, 2012 11:19 am

Will need to check this! Thanks a lot! Eclipse is a nice IDE, but a very bad text editor.
Give APIs, let the community build the rest!
https://github.com/titoBouzout
tito
 
Posts: 850
Joined: Thu Sep 29, 2011 2:27 pm
Location: Montevideo, Uruguay

Re: SublimeAndroid

Postby tito on Sat Dec 08, 2012 3:24 am

For some reason.. after installing this package I can't open a python file. the file is https://github.com/SublimeText/Tag/blob ... ag_lint.py
Give APIs, let the community build the rest!
https://github.com/titoBouzout
tito
 
Posts: 850
Joined: Thu Sep 29, 2011 2:27 pm
Location: Montevideo, Uruguay

Re: SublimeAndroid

Postby dskinner on Mon Dec 10, 2012 3:12 pm

Hey,

I'd highly suggest anyone with issues file a report on the github issue tracker as I'll be notified immediately.

https://github.com/dskinner/SublimeAndr ... state=open

The initial state of the plugin caused it to try and do stuff for any file opened and I ran across multiple issues with it literally locking up the text editor when working on python and go projects.

The latest version of the plugin should resolve this as it checks appropriately if it's dealing with an actual android project. The latest version has a submodule dependency now for managing external dependencies (which currently creates a hard dependency on Package Control). If this is a fresh clone, use

Code: Select all
git clone --recursive git://github.com/dskinner/SublimeAndroid.git


Otherwise if updating from previous,

Code: Select all
git pull
git submodule init
git submodule update
dskinner
 
Posts: 9
Joined: Sat Nov 17, 2012 4:34 am

Re: SublimeAndroid

Postby rharter on Mon Jan 21, 2013 5:40 pm

Forgive me for the naive question, but I'm new to Sublime Text. I realize that these questions are not necessarily SublimeAndroid specific, but I can't seem to find documentation that helps with this. If there is general "working with (not developing) plugins" documentation I would certainly love a link.

Can you please give me a very quick intro on how to use this plugin? There are a few particular things I'm looking for.

1. How do I auto-configure my other plugins? Specifically I want to configure SublimeJava for the Android SDK but using the command palette (command-shift-p) I can't seem to find any of the "Android: ..." commands.

2. When running build with the Build System set to SublimeAndroid, I get "Unable to find target command: android_ant_build" in the console.

I've installed SublimeAndroid with the following commands:

$ cd ~/Library/Application\ Support/Sublime\ Text\ 2/Packages/
$ git clone --recursive git://github.com/dskinner/SublimeAndroid.git
rharter
 
Posts: 1
Joined: Mon Jan 21, 2013 5:36 pm

Re: SublimeAndroid

Postby nctusdk on Thu Feb 07, 2013 3:11 am

rharter wrote:Forgive me for the naive question, but I'm new to Sublime Text. I realize that these questions are not necessarily SublimeAndroid specific, but I can't seem to find documentation that helps with this. If there is general "working with (not developing) plugins" documentation I would certainly love a link.

Can you please give me a very quick intro on how to use this plugin? There are a few particular things I'm looking for.

1. How do I auto-configure my other plugins? Specifically I want to configure SublimeJava for the Android SDK but using the command palette (command-shift-p) I can't seem to find any of the "Android: ..." commands.

2. When running build with the Build System set to SublimeAndroid, I get "Unable to find target command: android_ant_build" in the console.

I've installed SublimeAndroid with the following commands:

$ cd ~/Library/Application\ Support/Sublime\ Text\ 2/Packages/
$ git clone --recursive git://github.com/dskinner/SublimeAndroid.git


Same here, it says "Unable to find target command: android_ant_build"...
Anyone?
nctusdk
 
Posts: 1
Joined: Thu Feb 07, 2013 3:09 am


Return to Plugin Announcements

Who is online

Users browsing this forum: Yahoo [Bot] and 13 guests