de-jcup / eclipse-asciidoctor-editor

An eclipse editor for asciidoctor files
https://marketplace.eclipse.org/content/asciidoctor-editor
Other
58 stars 15 forks source link

Provide Maven build of plugin #371

Open de-jcup opened 3 years ago

de-jcup commented 3 years ago

Situation

The gradle build does not build eclipse parts but only the "normal" parts. Reason: Problems with eclipse dependencies, OSGI etc.

Wanted

Automate the complete build process.

Solution

If we change the build to maven tycho we could completely automate the process

de-jcup commented 3 years ago

@vogella : Maybe you could help here?

vogella commented 3 years ago

Absolutely.

de-jcup commented 3 years ago

Here some pre-requisites :

Some additional information:

Something I would appreciate:

vogella commented 3 years ago

The plan is to replace the Gradle build with Maven or do you plan to keep both?

vogella commented 3 years ago

Please see https://github.com/de-jcup/eclipse-asciidoctor-editor/pull/372 for the initial setup. For the necessary libraries, I would not know where to search them. If they are available via Maven central you can add them to the target platform via M2e integration, see here https://www.vogella.com/tutorials/EclipseJarToPlugin/article.html

I hope this help, I don't think I would be very efficient trying to add the libs. Can you handle that?

de-jcup commented 3 years ago

@vogella : Thank you very much. I will check the PR and tryout to add the libs etc. If I have still questions I will ask you then.

vogella commented 3 years ago

Sure and thanks. Adding more plug-ins is just a question of adding path to the pom.xml. It is a bit more complex for test plug-ins. Once the libs are there, I can do this. Maybe we can do this in your repo directly in a branch? Could you give me write access?

de-jcup commented 3 years ago

The plan is to replace the Gradle build with Maven or do you plan to keep both?

de-jcup commented 3 years ago

Sure and thanks. Adding more plug-ins is just a question of adding path to the pom.xml. It is a bit more complex for test plug-ins. Once the libs are there, I can do this. Maybe we can do this in your repo directly in a branch? Could you give me write access?

I just invited you.

de-jcup commented 3 years ago

Just as an information: My eclipse commons library is currently directly added into GIT. With https://github.com/de-jcup/eclipse-asciidoctor-editor/issues/373 this will become a maven dependency as well. The library is just one central library to "not reinvent the wheel" and is used in most of my eclipse plugins.

de-jcup commented 3 years ago

https://github.com/de-jcup/eclipse-asciidoctor-editor/pull/372 is the first step but PR will not close this issue, so removed the former link.

vogella commented 2 years ago

Any news with asp-server-asciidoctorj-launcher-dist.jar? It is required by de.jcup.asciidoctoreditor and IIRC you were planning to add it to Maven? Alternative you could also add the JAR to the the lib folder so that we can continue with the update of the build and remove it later once you moved it to Maven central.

de-jcup commented 2 years ago

Any news with asp-server-asciidoctorj-launcher-dist.jar? It is required by de.jcup.asciidoctoreditor and IIRC you were planning to add it to Maven? Alternative you could also add the JAR to the the lib folder so that we can continue with the update of the build and remove it later once you moved it to Maven central.

Hello @vogella , sorry for the late response, was very busy. I just created https://github.com/de-jcup/asp/issues/39 to address the problem.

de-jcup commented 2 years ago

Hello Lars, I fixed the problem with #376 - which is already merged to master. There were multiple problems, but now the gradle build works again.

de-jcup commented 2 years ago

@vogella : The main topic of the gradle build fix is to use not asp* dependencies of version 1.3.0 but 1.3.1. I did not deploy 1.3.0 at maven central, but only 1.3.1

vogella commented 2 years ago

I'm a bit confused. What do we want to do as a next step?

vogella commented 2 years ago

@de-jcup any updates from your side?

de-jcup commented 2 years ago

Update:

I have added the dependencies as PDT dependencies in last commits,, but there are still some problems. For example: https://mvnrepository.com/artifact/de.jcup.asp/asp-server-asciidoctorj/1.3.1 contains the ASP server and has a runtime dependencies (e.g. asciidoctorj, asciidoctorj-pdf, ... more). The problem here is, that PDT maven dependencies does only show up/ handle compile dependencies.

vogella commented 2 years ago

@de-jcup anything left here?

de-jcup commented 2 years ago

There are still some steps to do:

vogella commented 2 years ago

We must reintegrate the library plugin to the maven build

As we source from Maven only changed parts will be included in the new build and downloaded.

Currently at runtime the ASP lauch mechanism will not work

If the server is part of the classpath of the plugin you can start it directly from the plug-in

de-jcup commented 2 years ago

I want to separate the download not for development, but for the users (update time)

For example: I released V2.5.0 of the editor plugin (old style with gradle) some days ago with library plugin 2.4.0 dependency which contains ASP 1.4.1

Some hours ago I fixed a serious bug and released V2.5.1 which uses again library plugin 2.4.0

Because the only changes were done inside the editor plugin the users only needed to download ~ 1 MB for the editor plugin and not ~ 50 MB with the complete ASP server.

So this means

vogella commented 2 years ago

Still don't understand. If the Maven dependencies are not updated they will also not be updated hence you will not see big updatesd if you only update the core plug-in

de-jcup commented 2 years ago

Remark: The former two commits did also merge the current master (containing changes for 3.0.0) into this branch.

vogella commented 12 months ago

Consumption of Maven libraries via the Tycho build is now also common practice for the platform build and all of my clients. As soon as the libraries are available via Maven central building this plug-in via Maven Tycho is trivial.

de-jcup commented 8 months ago

@vogella : I am still running out of time and I did invest much time to get it working in any way (and failed). Currently I cannot work on it.

vogella commented 8 months ago

No worries we all have time restrictions. If all lib requirements would be at Maven central or a P2 update site setting up a Tycho build would be trivial and I could provide it.

Maybe providing a P2 repo for the dependencies would be possible in the future.