Commit graph

11598 commits

Author SHA1 Message Date
Michal Koutný
3248437326
Fix fish completion (#3068)
* Fix fish completions

As per [1] printf in fish does not support '--' as a delimiter of format
string and args.
It used to work (accidentally) earlier (fish 3.5, glibc 2.31) but it is
broken (fish 3.6, glibc 2.36) nowadays.
Fix it by using the simple form of printf invocation with no argument
escaping.

Fixes: #3048

[1] https://fishshell.com/docs/current/cmds/printf.html#description

* Fix fish completions with older fish

Older versions (fish 3.5) cannot cope with '-' in printf format hence
add a workaround for these.
2023-07-25 15:29:50 -04:00
Nathan Luong
76b21f49e8
Implement due dates related methods for Task and TaskMut (#3145)
* Implement due dates related methods for Task and TaskMut

* Merge add_due and remove_due into the single method called set_due

* reformat the file
2023-07-25 09:09:25 -04:00
Dathan Bennett
c86252d693
Add devcontainer spec (#3144)
* Add devcontainer spec from codespaces generator

I started a codespace and used the VSCode devcontainer generator to
generate the devcontainer.json, reinstall-cmake.sh, and Dockerfile.

* Add uuid-dev in Dockerfile

---------

Co-authored-by: Dathan Bennett <dathanb@netflix.com>
2023-07-20 17:33:02 -04:00
Dathan Bennett
a7bb0c9ba0
Link executables using system frameworks on Darwin (#3075)
* Link test executables using system frameworks on Darwin

On an M1 MBP, running `cmake . && make test` yields the error

```
[ 69%] Linking CXX executable tc.t
Undefined symbols for architecture arm64:
  "_CFRelease", referenced from:
      _$LT$iana_time_zone..platform..system_time_zone..SystemTimeZone$u20$as$u20$core..ops..drop..Drop$GT$::drop::hcd3964de9573de30 in libtc_rust.a(iana_time_zone-0e2714c6ff24f5bb.iana_time_zone.4cacef0c-cgu.15.rcgu.o)
  "_CFStringGetBytes", referenced from:
      iana_time_zone::platform::string_ref::StringRef$LT$T$GT$::to_utf8::h39971b546d587152 in libtc_rust.a(iana_time_zone-0e2714c6ff24f5bb.iana_time_zone.4cacef0c-cgu.13.rcgu.o)
  "_CFStringGetCStringPtr", referenced from:
      iana_time_zone::platform::string_ref::StringRef$LT$T$GT$::as_utf8::h8bb5c2c0d091ded1 in libtc_rust.a(iana_time_zone-0e2714c6ff24f5bb.iana_time_zone.4cacef0c-cgu.13.rcgu.o)
  "_CFStringGetLength", referenced from:
      iana_time_zone::platform::string_ref::StringRef$LT$T$GT$::to_utf8::h39971b546d587152 in libtc_rust.a(iana_time_zone-0e2714c6ff24f5bb.iana_time_zone.4cacef0c-cgu.13.rcgu.o)
  "_CFTimeZoneCopySystem", referenced from:
      iana_time_zone::platform::system_time_zone::SystemTimeZone:🆕:hc42d30609914d79d in libtc_rust.a(iana_time_zone-0e2714c6ff24f5bb.iana_time_zone.4cacef0c-cgu.15.rcgu.o)
  "_CFTimeZoneGetName", referenced from:
      iana_time_zone::platform::system_time_zone::SystemTimeZone::name::h44947ee6deb3339a in libtc_rust.a(iana_time_zone-0e2714c6ff24f5bb.iana_time_zone.4cacef0c-cgu.15.rcgu.o)
  "_SecRandomCopyBytes", referenced from:
      ring::rand::darwin::fill::h0ad94d66d4e1a222 in libtc_rust.a(ring-e5f87a2e334d4c6a.ring.a21bac31-cgu.4.rcgu.o)
  "_kSecRandomDefault", referenced from:
      ring::rand::darwin::fill::h0ad94d66d4e1a222 in libtc_rust.a(ring-e5f87a2e334d4c6a.ring.a21bac31-cgu.4.rcgu.o)
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[3]: *** [test/tc.t] Error 1
make[2]: *** [test/CMakeFiles/tc.t.dir/all] Error 2
make[1]: *** [test/CMakeFiles/test.dir/rule] Error 2
```

This change resolves the error by updating the targets in
test/CMakeLists.txt to link against the CoreFoundation and Security
frameworks when building under Mac OS.

* Link executables against CoreFoundation and Security frameworks on Mac OS

* Rename test_osx.sh to test_macos.sh

---------

Co-authored-by: Dathan Bennett <dathanb@netflix.com>
2023-07-20 17:23:12 -04:00
Dustin J. Mitchell
7f68441916
Change "client key" to "client id" (#3130)
In #3118 @ryneeverett mentioned that "key" suggests that this is a
secret, when in truth it's just a user identifier. So "ID" is a better
word for it than "key".
2023-07-11 22:13:53 -04:00
dependabot[bot]
8097e28318
Bump pretty_assertions from 1.3.0 to 1.4.0 (#3129)
Bumps [pretty_assertions](https://github.com/rust-pretty-assertions/rust-pretty-assertions) from 1.3.0 to 1.4.0.
- [Release notes](https://github.com/rust-pretty-assertions/rust-pretty-assertions/releases)
- [Changelog](https://github.com/rust-pretty-assertions/rust-pretty-assertions/blob/main/CHANGELOG.md)
- [Commits](https://github.com/rust-pretty-assertions/rust-pretty-assertions/compare/v1.3.0...v1.4.0)

---
updated-dependencies:
- dependency-name: pretty_assertions
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-07-08 10:28:07 -04:00
Dustin J. Mitchell
31105c2ba3
Sync against taskchampion-sync-server (#3118)
This removes use of gnutls and the TLS implementation, which is no
longer needed (task synchronization is handled via Taskchampion, which
uses `reqwest`, which handles TLS via other Rust dependencies). This
incidentally removes the following config options:
 * `debug.tls`
 * `taskd.ca`
 * `taskd.certificate`
 * `taskd.ciphers`
 * `taskd.credentials`
 * `taskd.key`
 * `taskd.server`
 * `taskd.trust`
2023-07-08 10:27:33 -04:00
Dustin J. Mitchell
771977aa69 Restore check for missing config 2023-07-04 14:08:51 -04:00
dependabot[bot]
5db8b292c7 Bump uuid from 1.3.0 to 1.4.0
Bumps [uuid](https://github.com/uuid-rs/uuid) from 1.3.0 to 1.4.0.
- [Release notes](https://github.com/uuid-rs/uuid/releases)
- [Commits](https://github.com/uuid-rs/uuid/compare/1.3.0...1.4.0)

---
updated-dependencies:
- dependency-name: uuid
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-28 12:23:50 -04:00
Dustin J. Mitchell
0c3d4bbe74 bump ffizz-header to 0.5 2023-06-26 18:18:44 -04:00
Dustin J. Mitchell
48543b7fcb Put Rust deps at the root of the workspace
This allows us to be consistent about the required versions for each of
the member packages.

Fixes #3088.
2023-06-21 12:01:06 -04:00
Dustin J. Mitchell
7a310fbfc1 Remove redundant comments
There's no need to repeat comments on the fields of a struct within
taskchampion-lib.
2023-06-21 12:00:23 -04:00
dependabot[bot]
1930ea0ad0 Bump strum_macros from 0.24.3 to 0.25.0
Bumps [strum_macros](https://github.com/Peternator7/strum) from 0.24.3 to 0.25.0.
- [Changelog](https://github.com/Peternator7/strum/blob/master/CHANGELOG.md)
- [Commits](https://github.com/Peternator7/strum/commits)

---
updated-dependencies:
- dependency-name: strum_macros
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-19 16:29:57 -04:00
dependabot[bot]
790a50f7e0 Bump strum from 0.24.1 to 0.25.0
Bumps [strum](https://github.com/Peternator7/strum) from 0.24.1 to 0.25.0.
- [Changelog](https://github.com/Peternator7/strum/blob/master/CHANGELOG.md)
- [Commits](https://github.com/Peternator7/strum/commits)

---
updated-dependencies:
- dependency-name: strum
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-19 13:36:25 -04:00
Dustin J. Mitchell
839a0c4a0f fix workflow reference 2023-06-19 13:36:17 -04:00
Dustin J. Mitchell
efc2531a7f fix a spot where C code looked like a doctest 2023-06-19 13:36:17 -04:00
Dustin J. Mitchell
a0703af0b9 Run 'cargo xtask codegen' in CI and check that there are no diffs 2023-06-19 13:36:17 -04:00
Dustin J. Mitchell
75e10676ce Use ffizz_header to generate taskchampion.h 2023-06-19 13:36:17 -04:00
dependabot[bot]
989a330e46 Bump ureq from 2.6.1 to 2.7.0
Bumps [ureq](https://github.com/algesten/ureq) from 2.6.1 to 2.7.0.
- [Changelog](https://github.com/algesten/ureq/blob/main/CHANGELOG.md)
- [Commits](https://github.com/algesten/ureq/compare/2.6.1...2.7.0)

---
updated-dependencies:
- dependency-name: ureq
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-15 19:54:42 -04:00
Dustin J. Mitchell
a69b0c8032 Remove properties when set to an empty string
Fixes #3109.
2023-06-11 17:37:03 -04:00
Dustin J. Mitchell
6cd5bf1237 Update "modified" on modification 2023-06-11 17:37:03 -04:00
Dustin J. Mitchell
a1b64a05ba add more information to 'task purge' footnote 2023-06-11 17:37:03 -04:00
Dustin J. Mitchell
02de8dfe67 remove TDB2::commit call from tests 2023-06-11 17:37:03 -04:00
Dustin J. Mitchell
3b4113c61a Update comments for TDB2::modify 2023-06-11 17:37:03 -04:00
Dustin J. Mitchell
18d60719e4 update comment for TDB2::get_changes 2023-06-11 17:37:03 -04:00
Dustin J. Mitchell
9df4c8156e remove TDB::commit 2023-06-11 17:37:03 -04:00
Dustin J. Mitchell
0882a08d18 Remove unnecessary TDB2::{modify,add} argument 2023-06-11 17:37:03 -04:00
Dustin J. Mitchell
5bb9857984 Use Taskchampion to store Taskwarrior data
This replaces the TF2 task files with a TaskChampion replica.
2023-06-11 17:37:03 -04:00
Dustin J. Mitchell
4b814bc602 [BREAKING] remove diff display from 'task undo'
TaskChampion does not make the necessary information available to
accomplish this, but see #2928.
2023-06-11 17:37:03 -04:00
Dustin J. Mitchell
87467f72c7 [BREAKING] remove 'task purge' support
TaskChampion removes deleted tasks automatically when they expire, so
this subcommand is no longer required.
2023-06-11 17:37:03 -04:00
Dustin J. Mitchell
d47c70579f [BREAKING] Disable the 'sync' command
This will require support from TaskChampion.
2023-06-11 17:37:03 -04:00
dependabot[bot]
16c35a41d3 Bump tempfile from 3.5.0 to 3.6.0
Bumps [tempfile](https://github.com/Stebalien/tempfile) from 3.5.0 to 3.6.0.
- [Changelog](https://github.com/Stebalien/tempfile/blob/master/CHANGELOG.md)
- [Commits](https://github.com/Stebalien/tempfile/compare/v3.5.0...v3.6.0)

---
updated-dependencies:
- dependency-name: tempfile
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-07 20:19:59 -04:00
dependabot[bot]
d28cdc39fa Bump proptest from 1.1.0 to 1.2.0
Bumps [proptest](https://github.com/proptest-rs/proptest) from 1.1.0 to 1.2.0.
- [Release notes](https://github.com/proptest-rs/proptest/releases)
- [Changelog](https://github.com/proptest-rs/proptest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/proptest-rs/proptest/compare/v1.1.0...v1.2.0)

---
updated-dependencies:
- dependency-name: proptest
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-05-25 10:55:10 -04:00
dependabot[bot]
66b2db52f4 Bump clap from 4.2.1 to 4.3.0
Bumps [clap](https://github.com/clap-rs/clap) from 4.2.1 to 4.3.0.
- [Release notes](https://github.com/clap-rs/clap/releases)
- [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md)
- [Commits](https://github.com/clap-rs/clap/compare/clap_complete-v4.2.1...clap_complete-v4.3.0)

---
updated-dependencies:
- dependency-name: clap
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-05-22 19:09:04 -04:00
Dathan Bennett
41608dc35f Fork CMakeRust and add the aarch64-apple-darwin fix to it 2023-04-27 19:18:10 -04:00
Dathan Bennett
7492fc48bb Vendor CMakeRust 2023-04-27 19:18:10 -04:00
Dathan Bennett
37d7f3de8a Ignore IntelliJ artifacts and remove CMakeRust submodule 2023-04-27 19:18:10 -04:00
Dustin J. Mitchell
ddd367232e [BREAKING] Remove journal.info support
This support will require access to all of the operations ever performed
on a task, which is not currently exposed by TaskChampion (but see #2928)
2023-04-16 19:21:14 -04:00
dependabot[bot]
cf711f5eb1 Bump h2 from 0.3.16 to 0.3.17
Bumps [h2](https://github.com/hyperium/h2) from 0.3.16 to 0.3.17.
- [Release notes](https://github.com/hyperium/h2/releases)
- [Changelog](https://github.com/hyperium/h2/blob/master/CHANGELOG.md)
- [Commits](https://github.com/hyperium/h2/compare/v0.3.16...v0.3.17)

---
updated-dependencies:
- dependency-name: h2
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-04-13 17:16:10 -04:00
Dustin J. Mitchell
f0ced5287b bump MSRV 2023-04-09 16:17:16 -04:00
Dustin J. Mitchell
645c6bf13f update clap used in sync-server 2023-04-09 16:17:16 -04:00
Dustin J. Mitchell
5f2d82dc72 update MSRV 2023-04-09 15:44:26 -04:00
Dustin J. Mitchell
ae028983b6 clippy fixes 2023-04-09 15:44:26 -04:00
Dustin J. Mitchell
52fdc6a877 Update Actix crates to latest versions
This avoids a vulnerability in tokio (#3085). The major version updates
of both actix-web and actix-rt required some signficant changes. Chief
among those, it turns out we were relying on actix-rt to run the
HttpServer in a different thread from the rest of the test, so that we
could talk to it from sync code in the test thread. This no longer
works, so the sync code is now run in a dedicated thread with
`actix_rt::task::spawn_blocking`.
2023-04-09 15:44:26 -04:00
Dathan Bennett
33366e2f05 Ignore the aarch64-apple-darwin directory
This directory is generated instead of the x86_64-unknown-linux-gnu
directory when building on an ARM64/AArch64 Mac, so this change adds
that directory to the gitignore config.
2023-04-09 15:29:29 -04:00
Dustin J. Mitchell
ed674ec9e5 fix branch references in dev docs 2023-04-09 15:28:45 -04:00
dependabot[bot]
491941a55c Bump tempfile from 3.4.0 to 3.5.0
Bumps [tempfile](https://github.com/Stebalien/tempfile) from 3.4.0 to 3.5.0.
- [Release notes](https://github.com/Stebalien/tempfile/releases)
- [Changelog](https://github.com/Stebalien/tempfile/blob/master/NEWS)
- [Commits](https://github.com/Stebalien/tempfile/commits)

---
updated-dependencies:
- dependency-name: tempfile
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-03-29 17:51:08 -04:00
dependabot[bot]
77e1773b04 Bump rusqlite from 0.28.0 to 0.29.0
Bumps [rusqlite](https://github.com/rusqlite/rusqlite) from 0.28.0 to 0.29.0.
- [Release notes](https://github.com/rusqlite/rusqlite/releases)
- [Changelog](https://github.com/rusqlite/rusqlite/blob/master/Changelog.md)
- [Commits](https://github.com/rusqlite/rusqlite/compare/v0.28.0...v0.29.0)

---
updated-dependencies:
- dependency-name: rusqlite
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-03-27 17:37:40 -04:00
dependabot[bot]
d2f2e2b4a4 Bump rstest from 0.16.0 to 0.17.0
Bumps [rstest](https://github.com/la10736/rstest) from 0.16.0 to 0.17.0.
- [Release notes](https://github.com/la10736/rstest/releases)
- [Changelog](https://github.com/la10736/rstest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/la10736/rstest/compare/0.16.0...0.17.0)

---
updated-dependencies:
- dependency-name: rstest
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-03-21 15:23:16 -04:00
dependabot[bot]
e46533ef2b Bump tempfile from 3.3.0 to 3.4.0
Bumps [tempfile](https://github.com/Stebalien/tempfile) from 3.3.0 to 3.4.0.
- [Release notes](https://github.com/Stebalien/tempfile/releases)
- [Changelog](https://github.com/Stebalien/tempfile/blob/master/NEWS)
- [Commits](https://github.com/Stebalien/tempfile/commits)

---
updated-dependencies:
- dependency-name: tempfile
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-02-28 15:12:52 -05:00