From 948ff4c609da3797a240a24a2f97314638b07b17 Mon Sep 17 00:00:00 2001 From: Oliver Kopp Date: Fri, 13 May 2022 08:57:40 +0200 Subject: [PATCH] Workaround for buildSrc:jar issue --- buildSrc/build.gradle | 7 +++++++ .../guidelines-for-setting-up-a-local-workspace.md | 7 ++++--- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/buildSrc/build.gradle b/buildSrc/build.gradle index e5e1d0fb399..43eb84d3cb2 100644 --- a/buildSrc/build.gradle +++ b/buildSrc/build.gradle @@ -18,3 +18,10 @@ sourceSets{ } } } + +/** + * This is a workaround for Entry org/jabref/build/JournalAbbreviationConverter$_convert_closure1$_closure2.class is a duplicate but no duplicate handling strategy has been set. + * + * Source: https://github.com/gradle/gradle/issues/17236#issuecomment-923074298 + */ +tasks.getByName("jar").setProperty("duplicatesStrategy", DuplicatesStrategy.EXCLUDE); diff --git a/docs/getting-into-the-code/guidelines-for-setting-up-a-local-workspace.md b/docs/getting-into-the-code/guidelines-for-setting-up-a-local-workspace.md index a6f11b2c4bc..dd8ff6ee03c 100644 --- a/docs/getting-into-the-code/guidelines-for-setting-up-a-local-workspace.md +++ b/docs/getting-into-the-code/guidelines-for-setting-up-a-local-workspace.md @@ -351,10 +351,11 @@ If that does not help: 4. Execute `./gradlew run` 5. Start IntelliJ and try again. -### Issue with org/jabref/build/JournalAbbreviationConverter$\_convert\_closure1$\_closure2.class is a duplicate but no duplicate handling strategy has been set +### Issue with `_closure2.class is a duplicate but no duplicate handling strategy has been set` After changing the contents of `build.gradle`, on might get following error: -`Entry org/jabref/build/JournalAbbreviationConverter$_convert_closure1$_closure2.class is a duplicate but no duplicate handling strategy has been set.` + Entry org/jabref/build/JournalAbbreviationConverter$_convert_closure1$_closure2.class is a duplicate but no duplicate handling strategy has been set. -Currently, no "real" solution is known. One has to start from scratch (`git clean -xdf`, ...). +Please update to the latest development code. +We applied the workaround from .