Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to build template project for Android Studio

I work with Android Studio. I have to create many projects alway with three modules:

  • app (application)
  • library (library)
  • wallpaper (application)

I know that is possibile to use ADT to build Activity Templates, etc. I found some tutorial like this and this, but they talk about activity template, no project with modules template.

Are there good tutorial around to create Project template for Android Studio directly with the structure i need?

Which IDE can i use to manage template like a project (content assistant, etc)?

like image 615
xcesco Avatar asked Sep 26 '22 15:09

xcesco


1 Answers

Yes you can, but it is nothing different than building an Activity Template.

Have a look in the folder android-studio/plugins/android/lib/templates/activities. And more specifically in the MasterDetailFlow template. You see that you can add an arbitrary amount of activities, resources and layouts in your template. So the templates are not limiting you from creating a whole project as a template project.

In each of the files you can use the variables defined in the globals.xml.ftl.

like image 172
Bas van Stein Avatar answered Sep 30 '22 00:09

Bas van Stein