0

I am an experienced Java developer with years of familarity with Eclipse and Maven.

My goal is to create an android application and I am getting familiar with the latest Development environment Android Studio 2.3.2 which obviously uses Java 8 and Gradle. The app shall share code with an Eclipse based project that uses maven and Swing and is also Java 8 based. I am intending to publish the result as an open source project on github.

I found e.g.

How feasible is a combined maven/gradle project structure?

What would be a proper way to structure the project files to accomplish the above goals?

What are good examples projects that follow a similar approach?

My reason to be reluctant with Gradle and IntelliJ is obvious. It is an unfamiliar environment for me and android is not the main target of my development.

Community
  • 1
  • 1
Wolfgang Fahl
  • 15,016
  • 11
  • 93
  • 186
  • Gradle provides the same features as Maven. Eclipse can work with Gradle... So why do you need Maven? And why do you need Eclipse? Just use Intellij / Android Studio – OneCricketeer May 19 '17 at 09:06
  • thx for your comment - so you are suggesting to only use one gradle layout? Please supply a link to an example structure or project with the shared code approach for a Swing Application and Android App. e.g. as in http://stackoverflow.com/questions/38760041/gradle-project-for-plain-java-and-android-with-single-source-tree – Wolfgang Fahl May 19 '17 at 09:09
  • You just start a new Gradle module with `apply plugin: 'java'` for the swing code. I don't have a link other than the official Gradle documentation for the Java plugin – OneCricketeer May 19 '17 at 09:13

1 Answers1

0

Part of the answer seems be covered at:

Can Android Studio be used to run standard Java projects?

I got somewhat of a success with the project https://github.com/BITPlan/can4eve but would appreciate some help on the android studio / gradle side of things.

The project also has travis support built in and I am also running nightly Jenkins checks based on maven.

Wolfgang Fahl
  • 15,016
  • 11
  • 93
  • 186