Two working directories - Two instances

I’m an happy user of paperwork for my personal stuff.

I’m recently working as a beekeeper and I want to use another working dir or instance to manage my professional documents. I know that the paperwork goal is to have everything in only one place but I would like keep perso and pro documents separated.
A solution could be the ability to pass the working directory as a startup parameter.
Is there any workaround ? perhaps using paperwork-shell.




At the moment, there is nothing implemented yet for that, but it’s on the TODO list.

The only workaround that I know of at the moment is by setting the environment variables XDG_CONFIG_HOME and XDG_DATA_HOME to use 2 different configurations. For example, in a Linux terminal:

export XDG_CONFIG_HOME=~/some_config_dir  # default is ~/.config
export XDG_DATA_HOME=~/some_data_dir  # default is ~/.local/share

Or if you use Flatpak:

# both paths must be in your home directory
flatpak run \
  --env=XDG_CONFIG_HOME=${HOME}/some_config_dir  \
  --env=XDG_DATA_HOME=${HOME}/some_data_dir \

XDG_CONFIG_HOME specifies where the configuration file must be stored (${XDG_CONFIG_HOME}/paperwork.conf), and the configuration files contains the work directory location (so switching the first one allows to switch the second one).

XDG_DATA_HOME specifies where the data files (index, training, etc) must be stored (${XDG_DATA_HOME}/paperwork/*). Since those data files depends on the content of the work directory, you should switch them too. If you don’t, Paperwork will have to do full index updates everything you switch the work directory. It would be safe but it would be very slow.

Best regards,

Thanks for your quick answer :slight_smile:
I can made a shell script for my perso docs and I use the 2.99 version with flatpack for my pro docs.

Best regards,