Skip to content

Commit

Permalink
Merge branch 'main' into addRightlickToGroup
Browse files Browse the repository at this point in the history
  • Loading branch information
Siedlerchr authored Jan 10, 2025
2 parents c579a88 + 772f24b commit d2d321b
Show file tree
Hide file tree
Showing 7 changed files with 38 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/deployment-arm64.yml
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ jobs:
BUILDJABREFPRIVATEKEY: ${{ secrets.buildJabRefPrivateKey }}
- name: Download from GitHub workflow artifacts store (macOS)
if: (steps.checksecrets.outputs.secretspresent == 'YES')
uses: actions/download-artifact@master
uses: actions/download-artifact@v4
with:
name: JabRef-macOS-arm-tbn
path: build/distribution/
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/deployment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,9 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-13]
os: [ubuntu-22.04, windows-latest, macos-13]
include:
- os: ubuntu-latest
- os: ubuntu-22.04
displayName: linux
archivePortable: tar -c -C build/distribution JabRef | pigz --rsyncable > build/distribution/JabRef-portable_linux.tar.gz && rm -R build/distribution/JabRef
- os: windows-latest
Expand Down Expand Up @@ -314,7 +314,7 @@ jobs:
BUILDJABREFPRIVATEKEY: ${{ secrets.buildJabRefPrivateKey }}
- name: Download from GitHub workflow artifacts store (macOS)
if: (steps.checksecrets.outputs.secretspresent == 'YES')
uses: actions/download-artifact@master
uses: actions/download-artifact@v4
with:
name: JabRef-macOS-tbn
path: build/distribution/
Expand Down
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ Note that this project **does not** adhere to [Semantic Versioning](https://semv
### Fixed

- We fixed an issue where a bib file with UFF-8 charset was wrongly loaded with a different charset [forum#5369](https://discourse.jabref.org/t/jabref-5-15-opens-bib-files-with-shift-jis-encoding-instead-of-utf-8/5369/)
- We fixed an issue where new entries were inserted in the middle of the table instead of at the end. [#12371](https://github.com/JabRef/jabref/pull/12371)
- We fixed an issue where removing the sort from the table did not restore the original order. [#12371](https://github.com/JabRef/jabref/pull/12371)

### Removed

Expand Down
23 changes: 22 additions & 1 deletion src/main/java/org/jabref/gui/maintable/MainTable.java
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,28 @@ public MainTable(MainTableDataModel model,
this.setItems(model.getEntriesFilteredAndSorted());

// Enable sorting
model.getEntriesFilteredAndSorted().comparatorProperty().bind(this.comparatorProperty());
// Workaround for a JavaFX bug: https://bugs.openjdk.org/browse/JDK-8301761 (The sorting of the SortedList can become invalid)
// The default comparator of the SortedList does not consider the insertion index of entries that are equal according to the comparator.
// When two entries are equal based on the comparator, the entry that was inserted first should be considered smaller.
this.setSortPolicy(_ -> true);
model.getEntriesFilteredAndSorted().comparatorProperty().bind(
this.comparatorProperty().map(comparator -> {
if (comparator == null) {
return null;
}

return (entry1, entry2) -> {
int result = comparator.compare(entry1, entry2);
if (result != 0) {
return result;
}
// If the entries are equal according to the comparator, compare them by their index in the database.
// The comparison should ideally be based on the database index, but retrieving the index takes log(n). See {@link BibDatabase#indexOf}.
// Using the entry ID is also valid since IDs are monotonically increasing.
return entry1.getEntry().getId().compareTo(entry2.getEntry().getId());
};
})
);

// Store visual state
new PersistenceVisualStateTable(this, mainTablePreferences.getColumnPreferences()).addListeners();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ private static Stream<Arguments> providePdfData() {
Arguments.of("Pandemic programming", "/pdfs/PdfContentImporter/Ralph2020.pdf"),
Arguments.of("Do RESTful API design rules have an impact on the understandability of Web APIs?", "/pdfs/PdfContentImporter/Bogner2023.pdf"),
Arguments.of("Adopting microservices and DevOps in the cyber-physical systems domain: A rapid review and case study", "/pdfs/PdfContentImporter/Fritzsch2022.pdf"),
Arguments.of("OPIUM: Optimal Package Install/Uninstall Manager", "/pdfs/PdfContentImporter/opium.pdf")
Arguments.of("OPIUM: Optimal Package Install/Uninstall Manager", "/pdfs/PdfContentImporter/Tucker2007.pdf")
);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -134,3 +134,12 @@ @inproceedings{Baldoni2002Fundamentals
year = {2002}
file = {Baldoni2002.pdf}
}

@inproceedings{Tucker2007OPIUM,
author = {Chris Tucker and David Shuffelton and Ranjit Jhala and Sorin Lerner}
abstract = {Linux distributions often include package management tools such as apt-get in Debian or yum in RedHat. Using information about package dependencies and conflicts, such tools can determine how to install a new package (and its dependencies) on a system of already installed packages. Using off-the-shelf SAT solvers, pseudo-boolean solvers, and Integer Linear Programming solvers, we have developed a new package-management tool, called Opium, that improves on current tools in two ways: (1) Opium is complete, in that if there is a solution, Opium is guaranteed to find it, and (2) Opium can optimize a user-provided objective function, which could for example state that smaller packages should be preferred over larger ones. We performed a comparative study of our tool against Debian's apt-get on 600 traces of real-world package installations. We show that Opium runs fast enough to be usable, and that its completeness and optimality guarantees provide concrete benefits to end users.}
title = {OPIUM: Optimal Package Install/Uninstall Manager}
url = {https://ieeexplore.ieee.org/document/4222580}
year = {2007}
file = {Tucker2007.pdf}
}

0 comments on commit d2d321b

Please sign in to comment.