-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
[WIP] Multi module build #3704
Closed
Closed
[WIP] Multi module build #3704
Changes from 1 commit
Commits
Show all changes
90 commits
Select commit
Hold shift + click to select a range
fc626a6
Initial gradle build files
koppor a0b1397
Result of linter
koppor 83b74c8
Fix linter
koppor 86714e9
Create org.jabref.logic package (besides logic.shared and logic.remote)
koppor f23e579
Ignoure out directory
koppor ae1102b
Three more classes for logic
koppor fd3ffa2
Seperate logic from GUI
koppor fa1536f
Refactor OpenOffice preferences
koppor 68335c9
autosave and backup read config from preferences at each event -> kee…
koppor 1ee315a
Refactor CleanupPreset
koppor 4b7ea7d
Make ModsImporter independent from JabRefPreferences
koppor 2ba26da
FileAnnotationCache needs fileDirectoryPreferences
koppor 7dfe2ed
Some compile fixes
koppor b889fed
lint build.gradle
koppor df4ef0d
Fix install4j location
koppor 2f52b51
Merge remote-tracking branch 'origin/master' into multi-module-build
koppor a46d569
Move jabref.install4j to right folder
koppor 9646887
Move model tests from gui to model/logic
koppor 76c1d29
Duplicate TreeNodeTestData, because test data is not shared across mo…
koppor 8903b26
lint build.gradle files
koppor 2f2e81e
Move logic tests from org.jabref.gui org.jabref.logic
koppor 4afbb8b
Fix bibtexTestData location
koppor 9b5e1f8
Remove GenerateCharacterTable - it was never published officially
koppor 4fec000
Create org.jabref.cli.xmp project
koppor abbe777
Fix location of test resources
koppor ab37471
Fix locations of DatabaseTest
koppor 7e620f7
Fix location of ImportDataTest
koppor 40c6bf7
Remove strange CLI tests also testing logic
koppor e88de4f
Replace one straight-forward assertEqualsBibtexEntry
koppor 2435aff
Fix module of BackupManagerTest
koppor 6594f68
Remove dependency to JabRefMain
koppor dce1afd
Fix location of test files
koppor c6890d8
lint build.gradle
koppor 7481fb6
Inline SavePreferencesFactory to JabRefPreferences
koppor d4b2e9a
Fix package of FallbackExceptionHandler
koppor 211caad
Compilefix
koppor 25dae4b
Merge remote-tracking branch 'origin/master' into multi-module-build
koppor e963a6f
Switch from com.airhacks:afterburner.fx to jabref's afterburner.fx
koppor 1013a36
Fix import
koppor 14548e8
Add missing checkstyle files
koppor d7abe22
Fix location of *.css *.fxml --> resource is the key
koppor f821561
Integrate CodeStyleTest into StringUtilTest
koppor 20d17ce
Add required mock to LinkedfileViewModelTest
koppor cf5ad67
Remove generated files
koppor 8fcbf70
Move checkstyle
stefan-kolb 4e13152
Revert "Fix location of *.css *.fxml --> resource is the key"
koppor 49c24c3
Modernizer
stefan-kolb e505ea4
Merge branch 'multi-module-build' of https://github.com/JabRef/jabref…
stefan-kolb 2f93792
Fix source sets
koppor de57cf3
Add LinkedFileViewModelTest to classes which may use Globals
koppor a630326
Merge remote-tracking branch 'origin/master' into multi-module-build
koppor 0352c00
Move more stuff
stefan-kolb f2f2f7a
Java compilation
stefan-kolb 3848e51
Merge branch 'multi-module-build' of https://github.com/JabRef/jabref…
stefan-kolb 5465fe1
Merge remote-tracking branch 'origin/master' into multi-module-build
koppor e738086
Dev replacements
stefan-kolb fe6e2c5
Revert "Add LinkedFileViewModelTest to classes which may use Globals"
koppor 2615756
Unused imports
stefan-kolb 073ba4a
Merge branch 'multi-module-build' of github.com:JabRef/jabref into mu…
koppor a933d52
XMP dependencies
stefan-kolb 5d7e766
XMP build
stefan-kolb 214625d
Move stuff
stefan-kolb 392dc7c
Merge branch 'multi-module-build' of github.com:JabRef/jabref into mu…
koppor e115a9d
Fix path in CircleCI upload script
koppor 9ec6cfe
Remove obsolete scripts (was hosted at https://github.com/jabref/htdocs)
koppor ac35918
Move dev switch to org.jabref.gui
koppor 266c7b8
Enable build scan
koppor 5d258f8
Fix location of binaries
koppor 9c54c3c
Add missing checkstyle configuration
koppor e91ebaa
Include changes of https://github.com/JabRef/jabref/pull/3659
koppor 3818f10
Remove "modernizer" also from Travis build
koppor 8064843
Load buildscan first
koppor 8ebd604
Fix build. a) dir b) name
koppor 5058b36
Reenable JUnit tests by global dependencies
koppor e4e9e86
Restructure, update Install4J
koppor 0c96e14
Update gradle from 4.5 to 4.5.1
koppor ca05215
Fix iconpath (again)
koppor 13b85df
Fix artifacts path
koppor ff6f440
Better 9 binaries than nothing
koppor 297b225
Merge remote-tracking branch 'origin/master' into multi-module-build
koppor 9145feb
Fix file paths
koppor 265507d
Compile fix and migrate OAI2HandlerFetcherTest @Ignore to JUnit5 @Dis…
koppor 7c8b761
Fix Install4J build
koppor 2985d71
Fix build on CircleCI
koppor 17e9969
Merge remote-tracking branch 'origin/master' into multi-module-build
koppor 92cf1a3
No daemon at CircleCI
koppor de4a574
Initial compilation also is a development build
koppor 9bfea57
Replace Project.getRootProject() by rootProject
koppor a1deb36
Fix test
koppor 8029a3f
Merge branch 'master' into multi-module-build
koppor File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
org.jabref.gui/src/main/java/org/jabref/preferences/ExporterFactoryFactory.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
package org.jabref.preferences; | ||
|
||
import org.jabref.logic.exporter.ExporterFactory; | ||
import org.jabref.logic.exporter.SavePreferences; | ||
import org.jabref.logic.exporter.TemplateExporter; | ||
import org.jabref.logic.journals.JournalAbbreviationLoader; | ||
import org.jabref.logic.layout.LayoutFormatterPreferences; | ||
|
||
import java.util.Map; | ||
|
||
public class ExporterFactoryFactory { | ||
|
||
public static ExporterFactory create(JabRefPreferences preferences, JournalAbbreviationLoader abbreviationLoader) { | ||
Map<String, TemplateExporter> customFormats = preferences.customExports.getCustomExportFormats(preferences, abbreviationLoader); | ||
LayoutFormatterPreferences layoutPreferences = preferences.getLayoutFormatterPreferences(abbreviationLoader); | ||
SavePreferences savePreferences = SavePreferencesFactory.loadForExportFromPreferences(preferences); | ||
return ExporterFactory.create(customFormats, layoutPreferences, savePreferences); | ||
} | ||
|
||
} |
47 changes: 47 additions & 0 deletions
47
org.jabref.gui/src/main/java/org/jabref/preferences/SavePreferencesFactory.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
package org.jabref.preferences; | ||
|
||
import org.jabref.logic.bibtex.LatexFieldFormatterPreferences; | ||
import org.jabref.logic.exporter.SavePreferences; | ||
import org.jabref.model.bibtexkeypattern.GlobalBibtexKeyPattern; | ||
import org.jabref.model.metadata.SaveOrderConfig; | ||
|
||
import java.nio.charset.Charset; | ||
|
||
public class SavePreferencesFactory { | ||
|
||
public static SavePreferences loadForExportFromPreferences(JabRefPreferences preferences) { | ||
Boolean saveInOriginalOrder = preferences.getBoolean(JabRefPreferences.EXPORT_IN_ORIGINAL_ORDER); | ||
SaveOrderConfig saveOrder = null; | ||
if (!saveInOriginalOrder) { | ||
if (preferences.getBoolean(JabRefPreferences.EXPORT_IN_SPECIFIED_ORDER)) { | ||
saveOrder = preferences.loadExportSaveOrder(); | ||
} else { | ||
saveOrder = preferences.loadTableSaveOrder(); | ||
} | ||
} | ||
Charset encoding = preferences.getDefaultEncoding(); | ||
Boolean makeBackup = preferences.getBoolean(JabRefPreferences.BACKUP); | ||
SavePreferences.DatabaseSaveType saveType = SavePreferences.DatabaseSaveType.ALL; | ||
Boolean takeMetadataSaveOrderInAccount = false; | ||
Boolean reformatFile = preferences.getBoolean(JabRefPreferences.REFORMAT_FILE_ON_SAVE_AND_EXPORT); | ||
LatexFieldFormatterPreferences latexFieldFormatterPreferences = preferences.getLatexFieldFormatterPreferences(); | ||
GlobalBibtexKeyPattern globalCiteKeyPattern = preferences.getKeyPattern(); | ||
return new SavePreferences(saveInOriginalOrder, saveOrder, encoding, makeBackup, saveType, | ||
takeMetadataSaveOrderInAccount, reformatFile, latexFieldFormatterPreferences, globalCiteKeyPattern); | ||
} | ||
|
||
public static SavePreferences loadForSaveFromPreferences(JabRefPreferences preferences) { | ||
Boolean saveInOriginalOrder = false; | ||
SaveOrderConfig saveOrder = null; | ||
Charset encoding = preferences.getDefaultEncoding(); | ||
Boolean makeBackup = preferences.getBoolean(JabRefPreferences.BACKUP); | ||
SavePreferences.DatabaseSaveType saveType = SavePreferences.DatabaseSaveType.ALL; | ||
Boolean takeMetadataSaveOrderInAccount = true; | ||
Boolean reformatFile = preferences.getBoolean(JabRefPreferences.REFORMAT_FILE_ON_SAVE_AND_EXPORT); | ||
LatexFieldFormatterPreferences latexFieldFormatterPreferences = preferences.getLatexFieldFormatterPreferences(); | ||
GlobalBibtexKeyPattern globalCiteKeyPattern = preferences.getKeyPattern(); | ||
return new SavePreferences(saveInOriginalOrder, saveOrder, encoding, makeBackup, saveType, | ||
takeMetadataSaveOrderInAccount, reformatFile, latexFieldFormatterPreferences, globalCiteKeyPattern); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can just move these methods to
JabRefPreferences
.