Commit Graph

10 Commits

Author SHA1 Message Date
ratchek 2cb9afd4d5
Add a dev mode that allows for local storing of config files and logs (#1682)
Allows vorta to be called with the command-line flag `--development` or `-D` that will make it use a directory in the project tree to store all the settings, logs, and cache. This default directory will be called `.dev_config` and placed in the projects root.
Also allows for a custom directory path allowing for multiple "configuration" folders at once.
This can be used to prevent the vorta instance that a developer is working on from accessing the configuration files that they have set up for their personal backups.

* .gitignore : Add `.dev_config`.

* src/vorta/utils.py (parse_args): Add `--development` flag. The default will be `DEFAULT_DIR_FLAG`.

* src/vorta/utils.py : Add `DEFAULT_DIR_FLAG`.

* src/vorta/config.py : Add methods for populating the config directories exposed by this module.

* src/vorta/__main__.py (main): Handle `--development` flag and update config directories if its specified.

* Access config constants through the `config` module instead of importing them directly with `from .config import`.

---------
Co-authored-by: yfprojects <62463991+real-yfprojects@users.noreply.github.com>
2023-05-30 10:43:20 +00:00
real-yfprojects 24e1dd5c56
Run pre-commit (with newly added ruff) on code base.
Includes all changes by `pre-commit --all-files` including the changes introduced by ruff.
2023-05-01 10:28:11 +02:00
Vamp 961e0b5057
Migrate from appdirs to platformdirs (#1617)
Fixes #1610. Replace deprecated `appdirs` with fork `platformdirs`. Use the new `*_path` api of set fork. This changes the type of the constants defined in `vorta.config` holding locations to `pathlib.Path`.

* setup.cfg : Replace dep `appdirs` with `platformdirs`.

* src/vorta/config.py : Migrate. Simplify code for ensuring that the directories exist.

* src/vorta/log.py
* src/vorta/autostart.py
* src/vorta/application.py
* src/vorta/__main__.py
2023-03-10 16:00:39 +00:00
Philipp Hossner 5192bd132c
Import/export settings (or bootstrap with default config). By @phihos (#955) 2021-06-05 15:15:38 +04:00
Hofer Julian 96e4d4bef2
Move socket file from state-dir to tmp-dir. Fixes #513 2020-06-22 16:24:38 +08:00
Manu 82844a17b4
Add macOS notarization, use Github Workflows for testing (#407)
* Improve macOS packaging, add notarization.
* Properly use QApplication while testing, remove workarounds.
* Use Github Workflows instead of Travis.
* Remove outdated test workaround.
2020-03-03 13:19:36 +08:00
Julian Hofer 8f5953b3b4 Make Flatpak Ready
1) Change socket-file path so that Flatpaks has access
2) Change autostart function so that it detects if it is run as Flatpak
2019-05-05 16:16:46 +02:00
Manu c30bdd9cf4 Redirect Borg logging output to standard location. Fixes #35 2018-11-22 11:06:58 +08:00
Manu 3a5eafd061 Replace peewee_migrate with native solution. Fix window activation. 2018-11-02 00:53:41 +08:00
Manu df04edb222 Change to src-based layout. Start work on scheduler. 2018-10-29 13:12:45 +08:00
Renamed from vorta/config.py (Browse further)