Skip to content

Dynamic group mirroring the file system. #10930

@koppor

Description

@koppor

As user, I organize my PDFs in folders. Example:

Related_Work_Collection
├── Quantum_Computing
│   ├── Algorithms
│   │   ├── Quantum_Factorization_Overview.pdf
│   │   └── Grover_Search_Implementation.pdf
│   ├── Error_Correction
│   │   ├── Topological_Qubits_and_Error_Correction.pdf
│   │   └── Quantum_Codec_Principles.pdf
│   └── Hardware
│       └── Superconducting_Qubits_Advancements.pdf
├── Machine_Learning
│   ├── Neural_Networks
│   │   ├── Deep_Learning_Architectures.pdf
│   │   └── CNN_for_Image_Recognition.pdf
│   ├── Reinforcement_Learning
│   │   └── RL_in_Video_Games.pdf
│   └── Natural_Language_Processing
│       ├── BERT_and_Transformers.pdf
│       └── Sentiment_Analysis_Techniques.pdf
└── Environmental_Science
    ├── Climate_Change
    │   └── Impact_of_Climate_Change_on_Biodiversity.pdf
    ├── Renewable_Energy
    │   ├── Solar_Energy_Trends.pdf
    │   └── Wind_Power_Innovations.pdf
    └── Conservation
        ├── Wildlife_Conservation_Strategies.pdf
        └── Marine_Protection_Efforts.pdf

When one wants to have this hierarchy in JabRef, one needs to manually create groups and sub groups.

A new type of group "Directory structure" should be created:

image

JabRef then mirrors the directory structure in the group tree. Sub groups are automatically created.

Currently: Only inbound mirroring. Use WatchService to watch for changes.

All BibEntries having a file in the selected directory belong to that group.

File added to a folder -> automatically added to the respective group and a new BibEntry created (with PDF import)

Implementation hint:

  • A user selects the root directory, all sub groups are automatically updated (created and remved) by JabRef upon file system changes.
  • Implement a DirectoryUpdateMonitor (similar to org.jabref.model.util.FileUpdateMonitor) which watches directories and sends updates to the group tree (see third bullet point at Add FileMonitor for LaTeX citations #10937 (comment) in another context)

Future work:

  1. Group moved -> On file system also renames and BibTeX entry "files" field adapted accordingly
  2. Group renamed -> On file system also renamed and BibTeX entry "files" field adapted accordingly
  3. file moved -> entry assigned to another group BibTeX entry "files" field adapted accordingly

Related issues:

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    Free to take

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions