Commits
- Commit:
dce3ee7356ef403d0293d91edeefd789fa41fc83- From:
- Thomas Böhler <witcher@wiredspace.de>
- Date:
Add build manifest
Signed-off-by: Thomas Böhler <witcher@wiredspace.de>
- Commit:
3a1962417f5a84d9f1338b4cbab827577039f038- From:
- Thomas Böhler <witcher@wiredspace.de>
- Date:
Add CI manifests for Arch Linux and OpenBSD
Signed-off-by: Thomas Böhler <witcher@wiredspace.de>
- Commit:
b7118f1e9b9399020f683ebe7644cf7ce97eaf41- From:
- Thomas Böhler <witcher@wiredspace.de>
- Date:
Add .mailmap
Signed-off-by: Thomas Böhler <witcher@wiredspace.de>
- Commit:
1c780a5edc5db9414485a837e10b60040019cbd9- From:
- Thomas Böhler <witcher@wiredspace.de>
- Date:
Quote extension due date format properly
Signed-off-by: Thomas Böhler <witcher@wiredspace.de>
- Commit:
1f4ddc96eb4db278a8b9f42e7d60f902b1a5951d- From:
- Thomas Böhler <witcher@wiredspace.de>
- Date:
Use HTML comments for README.md license header
Signed-off-by: Thomas Böhler <witcher@wiredspace.de>
- Commit:
062b8f7a7f5d53a6994476f1eafe1775d6c76d62- From:
- Thomas Böhler <witcher@wiredspace.de>
- Date:
Change copyright owner
Signed-off-by: Thomas Böhler <witcher@wiredspace.de>
- Commit:
e0043a0e594792655e8b779ee92382e68e5c1a05- From:
- Thomas Böhler <witcher@wiredspace.de>
- Date:
Use `()` instead of `_` for closure
If the function argument to a closure is of type `()` clippy wants this to be
captured with a `()`, even if the argument isn't used.
Signed-off-by: Thomas Böhler <witcher@wiredspace.de>
- Commit:
bc6fb9a91750c4bf7c6dc6318f8a6c6bf0e0289f- From:
- witcher <witcher@wiredspace.de>
- Date:
Implement respecting the strict rule of `rec`
The `next_due` and `next_due_with_rec` methods now respect the strict
attribute of the recurring rule.
To still be able to test the method, a third method,
`next_due_with_rec_and_date` has been created which, instead of
internally computing the current date, explicitly takes the supposedly
current date.
The `next_due_with_rec_and_date` method is public for now but might be
made private, depending on how useful it might be.
Implements: https://todo.sr.ht/~witcher/todotxt/4
- Commit:
c25ff820f4b12628b9df9a9b35435c01da6f1606- From:
- witcher <witcher@wiredspace.de>
- Date:
Clarify WIP library
- Commit:
c8d456ebaa5112aa4cb65b8dc23a90e4a8dfa276- From:
- witcher <witcher@wiredspace.de>
- Date:
Expand on README.md a little
- Commit:
d74e882f5b7d2191be54e3eca5e95e06d8693b90- From:
- witcher <witcher@wiredspace.de>
- Date:
Fix `rec` regex not escaping literal `+`
- Commit:
157d7b0f7b1b8381c16b9761abcec10f6293ee6b- From:
- witcher <witcher@wiredspace.de>
- Date:
Add methods relating to recurring tasks
Basic recurring task functionality has been implemented in this patch,
but the strict recurring rule is still missing and needs to be
implemented.
This is quite hard to do while keeping the methods testable as the
strict rule relies on the current date, which currently is not being
taken via a parameter.
References: https://todo.sr.ht/~witcher/todotxt/4
- Commit:
2b4c6992a668ec0a40bb37a7ef041bd46f8f2b11- From:
- witcher <witcher@wiredspace.de>
- Date:
Be pedantic about references in doc comments
- Commit:
4846caa86f50134b6790df48298060c52944a501- From:
- witcher <witcher@wiredspace.de>
- Date:
Add getter/setter to `Task`
The attributes of the `Task` struct will remain private and access is
granted through getter and setter.
Additionally, methods for adding tags have been added.
- Commit:
82d62f1006b9df033509bb03d9cf3b550fe2d7bc- From:
- witcher <witcher@wiredspace.de>
- Date:
Derive `Copy` on `Completion`
- Commit:
249da5d44ed04e0b53c5a71d3934193d834791f3- From:
- witcher <witcher@wiredspace.de>
- Date:
Implement `Display` for some types
- Commit:
01ba7a35eb3e4796a5d0cdf8a5d72c53d4a7c3e4- From:
- witcher <witcher@wiredspace.de>
- Date:
Remove field `tags` from struct `Task` altogether
As the `tags` field is essentially just a view into the `description`
field and keeping both fields synchronised can be a burden, the `tags`
field has been removed and tags will now be computed on the fly, if
necessary.
Additionally, `description` has been changed to a `Cow` since it can
change and thus needs to be able to be an owned type. It nothing is
changed, however, the description will still only be a slice of the
original one, avoiding multiple copies being stored in memory.
If the description of the task needs to be changed, `description` will
become an owned field.
- Commit:
e79ffd7b92c4807a481f6ad3d27605e484f4f58d- From:
- witcher <witcher@wiredspace.de>
- Date:
Restrict field access on `Task`
The `Task` struct has 2 fields that rely on each other: `description`
and `tags`. Changing one will most likely mean a change in the other,
and changing `tags` by itself probably makes no sense.
Both fields have been made private, forcing instantiation with
`Task::new` and forcing changes to go through the `set_description`
method, both computing the `tags` from the description.
- Commit:
a6078516315466372617a4c3b72a6b88d04ad76b- From:
- witcher <witcher@wiredspace.de>
- Date:
Make fields of types public, strict completion
All fields in all structs in `types.rs` have been made public.
The `completed` field in `Tag` has been replaced with a `completion`
field with type `Completion`. This encodes in the type system that a
task can only ever has a date of completion if it is actually complete.
- Commit:
c6bbc32edce650be04dc40fbc37cbd56dea19819- From:
- witcher <witcher@wiredspace.de>
- Date:
Add example for listing todo tasks from file
- Commit:
bb8c74542457826daface68277e34212797debec- From:
- witcher <witcher@wiredspace.de>
- Date:
Mark `Tag` as `non_exhaustive`
Since it is planned to add more tags later on, `Tag` is now marked as
`non_exhaustive`.
- Commit:
56a34cab2c941537894a8d45e00a8a0c22102ba7- From:
- witcher <witcher@wiredspace.de>
- Date:
Add integration test for `types.rs`
- Commit:
bda18df0aafe22fad505453b2dcdbe9868c90a54- From:
- witcher <witcher@wiredspace.de>
- Date:
Add TryFrom implementation for Task and unit tests
`Task` can now be created from `&str` via `TryFrom`.
The `new_key_value` method on `Tag` now has unit tests.
- Commit:
caf5a2e4344d368c834c8d00be84873248d843bc- From:
- witcher <witcher@wiredspace.de>
- Date:
Verify recurring amount is at least 1
- Commit:
921165feb60b35f5fff3c8ca30107a3fb5273c46- From:
- witcher <witcher@wiredspace.de>
- Date:
Add more clippy lints and fix them
