diff options
| author | Ben Beasley <code@musicinmybrain.net> | 2026-01-31 02:15:05 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-01-30 18:15:05 -0800 |
| commit | 2c58505f6b50c5a89e8fbb8dcf22d678826d1694 (patch) | |
| tree | 656bce9b0f4e25749e97388d5bc3f5797de850a6 /dist-workspace.toml | |
| parent | docs(README): update links (#3116) (diff) | |
| download | atuin-2c58505f6b50c5a89e8fbb8dcf22d678826d1694.zip | |
chore(deps): update whoami dependency to v2 (#3118)
<!-- Thank you for making a PR! Bug fixes are always welcome, but if
you're adding a new feature or changing an existing one, we'd really
appreciate if you open an issue, post on the forum, or drop in on
Discord -->
In the [2.0.0](https://github.com/ardaku/whoami/releases/tag/v2.0.0)
series, `whoami` removed all infallible function variants, and removed
the `fallible` module, moving those functions to the root module.
Therefore, I replaced `whoami::fallible::hostname` with
`whoami::hostname` (the same function with the same signature, just
moved to the root module).
For `whoami::username`, the infallible function that `atuin` was using
before is gone, and we must add error handling. I chose to fall back to
the string `"unknown-user"` if getting the username fails, just as
`"unknown-host"` is already the fallback when getting the hostname
fails. This seemed reasonable to me, but it’s worth double-checking if
there could be any unintended consequences, especially if `unknown-user`
happens to be a real, valid username on the system. The alternatives I
can see would be to panic on failure or to amend the signature of
`get_username()` and all of its call sites with some kind of more
graceful error handling (what?).
## Checks
- [x] I am happy for maintainers to push small adjustments to this PR,
to speed up the review cycle
- [x] I have checked that there are no existing pull requests for the
same thing
Diffstat (limited to 'dist-workspace.toml')
0 files changed, 0 insertions, 0 deletions
