Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[RFE#1714] chore: build languagetool as modules #741

Merged

Conversation

miurahr
Copy link
Member

@miurahr miurahr commented Sep 7, 2023

Languagetools language libraries are optional for OmegaT application.
This proposal changes these libraries as module.

In future, we will distribute these modules as optional plugin packages when #226 merged.

Pull request type

  • Build and release changes -> [build/release]

Which ticket is resolved?

What does this PR change?

  • Form subproject languagetools
  • produce modules that names are omegat-language-XX.jar in build/modules

Other information

dev-ML discussion suggests

There is about 300MB with dependencies. We change core dependnecies such as LanguageTools and Apache Lucene.

LanguageTool 3.5 takes 65MB, and LanguageTool 5.7 takes 129MB.

Would it be possible to download LanguageTools separately (from within OmegaT) ?

LanguageTool in not a core OmegaT function. A lot of languages do not have use for it.

For first users, we could have a dialog that says "if you use such and such language, install LanguageTool to have access to grammatical... checks" and provide a link.

Lucene is a core function but not all languages have specific tokenizers, so here again, it there is a need to download the whole thing, do something similar for users who could benefit from Lucene.

Signed-off-by: Hiroshi Miura <miurahr@linux.com>
Signed-off-by: Hiroshi Miura <miurahr@linux.com>
Signed-off-by: Hiroshi Miura <miurahr@linux.com>
@miurahr miurahr marked this pull request as ready for review September 8, 2023 00:06
@miurahr
Copy link
Member Author

miurahr commented Sep 8, 2023

Review points file languagetools/build.gradle

  • Plugin name and description template
  • Language name

@miurahr
Copy link
Member Author

miurahr commented Sep 8, 2023

Would it be possible to download LanguageTools separately (from within OmegaT) ?

To allow download LT separately, #226 is required.

@miurahr
Copy link
Member Author

miurahr commented Sep 8, 2023

TODO:

  • Bundle language libraries in source distribution. currently only core library is there.

Signed-off-by: Hiroshi Miura <miurahr@linux.com>
Copy link
Contributor

@Kazephil Kazephil left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I spotted a few typos.

build.gradle Outdated Show resolved Hide resolved
languagetools/build.gradle Outdated Show resolved Hide resolved
languagetools/build.gradle Outdated Show resolved Hide resolved
and add comment line for string match stratgy

Signed-off-by: Hiroshi Miura <miurahr@linux.com>
@miurahr miurahr changed the title chore: build languagetool as modules [RFE#1714] chore: build languagetool as modules Sep 9, 2023
Copy link
Contributor

@Kazephil Kazephil left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me now.

@miurahr
Copy link
Member Author

miurahr commented Sep 11, 2023

I found that a source distribution has unwanted library jar files. It may be caused by a filter of "*RuntimeClasspath" that may include dependencies of Gradle plugins such as SpotBugs dependency.
It breaks build process of source distribution.

@miurahr
Copy link
Member Author

miurahr commented Sep 11, 2023

I found that a source distribution has unwanted library jar files. It may be caused by a filter of "*RuntimeClasspath" that may include dependencies of Gradle plugins such as SpotBugs dependency. It breaks build process of source distribution.

This caused from dependency jStyleParser library. I'd like to fix the issue in another PR.

@miurahr miurahr merged commit 7a3a77f into omegat-org:master Sep 11, 2023
3 checks passed
@miurahr miurahr deleted the topic/miurahr/languagetool/module-optionals branch September 11, 2023 14:08
miurahr added a commit that referenced this pull request Oct 7, 2023
This reverts commit 7a3a77f.

There is a report that modularize of langaugetool does not work.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants