Commit Graph

201 Commits

Author SHA1 Message Date
Fintan Halpenny 170915ffcf nix: Nix flake maintenance
The nix flake's checks were failing for various reasons. The following fixes are
applied to get it up to date again.

- Update to release-24.11, since `crane` requires it – also to keep up-to-date
- Add `.json` to the source filters to allow for testing patch migration
- Ensure that the `rad` and `git-remote-rad` binaries are built for the nextest
  check. N.b. the binaries need to be in the target dir of `radicle-cli` since
  that is where the nextest check runs from.
- Add `cargo-audit` and `cargo-deny`, to the devShell, to allow for running those
  tools locally
- Bump `gix-path` to 0.10.11 to avoid a vulnerability[^0]

[^0]: https://rustsec.org/advisories/RUSTSEC-2024-0371
2025-04-10 15:29:08 +02:00
Fintan Halpenny c2863c08ab radicle: extend emoji support
Extend the ranges of emojis that are supported, listed
[below](#new-emojis-supported).

To ensure that single `char` emojis are supported, the `emojis` crate
is added as a dev dependency, using it to check that a `Reaction` can
be constructed for the two groups `SmileysAndEmotion` and
`PeopleAndBody`.

### New Emojis Supported

'🩵' 0x1FA75
'🩶' 0x1FA76
'🩷' 0x1FA77
'🫀' 0x1FAC0
'🫁' 0x1FAC1
'🫂' 0x1FAC2
'🫃' 0x1FAC3
'🫄' 0x1FAC4
'🫅' 0x1FAC5
'🫆' 0x1FAC6
'🫠' 0x1FAE0
'🫡' 0x1FAE1
'🫢' 0x1FAE2
'🫣' 0x1FAE3
'🫤' 0x1FAE4
'🫥' 0x1FAE5
'🫦' 0x1FAE6
'🫨' 0x1FAE8
'🫩' 0x1FAE9
'🫰' 0x1FAF0
'🫱' 0x1FAF1
'🫲' 0x1FAF2
'🫳' 0x1FAF3
'🫴' 0x1FAF4
'🫵' 0x1FAF5
'🫶' 0x1FAF6
'🫷' 0x1FAF7
'🫸' 0x1FAF8
2025-04-10 15:18:31 +02:00
Fintan Halpenny d9c76893a1
cli: bump version to 0.12.1 2024-12-04 12:47:00 +01:00
Lorenz Leutgeb 7616dcb793
cli/cob: Output JSON Lines 2024-12-03 12:36:02 +01:00
Lorenz Leutgeb b4f18f43d3
cli: Bump to 0.12.0 2024-11-29 16:31:52 +01:00
Lorenz Leutgeb 1fa1cafee9
cli: Update tree-sitter
Bump `tree-sitter` from 0.20 to 0.24 and replace `tree-sitter-toml` with
the fork `tree-sitter-toml-ng`.
2024-11-29 16:09:53 +01:00
cloudhead fd892d006f
Update `radicle` to 0.14 2024-11-29 15:25:09 +01:00
cloudhead d39ba83cfc
Update `Cargo.lock` 2024-09-03 12:42:10 +02:00
cloudhead 4e112aaeaa
Update `radicle` crate to 0.13.0 2024-08-28 13:01:35 +02:00
cloudhead 2d241e5f7d
Update `radicle-crypto` crate to 0.11.0 2024-08-28 13:01:35 +02:00
cloudhead c112f3fbc9
Update `radicle-cob` crate to 0.12.0 2024-08-28 12:55:30 +02:00
Sebastian Martinez beac367056
Update `radicle-surf` to 0.22.0 2024-08-20 16:35:04 +02:00
Fintan Halpenny e1470fccd7
fetch: update gix-pack and gix-odb
The `gix-fs` crate was flagged as vulnerable[^0]. To update it to `>=0.11.0`, it
was necessary to update the `gix-pack` and `gix-odb` crate versions to `0.51`
and `0.61`, respectively.

This in turn updated `fastrand` which changed its algorithm[^1], which meant
that some test outputs were reordered or matched new values.

[0]: https://rustsec.org/advisories/RUSTSEC-2024-0350
[1]: https://github.com/smol-rs/fastrand/blob/master/CHANGELOG.md#version-210
2024-08-09 12:41:01 +02:00
Lorenz Leutgeb 723e2741f5
node: Socket Activation with systemd 2024-07-22 10:44:22 +02:00
cloudhead 123f7eb6bb
Update `radicle` crate to 0.12.0 2024-07-18 16:22:14 +02:00
cloudhead 27eff8095d
node: Don't depend on `gix` directly
This avoids pulling in the same dependency twice.
2024-07-16 15:57:27 +02:00
Alexis Sellier e56a70b0d3
node: Update `io-reactor` dependency
The previous version contained a bug which caused disconnections
to not be forwarded to the service.
2024-07-06 11:12:13 +02:00
cloudhead 92c9e21873
Bump `radicle` crate to 0.11.1 2024-06-26 14:49:10 +02:00
cloudhead a4989b7ce7
Remove `radicle-httpd` crate
The HTTP daemon is moved to the `radicle-explorer` repository. Hence,
all traces of it are removed from this repository.
2024-06-06 11:14:00 +02:00
cloudhead ab532be033
Bump crate versions
We bump the versions of the crates required to publish a new version of
`radicle-httpd` in preparation of moving it out of the repo.
2024-06-05 16:51:55 +02:00
cloudhead a85e7f7442
node: Set TCP_KEEPALIVE on sockets
Ensures dead connections are not kept around longer than necessary.
Note that the ping/pong mechanism is more expensive and checks that the
session is active and healthy, while TCP_KEEPALIVE is lower level,
cheaper, and checks that the connection is still alive.
2024-05-22 14:46:08 +02:00
Lorenz Leutgeb a4e10f0344
fetch: upgrade gix crates
Upgrade the family of `gix` crates and resolve any breaking API changes.

Fixes RUSTEC-2024-0335[[0]].

[0]: https://rustsec.org/advisories/RUSTSEC-2024-0335.html

Co-authored-by: Fintan Halpenny <fintan.halpenny@gmail.com>
Signed-off-by: Fintan Halpenny <fintan.halpenny@gmail.com>
X-Clacks-Overhead: GNU Terry Pratchett
2024-05-17 13:27:18 +02:00
Fintan Halpenny c8a24d5584
node: report upload-pack progress
Emit the `UploadPack` events from the `upload_pack` method.

A wrapper type, `Reporter`, is introduced for implementing a `Write` instance
that will parse the given bytes as `gix_protocol::RemoteProgress`, if possible,
and emit it via the `Emitter`, and then write the bytes to the underlying
writer. This allows any subscribers to see the progress of an upload-pack, i.e.
`Compressing objects`, `Counting object`, `Enumerating objects`.

Signed-off-by: Fintan Halpenny <fintan.halpenny@gmail.com>
X-Clacks-Overhead: GNU Terry Pratchett
2024-05-15 10:07:56 +01:00
Dr Maxim Orlovsky a3cce22f7a
node: Patch dependencies for Tor/socks5 support 2024-05-06 22:19:36 +02:00
cloudhead 40f4383bbc
term: Implement content-aware pager
This is a pager (like `less`) that takes an `Element`, and dynamically
re-renders the element when the terminal size changes. This ensures that
the content is always properly wrapped and rendered.
2024-05-03 14:31:05 +02:00
cloudhead 2801403182
signals: Move signal handling to its own crate
We're going to share this code with `radicle-term`.
2024-05-03 14:30:51 +02:00
cloudhead e5df616ead
node: Protect against non-monotonic clocks
Many (most?) system clocks are not monotonic, and even though we're
getting a `LocalTime`, which *is* monotonic when using `now()`, it is
constructed from a `SystemTime` which isn't.
2024-04-30 10:56:37 +02:00
Sebastian Martinez 7fc3b73e88
Update radicle-surf to 0.21 2024-04-24 11:51:25 +02:00
cloudhead c07522365a
cargo: Run `cargo update` on workspace 2024-04-23 17:43:21 +02:00
cloudhead f17df88229
term: Update `inquire` crate 2024-04-15 17:12:36 +02:00
cloudhead a5212a7a88
term: Fix editor command with args
We add support for `EDITOR` being set to a command with arguments, eg.
`code --wait`.

Fixes dd6861f.
2024-04-04 10:52:36 +02:00
cloudhead 9cdf0aa1fd
Update radicle crates to 0.9.0 2024-03-26 11:56:27 +01:00
cloudhead f1f1313b6d
node: Update `netservices` to 0.8.0
The previous version was relying on a broken method from `socket2` that
switched non-blocking sockets to blocking.
2024-03-21 12:40:58 +01:00
Sebastian Martinez bdd1b238fc
Bump `radicle-surf` to 0.19.0 2024-03-11 12:27:27 +01:00
cloudhead b0fbbeed6b
node: Upgrade dependencies
Fixes issue with improperly closed connections.
2024-02-26 11:47:03 +01:00
cloudhead e12bff0871
cli: Update and remove some dependencies 2024-02-02 09:57:45 +01:00
cloudhead ebdaf0edd9
General dependency update
Left out some of the `gix-*` dependencies to be done separately after
review.
2024-01-18 13:30:26 +01:00
cloudhead ccc675b304
cli: Have a way of enabling logging in helper
Log to stderr if RUST_LOG is enabled in the remote helper.
2024-01-17 17:34:30 +01:00
cloudhead 045b3e7175
node: Increase process ulimit on start
Users have been having issues with the process soft file limit.
We set that to a reasonably high value to avoid problems.
2024-01-17 17:34:25 +01:00
cloudhead 25ca4c8b92
node: Upgrade `netservices` and `io-reactor`
There was an issue with the old version due to the use of `RawFd` as
peer IDs, since they are not unique for the lifetime of a process.

With this change, we use the new `ResourceId` type, though these are not
immediately available, as they are generated when the resource is
registered.
2024-01-11 12:03:53 +01:00
Sebastian Martinez 5331cf3bcf
radicle: Move `DataUri` to `common::DataUri` 2023-12-22 15:09:20 +01:00
Fintan Halpenny 47a440a384
radicle: expose shared logger
To be able to use log setup across the different components of
heartwood, expose a `logger` module from `radicle`. This also includes
a `test` logger.

These modules are guarded behind a `logger` feature flag, so that
other crates are not bringing any uneeded dependencies.

This allows logging to be setup in `radicle-cli-test` so that when a
test fails, the log output is present for debugging purposes.

Signed-off-by: Fintan Halpenny <fintan.halpenny@gmail.com>
X-Clacks-Overhead: GNU Terry Pratchett
2023-12-20 15:11:10 +01:00
Thomas Scholtes 48dedc6e7e
`rad-web` runs HTTP API and connects web app
Instead of `rad-web` just creating a session for an already running HTTP
API the command now starts the HTTP API, creates a session and opens the
authentication link.

Signed-off-by: Thomas Scholtes <geigerzaehler@axiom.fm>
2023-12-19 13:14:07 +01:00
Sebastian Martinez bdcaa60474
httpd: Update axum and hyper dependency 2023-12-15 12:08:43 +01:00
Fintan Halpenny f4dc224b3a
crypto: update ssh-key
There are two vulnerabilities that were due to `ssh-key`'s
dependencies[[0]][[1]].

Updating to ssh-key-0.6.3 removes the vulnerability[[0]], however,
there is no existing patch for [[1]] but it is being worked on.

[0]: https://rustsec.org/advisories/RUSTSEC-2022-0093
[1]: https://rustsec.org/advisories/RUSTSEC-2023-0071

Signed-off-by: Fintan Halpenny <fintan.halpenny@gmail.com>
X-Clacks-Overhead: GNU Terry Pratchett
2023-12-14 16:13:29 +00:00
Fintan Halpenny 924a2624a4
git: update git2-0.18.1
Update to git2-0.18.1, which also requires updating radicle-git-ext
and radicle-surf.

Signed-off-by: Fintan Halpenny <fintan.halpenny@gmail.com>
X-Clacks-Overhead: GNU Terry Pratchett
2023-12-04 11:11:36 +00:00
cloudhead ad7a3addb6
cli: Add `rad config` command
Displays the current configuration.

Also move to our tree-sitter highlighter for pretty-printing JSON and
remove the `json-color` dependency.
2023-11-30 10:46:32 +01:00
Sebastian Martinez 8277559ee0
Update radicle-surf to 0.17.1 2023-11-24 13:42:30 +01:00
Thomas Scholtes 3ccb6a5fac
Move `rad-web` binary to `radicle-httpd` package
Signed-off-by: Thomas Scholtes <geigerzaehler@axiom.fm>
2023-11-22 11:27:11 +01:00
cloudhead 40303cd8e1
term: Fix unicode display width hack
We were skipping certain glyphs due to the width calculation being
wrong. This fixes it, and we're able to display emojis correctly inside
tables now.
2023-11-17 15:05:39 +01:00