From 7acf63829138fd9a66f9cb9c2d238910700a06a6 Mon Sep 17 00:00:00 2001 From: tensorturtle Date: Fri, 20 Dec 2024 20:32:17 +0900 Subject: [PATCH] update to 0.2.6 --- README.md | 18 +++++------------- pyproject.toml | 2 +- src/fob/utils/utils.py | 2 +- uv.lock | 2 +- 4 files changed, 8 insertions(+), 16 deletions(-) diff --git a/README.md b/README.md index bb63777..5391817 100644 --- a/README.md +++ b/README.md @@ -33,17 +33,19 @@ Run app in development: uv run fob ``` +The `--debug` option may be helpful. Also, the so-called database is actually just a human-readable/editable JSON file. Use `fob info` to see where the database is located. + # Test ``` uvx pytest ``` -This is an end-to-end test. It installs `fob` to a temporary directory using `install.sh` and runs commands against it. +This is an end-to-end test. It installs `fob` to a temporary directory using `install.sh` and runs commands against it. Github Actions is set up to run the same test upon pushing to main branch. # Release -From the root of this repository, run `install.sh`. It uses pyinstaller to create a standalone binary and places it in `~/.local/bin` for access from anywhere on the system. +From the root of this repository, run `./install.sh`. It uses pyinstaller to create a standalone binary and places it in `~/.local/bin` for access from anywhere on the system. Create a new Github Release with a new tag and upload the executable. The binary is at: `dist/fob`. @@ -63,14 +65,4 @@ For example, to use a database synchronized across devices on your Dropbox, add the following line to `~/.bashrc` (for bash shell): ``` export FOB_DB_PATH="~/Dropbox/my-fob.db" -``` - -# Inner Workings - -## Database - -[`TinyDB`](https://github.com/msiemens/tinydb) is used to persist the data as a human-readable JSON file. - -Since we're not using a SQL database, we are responsible for upholding the integrity and consistency of the data before writing it to the database. We implement that by first receiving all the data from the user, validating it, and then 'committing' (writing) to the database in one go. - -Run the program with debug option `fob -x` or `fob --debug` to see how the database gets updated. Also, the so-called database is actually just a human-readable JSON file, so you can open that to inspect / edit it if you're developing `fob`. Use `fob info` to see where the database is located. \ No newline at end of file +``` \ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index aa64acf..89e4479 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,7 +1,7 @@ [project] name = "fob" # Remember to update the version number in 'utils/utils.py' manually also. -version = "0.2.5" +version = "0.2.6" description = "Focus Blocks: Simple and elegant daily time management tool." readme = "README.md" authors = [{ name = "tensorturtle", email = "tensorturtle@gmail.com" }] diff --git a/src/fob/utils/utils.py b/src/fob/utils/utils.py index 9034d64..e26ea30 100644 --- a/src/fob/utils/utils.py +++ b/src/fob/utils/utils.py @@ -7,7 +7,7 @@ from rich import print def get_version_number() -> tuple[int, int, int]: - return (0,2,5) + return (0,2,6) def get_db_path(args: Namespace) -> Path: ''' diff --git a/uv.lock b/uv.lock index 3c0e935..11eedf9 100644 --- a/uv.lock +++ b/uv.lock @@ -21,7 +21,7 @@ wheels = [ [[package]] name = "fob" -version = "0.2.5" +version = "0.2.6" source = { virtual = "." } dependencies = [ { name = "pyinstaller" },