treewide: Spelling

Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
This commit is contained in:
Josh Soref 2026-04-29 07:18:22 -04:00
parent a101705012
commit 5dae2a8b58
62 changed files with 106 additions and 106 deletions

View File

@ -326,7 +326,7 @@ configured, and removed the IP addresses in favor of the DNS names.
### Better Support for Bare Repositories ### Better Support for Bare Repositories
[gitrepostiory-layout]: https://git-scm.com/docs/gitrepository-layout/2.49.0 [gitrepository-layout]: https://git-scm.com/docs/gitrepository-layout/2.49.0
Some improvements to supporting bare repositories have been made for `rad` and Some improvements to supporting bare repositories have been made for `rad` and
`git-remote-rad`. For `rad`, the `rad clone` command has learned a new flag `git-remote-rad`. For `rad`, the `rad clone` command has learned a new flag
@ -560,7 +560,7 @@ continue to look into other fixes required for getting full Windows support.
### Display Full Node IDs ### Display Full Node IDs
Node IDs and and node addresses have improved formatting. The CLI will output Node IDs and node addresses have improved formatting. The CLI will output
shortened forms of NIDs and addresses when the output is transient, and the full shortened forms of NIDs and addresses when the output is transient, and the full
form where it is presented to the user. This will allow you to be able to copy form where it is presented to the user. This will allow you to be able to copy
and paste these identifiers. and paste these identifiers.

View File

@ -66,7 +66,7 @@ take some time, so grab a coffee ☕.
--- ---
**Note**: the script currently outputs warnings about the `strip` command for **Note**: the script currently outputs warnings about the `strip` command for
MacOS builds. These are ok, and can be ignored. macOS builds. These are ok, and can be ignored.
--- ---
@ -194,7 +194,7 @@ script linked to on [Get Started][website].
### Release Branch ### Release Branch
At this point, a release branch should be created. This branch will used for At this point, a release branch should be created. This branch will be used for
*patch releases*, e.g. `1.5.1`, `1.5.2`, etc. *patch releases*, e.g. `1.5.1`, `1.5.2`, etc.
The branch must be named `releases/x.y`, similar to the tagged release, where The branch must be named `releases/x.y`, similar to the tagged release, where
@ -228,7 +228,7 @@ Patch Releases
After the `x.y.0` release is made, it may be beneficial, or even necessary, to After the `x.y.0` release is made, it may be beneficial, or even necessary, to
release patch releases of the binaries. These patch releases must be compatible release patch releases of the binaries. These patch releases must be compatible
with minor version that was released, otherwise the commits should not be with minor version that was released; otherwise, the commits should not be
included. included.
These changes may have been made on `master` and back-ported to the These changes may have been made on `master` and back-ported to the

View File

@ -18,7 +18,7 @@ RUN mkdir -p .cargo && cp build/config.toml .cargo/config.toml
# Install dependencies. # Install dependencies.
RUN apk update && apk add --no-cache git musl-dev xz asciidoctor RUN apk update && apk add --no-cache git musl-dev xz asciidoctor
# Install a pinned zig version with MacOS TBD v4 support # Install a pinned zig version with macOS TBD v4 support
ARG ZIG_VERSION="0.13.0" ARG ZIG_VERSION="0.13.0"
RUN wget -q https://ziglang.org/download/${ZIG_VERSION}/zig-linux-x86_64-${ZIG_VERSION}.tar.xz && \ RUN wget -q https://ziglang.org/download/${ZIG_VERSION}/zig-linux-x86_64-${ZIG_VERSION}.tar.xz && \
tar -xf zig-linux-x86_64-${ZIG_VERSION}.tar.xz && \ tar -xf zig-linux-x86_64-${ZIG_VERSION}.tar.xz && \

View File

@ -1,4 +1,4 @@
We initialize Jujutusu for our repository for use with a bare Git repo. We initialize Jujutsu for our repository for use with a bare Git repo.
```(stderr) ```(stderr)
$ jj git init --git-repo heartwood heartwood.jj $ jj git init --git-repo heartwood heartwood.jj

View File

@ -1,4 +1,4 @@
We initialize Jujutusu for our repository by colocating with Git. We initialize Jujutsu for our repository by colocating with Git.
```(stderr) ```(stderr)
$ jj git init --colocate $ jj git init --colocate

View File

@ -58,7 +58,7 @@ Removed z6MknSLrJoTcukLrE435hVNQT4JUhbvWLX4kUzqkEStBU8Vi
✓ Successfully cleaned rad:z42hL2jL4XNk6K8oHQaSWfMgCL7ji ✓ Successfully cleaned rad:z42hL2jL4XNk6K8oHQaSWfMgCL7ji
``` ```
And attempting to clean the repository again, or any non-existent And attempting to clean the repository again, or any nonexistent
repository, has no effect on the storage at all: repository, has no effect on the storage at all:
``` ~eve (fail) ``` ~eve (fail)

View File

@ -625,7 +625,7 @@ $ rad config schema
"default": 128 "default": 128
}, },
"outbound": { "outbound": {
"description": "Max outbound connections. Note that this can be higher than the *target* number.", "description": "Max outbound connections. Note that this can be greater than the *target* number.",
"type": "integer", "type": "integer",
"format": "uint", "format": "uint",
"minimum": 0, "minimum": 0,

View File

@ -33,7 +33,7 @@ As of 2025-05 we can't use `jj` to do push with options directly, see:
- <https://github.com/jj-vcs/jj/issues/4075> - <https://github.com/jj-vcs/jj/issues/4075>
- <https://github.com/jj-vcs/jj/pull/2098> - <https://github.com/jj-vcs/jj/pull/2098>
However, since we initialized Jujutusu to colocate with Git, we can just use However, since we initialized Jujutsu to colocate with Git, we can just use
Git to push. Git to push.
``` (stderr) ``` (stderr)

View File

@ -39,7 +39,7 @@ pub(super) enum Command {
/// Print a log of all raw operations on a COB /// Print a log of all raw operations on a COB
Log { Log {
/// Tepository ID of the repository to operate on /// Repository ID of the repository to operate on
#[arg(long, short, value_name = "RID")] #[arg(long, short, value_name = "RID")]
repo: RepoId, repo: RepoId,

View File

@ -204,7 +204,7 @@ pub(super) enum Command {
/// Update the identity by setting metadata in one of the identity payloads /// Update the identity by setting metadata in one of the identity payloads
/// ///
/// [example values: xyz.radicle.project name '"radicle-example"'] /// [example values: xyz.radicle.project name '"radicle-example"']
// TODO(erikili:) Value parsers do not operate on series of values, yet. This will // TODO(erikli:) Value parsers do not operate on series of values, yet. This will
// change with clap v5, so we can hopefully use `Vec<Payload>`. // change with clap v5, so we can hopefully use `Vec<Payload>`.
// - https://github.com/clap-rs/clap/discussions/5930#discussioncomment-12315889 // - https://github.com/clap-rs/clap/discussions/5930#discussioncomment-12315889
// - https://docs.rs/clap/latest/clap/_derive/index.html#arg-types // - https://docs.rs/clap/latest/clap/_derive/index.html#arg-types

View File

@ -200,9 +200,9 @@ impl FromStr for SortBy {
pub(super) enum ListMode { pub(super) enum ListMode {
/// List the notifications of the current repository, if in a working /// List the notifications of the current repository, if in a working
/// directory, otherwise all the repositories. /// directory; otherwise, all the repositories.
Contextual, Contextual,
/// List the notifications for a all repositories. /// List the notifications for all repositories.
All, All,
/// List the notifications for a specific repository. /// List the notifications for a specific repository.
ByRepo(RepoId), ByRepo(RepoId),

View File

@ -169,7 +169,7 @@ pub fn init(repo: git::Repository, args: Args, profile: &profile::Profile) -> an
} }
if args.set_upstream || git::branch_remote(&repo, proj.default_branch()).is_err() { if args.set_upstream || git::branch_remote(&repo, proj.default_branch()).is_err() {
// Setup eg. `master` -> `rad/master` // Setup, e.g. `master` -> `rad/master`
radicle::git::set_upstream( radicle::git::set_upstream(
&repo, &repo,
&*radicle::rad::REMOTE_NAME, &*radicle::rad::REMOTE_NAME,
@ -244,7 +244,7 @@ pub fn init_existing(
)?; )?;
if args.set_upstream { if args.set_upstream {
// Setup eg. `master` -> `rad/master` // Setup, e.g. `master` -> `rad/master`
radicle::git::set_upstream( radicle::git::set_upstream(
&working, &working,
&*radicle::rad::REMOTE_NAME, &*radicle::rad::REMOTE_NAME,

View File

@ -185,7 +185,7 @@ pub(super) enum Command {
/// Show the status /// Show the status
Status { Status {
/// If node is running, only print the Node ID and exit, otherwise exit with a non-zero exit status. /// If node is running, only print the Node ID and exit; otherwise, exit with a non-zero exit status.
#[arg(long, value_parser = OnlyParser)] #[arg(long, value_parser = OnlyParser)]
only: Option<Only>, only: Option<Only>,
}, },

View File

@ -33,7 +33,7 @@ pub fn start(
return Ok(()); return Ok(());
} }
let envs = if profile.keystore.is_encrypted()? { let envs = if profile.keystore.is_encrypted()? {
// Ask passphrase here, otherwise it'll be a fatal error when running the daemon // Ask passphrase here; otherwise, it'll be a fatal error when running the daemon
// without `RAD_PASSPHRASE`. // without `RAD_PASSPHRASE`.
let validator = term::io::PassphraseValidator::new(profile.keystore.clone()); let validator = term::io::PassphraseValidator::new(profile.keystore.clone());
let passphrase = if let Some(phrase) = profile::env::passphrase() { let passphrase = if let Some(phrase) = profile::env::passphrase() {

View File

@ -43,7 +43,7 @@ impl inquire::validator::StringValidator for PassphraseValidator {
} }
} }
/// Get the signer. First we try getting it from ssh-agent, otherwise we prompt the user, /// Get the signer. First we try getting it from ssh-agent; otherwise, we prompt the user,
/// if we're connected to a TTY. /// if we're connected to a TTY.
pub fn signer(profile: &Profile) -> anyhow::Result<BoxedDevice> { pub fn signer(profile: &Profile) -> anyhow::Result<BoxedDevice> {
match profile.signer() { match profile.signer() {

View File

@ -9,7 +9,7 @@ pub struct UploadPack {
/// Keep track of which remotes are being uploaded to, removing any that /// Keep track of which remotes are being uploaded to, removing any that
/// have completed. /// have completed.
remotes: BTreeSet<NodeId>, remotes: BTreeSet<NodeId>,
/// Keep track of how long we've been transmitting for to calculate /// Keep track of how long we've been transmitting to calculate
/// throughput. /// throughput.
timer: Instant, timer: Instant,
} }

View File

@ -152,7 +152,7 @@ fn test_cob_replication() {
log::debug!(target: "test", "Issue {} created", issue.id()); log::debug!(target: "test", "Issue {} created", issue.id());
// Make sure that Bob's issue refs announcement has a different timestamp than his fork's // Make sure that Bob's issue refs announcement has a different timestamp than his fork's
// announcement, otherwise Alice will consider it stale. // announcement; otherwise, Alice will consider it stale.
std::thread::sleep(std::time::Duration::from_millis(3)); std::thread::sleep(std::time::Duration::from_millis(3));
bob.handle.announce_refs_for(rid, [bob.id]).unwrap(); bob.handle.announce_refs_for(rid, [bob.id]).unwrap();

View File

@ -6,7 +6,7 @@
//! is not handled by the process, i.e., no signal handler is installed. //! is not handled by the process, i.e., no signal handler is installed.
//! The default behaviour in this case is to terminate the process with an //! The default behaviour in this case is to terminate the process with an
//! exit code of 141 (128 + 13). Such lack of a signal handler is also //! exit code of 141 (128 + 13). Such lack of a signal handler is also
//! indidcated by `SIG_DFL`. //! indicated by `SIG_DFL`.
//! //!
//! Rust (since 1.62) ignores `SIGPIPE` by default, see [issue #6529]. //! Rust (since 1.62) ignores `SIGPIPE` by default, see [issue #6529].
//! Ignorance in this case means that the signal handler is set to //! Ignorance in this case means that the signal handler is set to

View File

@ -110,7 +110,7 @@ impl Environment {
/// Path to the working directory of the user with the given alias. /// Path to the working directory of the user with the given alias.
/// Tests that need to act on multiple repositories should crate /// Tests that need to act on multiple repositories should crate
/// subdirecories within this directory. /// subdirectories within this directory.
pub fn work(&self, has_alias: &impl HasAlias) -> PathBuf { pub fn work(&self, has_alias: &impl HasAlias) -> PathBuf {
self.unix_home(has_alias).join("work") self.unix_home(has_alias).join("work")
} }
@ -185,7 +185,7 @@ impl Environment {
} }
} }
/// Create a new profile using a the default configuration from [`Environment::config`]. /// Create a new profile using the default configuration from [`Environment::config`].
pub fn profile(&mut self, alias: &'static str) -> Profile { pub fn profile(&mut self, alias: &'static str) -> Profile {
self.profile_with(self.config(alias)) self.profile_with(self.config(alias))
} }

View File

@ -270,7 +270,7 @@ impl ProtocolStage for CanonicalId {
let verified = repo let verified = repo
.identity_doc_at( .identity_doc_at(
*s.canonical_rad_id() *s.canonical_rad_id()
.expect("ensure we got canonicdal 'rad/id' ref"), .expect("ensure we got canonical 'rad/id' ref"),
) )
.map_err(|err| error::Prepare::Verification { .map_err(|err| error::Prepare::Verification {
remote: self.remote, remote: self.remote,
@ -399,7 +399,7 @@ pub struct SigrefsAt {
impl ProtocolStage for SigrefsAt { impl ProtocolStage for SigrefsAt {
fn ls_refs(&self) -> Option<NonEmpty<RefPrefix>> { fn ls_refs(&self) -> Option<NonEmpty<RefPrefix>> {
// N.b. the `Oid`s are known but the `rad/sigrefs` are still // N.b. the `Oid`s are known but the `rad/sigrefs` are still
// asked for to mark them for updating the fetch state. // requested to mark them for updating the fetch state.
NonEmpty::collect( NonEmpty::collect(
self.refs_at self.refs_at
.iter() .iter()
@ -409,7 +409,7 @@ impl ProtocolStage for SigrefsAt {
) )
} }
// We only asked for `rad/sigrefs` so we should only get // We only requested `rad/sigrefs` so we should only get
// `rad/sigrefs`. // `rad/sigrefs`.
fn ref_filter(&self, r: Ref) -> Option<ReceivedRef> { fn ref_filter(&self, r: Ref) -> Option<ReceivedRef> {
let (refname, tip) = refs::unpack_ref(r).ok()?; let (refname, tip) = refs::unpack_ref(r).ok()?;

View File

@ -78,7 +78,7 @@ pub struct Handle {
pub(crate) controller: reactor::Controller, pub(crate) controller: reactor::Controller,
/// Whether a shutdown was initiated or not. Prevents attempting to shutdown twice. /// Whether or not a shutdown was initiated. Prevents attempting to shutdown twice.
shutdown: Arc<AtomicBool>, shutdown: Arc<AtomicBool>,
/// Publishes events to subscribers. /// Publishes events to subscribers.
emitter: Emitter<Event>, emitter: Emitter<Event>,
@ -353,7 +353,7 @@ impl radicle::node::Handle for Handle {
} }
fn shutdown(self) -> Result<(), Error> { fn shutdown(self) -> Result<(), Error> {
// If the current value is `false`, set it to `true`, otherwise error. // If the current value is `false`, set it to `true`; otherwise, error.
if self if self
.shutdown .shutdown
.compare_exchange(false, true, Ordering::SeqCst, Ordering::SeqCst) .compare_exchange(false, true, Ordering::SeqCst, Ordering::SeqCst)

View File

@ -2008,7 +2008,7 @@ fn test_announcement_message_amplification() {
s.elapsed() < LocalDuration::from_mins(3) s.elapsed() < LocalDuration::from_mins(3)
}); });
// Ensure nodes are all connected, otherwise skip this test run. // Ensure nodes are all connected; otherwise, skip this test run.
if alice.sessions().connected().count() != 4 { if alice.sessions().connected().count() != 4 {
continue; continue;
} }

View File

@ -722,7 +722,7 @@ where
ChannelsConfig::new(FETCH_TIMEOUT) ChannelsConfig::new(FETCH_TIMEOUT)
.with_reader_limit(reader_limit), .with_reader_limit(reader_limit),
) else { ) else {
log::debug!(target: "wire", "Peer attempted to open already-open stream stream {stream}"); log::debug!(target: "wire", "Peer attempted to open already-open stream {stream}");
continue; continue;
}; };
@ -1094,7 +1094,7 @@ pub fn dial<G: Ecdh<Pk = NodeId>>(
// In proxy mode, simply use the configured proxy address. // In proxy mode, simply use the configured proxy address.
// This takes precedence over any global proxy. // This takes precedence over any global proxy.
AddressConfig::Proxy { address } => Ok((*address).into()), AddressConfig::Proxy { address } => Ok((*address).into()),
// In "forward" mode, if a global proxy is set, we use that, otherwise // In "forward" mode, if a global proxy is set, we use that; otherwise,
// we treat the address as a regular DNS name. // we treat the address as a regular DNS name.
AddressConfig::Forward => Ok(global_proxy AddressConfig::Forward => Ok(global_proxy
.map(Into::into) .map(Into::into)
@ -1110,7 +1110,7 @@ pub fn dial<G: Ecdh<Pk = NodeId>>(
// Determine what address to establish a TCP connection with, given the remote peer // Determine what address to establish a TCP connection with, given the remote peer
// address and our node configuration. // address and our node configuration.
let inet_addr: NetAddr<InetHost> = match (&remote_addr.host, config.proxy) { let inet_addr: NetAddr<InetHost> = match (&remote_addr.host, config.proxy) {
// For IP and DNS addresses, use the global proxy if set, otherwise use the address as-is. // For IP and DNS addresses, use the global proxy if set; otherwise, use the address as-is.
(HostName::Ip(_), Some(proxy)) => proxy.into(), (HostName::Ip(_), Some(proxy)) => proxy.into(),
(HostName::Ip(ip), None) => NetAddr::new(InetHost::Ip(*ip), remote_addr.port), (HostName::Ip(ip), None) => NetAddr::new(InetHost::Ip(*ip), remote_addr.port),
(HostName::Dns(_), Some(proxy)) => proxy.into(), (HostName::Dns(_), Some(proxy)) => proxy.into(),

View File

@ -149,7 +149,7 @@ impl Handle {
// Notifications are only posted for pulls, not clones. // Notifications are only posted for pulls, not clones.
if let Some(mut store) = notifs { if let Some(mut store) = notifs {
// Only create notifications for repos that we have // Only create notifications for repos that we have
// contributed to in some way, otherwise our inbox will // contributed to in some way; otherwise, our inbox will
// be flooded by all the repos we are seeding. // be flooded by all the repos we are seeding.
if repo.remote(&storage.info().key).is_ok() { if repo.remote(&storage.info().key).is_ok() {
notify(&rid, &applied, &mut store)?; notify(&rid, &applied, &mut store)?;

View File

@ -8,7 +8,7 @@ use crate::wire;
/// Message stream deserializer. /// Message stream deserializer.
/// ///
/// Used to for example turn a byte stream into network messages. /// Used, for example, to turn a byte stream into network messages.
#[derive(Debug)] #[derive(Debug)]
pub struct Deserializer<const B: usize, D = Message> { pub struct Deserializer<const B: usize, D = Message> {
unparsed: BoundedVec<u8, B>, unparsed: BoundedVec<u8, B>,

View File

@ -463,7 +463,7 @@ impl Queue {
} }
/// Try to dequeue the next [`QueuedFetch`], but only if the `predicate` /// Try to dequeue the next [`QueuedFetch`], but only if the `predicate`
/// holds, otherwise it will be pushed back to the front of the queue. /// holds; otherwise, it will be pushed back to the front of the queue.
pub(super) fn try_dequeue<P>(&mut self, predicate: P) -> Option<QueuedFetch> pub(super) fn try_dequeue<P>(&mut self, predicate: P) -> Option<QueuedFetch>
where where
P: FnOnce(&QueuedFetch) -> bool, P: FnOnce(&QueuedFetch) -> bool,

View File

@ -100,7 +100,7 @@ pub const MAX_CONNECTION_ATTEMPTS: usize = 3;
/// How far back from the present time should we request gossip messages when connecting to a peer, /// How far back from the present time should we request gossip messages when connecting to a peer,
/// when we come online for the first time. /// when we come online for the first time.
pub const INITIAL_SUBSCRIBE_BACKLOG_DELTA: LocalDuration = LocalDuration::from_mins(60 * 24); pub const INITIAL_SUBSCRIBE_BACKLOG_DELTA: LocalDuration = LocalDuration::from_mins(60 * 24);
/// When subscribing, what margin of error do we give ourselves. A igher delta means we ask for /// When subscribing, what margin of error do we give ourselves. A greater delta means we ask for
/// messages further back than strictly necessary, to account for missed messages. /// messages further back than strictly necessary, to account for missed messages.
pub const SUBSCRIBE_BACKLOG_DELTA: LocalDuration = LocalDuration::from_mins(3); pub const SUBSCRIBE_BACKLOG_DELTA: LocalDuration = LocalDuration::from_mins(3);
/// Minimum amount of time to wait before reconnecting to a peer. /// Minimum amount of time to wait before reconnecting to a peer.
@ -648,7 +648,7 @@ where
/// Find the closest `n` peers by proximity in seeding graphs. /// Find the closest `n` peers by proximity in seeding graphs.
/// Returns a sorted list from the closest peer to the furthest. /// Returns a sorted list from the closest peer to the furthest.
/// Peers with more seedings in common score score higher. /// Peers with more seedings in common score higher.
#[allow(unused)] #[allow(unused)]
pub fn closest_peers(&self, n: usize) -> Vec<NodeId> { pub fn closest_peers(&self, n: usize) -> Vec<NodeId> {
todo!() todo!()
@ -1489,7 +1489,7 @@ where
} }
} }
// Discard announcement messages we've already seen, otherwise update our last seen time. // Discard announcement messages we've already seen; otherwise, update our last seen time.
let relay = match self.db.gossip_mut().announced(announcer, announcement) { let relay = match self.db.gossip_mut().announced(announcer, announcement) {
Ok(Some(id)) => { Ok(Some(id)) => {
log::debug!( log::debug!(
@ -1942,7 +1942,7 @@ where
let now = self.clock(); let now = self.clock();
let filter = self.filter(); let filter = self.filter();
// TODO: Only subscribe to outbound connections, otherwise we will consume too // TODO: Only subscribe to outbound connections; otherwise, we will consume too
// much bandwidth. // much bandwidth.
// If we've been previously connected to the network, we'll have received gossip messages. // If we've been previously connected to the network, we'll have received gossip messages.
@ -2806,7 +2806,7 @@ impl fmt::Display for DisconnectReason {
/// Result of a project lookup. /// Result of a project lookup.
#[derive(Debug)] #[derive(Debug)]
pub struct Lookup { pub struct Lookup {
/// Whether the project was found locally or not. /// Whether or not the project was found locally.
pub local: Option<Doc>, pub local: Option<Doc>,
/// A list of remote peers on which the project is known to exist. /// A list of remote peers on which the project is known to exist.
pub remote: Vec<NodeId>, pub remote: Vec<NodeId>,

View File

@ -46,7 +46,7 @@ pub trait Store {
ann: &Announcement, ann: &Announcement,
) -> Result<Option<AnnouncementId>, Error>; ) -> Result<Option<AnnouncementId>, Error>;
/// Set whether a message should be relayed or not. /// Set whether or not a message should be relayed.
fn set_relay(&mut self, id: AnnouncementId, relay: RelayStatus) -> Result<(), Error>; fn set_relay(&mut self, id: AnnouncementId, relay: RelayStatus) -> Result<(), Error>;
/// Return messages that should be relayed. /// Return messages that should be relayed.

View File

@ -31,7 +31,7 @@ where
/// with the set of commits of the other [`Did`]s. /// with the set of commits of the other [`Did`]s.
/// ///
/// If a quorum is found, then it is also ensured that the new head commit /// If a quorum is found, then it is also ensured that the new head commit
/// is a descendant of the current canonical commit, otherwise the commits /// is a descendant of the current canonical commit; otherwise, the commits
/// are considered diverging. /// are considered diverging.
/// ///
/// # Errors /// # Errors

View File

@ -36,7 +36,7 @@ impl TerminalFile {
/// What file is used for text output. /// What file is used for text output.
static TERMINAL: AtomicI32 = AtomicI32::new(TerminalFile::Stdout as i32); static TERMINAL: AtomicI32 = AtomicI32::new(TerminalFile::Stdout as i32);
/// Whether paint styling is enabled or not. /// Whether or not paint styling is enabled.
static ENABLED: AtomicBool = AtomicBool::new(true); static ENABLED: AtomicBool = AtomicBool::new(true);
/// Whether paint styling should be forced. /// Whether paint styling should be forced.
static FORCED: AtomicBool = AtomicBool::new(false); static FORCED: AtomicBool = AtomicBool::new(false);

View File

@ -136,7 +136,7 @@ impl Editor {
{ {
use std::os::fd::{AsRawFd as _, FromRawFd as _}; use std::os::fd::{AsRawFd as _, FromRawFd as _};
// We duplicate the stderr file descriptor to pass it to the child process, otherwise, if // We duplicate the stderr file descriptor to pass it to the child process; otherwise, if
// we simply pass the `RawFd` of our stderr, `Command` will close our stderr when the // we simply pass the `RawFd` of our stderr, `Command` will close our stderr when the
// child exits. // child exits.

View File

@ -52,7 +52,7 @@ pub trait Issues {
}) })
} }
/// List all closed issues with `CloseReasion::Other` in the store. /// List all closed issues with `CloseReason::Other` in the store.
fn closed(&self) -> Result<Self::Iter<'_>, Self::Error> { fn closed(&self) -> Result<Self::Iter<'_>, Self::Error> {
self.list_by_status(&State::Closed { self.list_by_status(&State::Closed {
reason: CloseReason::Other, reason: CloseReason::Other,

View File

@ -54,7 +54,7 @@ pub enum LoadError {
/// Operations are applied to an accumulator to yield a final state. /// Operations are applied to an accumulator to yield a final state.
#[derive(Debug, Clone, PartialEq, Eq, Serialize)] #[derive(Debug, Clone, PartialEq, Eq, Serialize)]
pub struct Op<A> { pub struct Op<A> {
/// Id of the entry under which this operation lives. /// ID of the entry under which this operation lives.
pub id: EntryId, pub id: EntryId,
/// The action carried out by this operation. /// The action carried out by this operation.
pub actions: NonEmpty<A>, pub actions: NonEmpty<A>,

View File

@ -809,7 +809,7 @@ impl Patch {
// In this case, since there is not enough information to determine // In this case, since there is not enough information to determine
// whether the action is authorized or not, we simply ignore it. // whether the action is authorized or not, we simply ignore it.
// It's likely that the target object was redacted, and we can't // It's likely that the target object was redacted, and we can't
// verify whether the action would have been allowed or not. // verify whether or not the action would have been allowed.
Ok(()) Ok(())
} }
} }
@ -943,7 +943,7 @@ impl Patch {
return Ok(()); return Ok(());
}; };
if let Some(rev) = rev { if let Some(rev) = rev {
// Insert a review if there isn't already one. Otherwise we just ignore // Insert a review if there isn't already one. Otherwise, we just ignore
// this operation // this operation
if let btree_map::Entry::Vacant(e) = rev.reviews.entry(author) { if let btree_map::Entry::Vacant(e) = rev.reviews.entry(author) {
let id = ReviewId(entry); let id = ReviewId(entry);

View File

@ -520,7 +520,7 @@ where
/// Add actions to this transaction. /// Add actions to this transaction.
/// Note that we cannot implement [`std::iter::Extend`] because [`Self::push`] /// Note that we cannot implement [`std::iter::Extend`] because [`Self::push`]
/// validates the action being pushed, and therefore is falliable. /// validates the action being pushed, and therefore is fallible.
pub fn extend<I: IntoIterator<Item = T::Action>>(&mut self, actions: I) -> Result<(), Error> { pub fn extend<I: IntoIterator<Item = T::Action>>(&mut self, actions: I) -> Result<(), Error> {
for action in actions { for action in actions {
self.push(action)?; self.push(action)?;

View File

@ -26,7 +26,7 @@ pub enum Error {
/// This error indicates that the operations are not being applied /// This error indicates that the operations are not being applied
/// in causal order, which is a requirement for this CRDT. /// in causal order, which is a requirement for this CRDT.
/// ///
/// For example, this can occur if an operation references anothern operation /// For example, this can occur if an operation references another operation
/// that hasn't happened yet. /// that hasn't happened yet.
#[error("causal dependency {0:?} missing")] #[error("causal dependency {0:?} missing")]
Missing(EntryId), Missing(EntryId),

View File

@ -794,7 +794,7 @@ mod tests {
// Note for the next two cases we only give enough merge base // Note for the next two cases we only give enough merge base
// information so that the quorum fails. If we provided all // information so that the quorum fails. If we provided all
// `merge_bases`, it would mean that c0 could be chosen as the quourum. // `merge_bases`, it would mean that c0 could be chosen as the quorum.
let mut cq = CommitQuorum::new([c2, b2].iter(), 2); let mut cq = CommitQuorum::new([c2, b2].iter(), 2);
cq.found_merge_bases([MergeBase { cq.found_merge_bases([MergeBase {
a: b2.id(), a: b2.id(),

View File

@ -1492,7 +1492,7 @@ pub(crate) mod properties {
/// the `short` alias, both sets of results will return. For the `long` /// the `short` alias, both sets of results will return. For the `long`
/// alias, only its results will return. /// alias, only its results will return.
/// ///
/// It is also expected that the lookup is case insensitive. /// It is also expected that the lookup is case-insensitive.
pub fn test_reverse_lookup(store: &impl AliasStore, AliasInput { short, long }: AliasInput) { pub fn test_reverse_lookup(store: &impl AliasStore, AliasInput { short, long }: AliasInput) {
let (short, short_ids) = short; let (short, short_ids) = short;
let (long, long_ids) = long; let (long, long_ids) = long;

View File

@ -246,7 +246,7 @@ pub struct ConnectionLimits {
/// Max inbound connections. /// Max inbound connections.
pub inbound: LimitConnectionsInbound, pub inbound: LimitConnectionsInbound,
/// Max outbound connections. Note that this can be higher than the *target* number. /// Max outbound connections. Note that this can be greater than the *target* number.
pub outbound: LimitConnectionsOutbound, pub outbound: LimitConnectionsOutbound,
} }
@ -671,8 +671,8 @@ impl Config {
node::Features::SEED node::Features::SEED
} }
/// Return the configured user agent, if set. Otherwise fall back to the /// Return the configured user agent, if set. Otherwise, fall back to the
/// unintetesting value `"/radicle/"`. /// uninteresting value `"/radicle/"`.
pub fn user_agent(&self) -> UserAgent { pub fn user_agent(&self) -> UserAgent {
match self.user_agent.as_ref() { match self.user_agent.as_ref() {
Some(agent) => agent.clone(), Some(agent) => agent.clone(),

View File

@ -70,7 +70,7 @@ impl UploadPack {
/// Construct a `UploadPack::Done` event. /// Construct a `UploadPack::Done` event.
/// ///
/// If `error` is `None` the process finished successfully, otherwise it /// If `error` is `None` the process finished successfully; otherwise, it
/// finished with an error. /// finished with an error.
pub fn done(rid: RepoId, remote: NodeId, status: ExitStatus) -> Self { pub fn done(rid: RepoId, remote: NodeId, status: ExitStatus) -> Self {
Self::Done { Self::Done {

View File

@ -4,7 +4,7 @@ create table if not exists "repository-notifications" (
"repo" text not null, "repo" text not null,
-- Git reference name related to this update. -- Git reference name related to this update.
"ref" text not null, "ref" text not null,
-- Notification read status. Null if unread, otherwise the time it was read. -- Notification read status. Null if unread; otherwise, the time it was read.
"status" integer default null, "status" integer default null,
-- Old head of the branch before update (OID or `null`). -- Old head of the branch before update (OID or `null`).
"old" text, "old" text,

View File

@ -125,7 +125,7 @@ impl Announcer {
/// Complete the [`Announcer`] process returning a [`AnnouncerResult`]. /// Complete the [`Announcer`] process returning a [`AnnouncerResult`].
/// ///
/// If the target for the [`Announcer`] has been reached, then the result /// If the target for the [`Announcer`] has been reached, then the result
/// will be [`AnnouncerResult::Success`], otherwise, it will be /// will be [`AnnouncerResult::Success`]; otherwise, it will be
/// [`AnnouncerResult::TimedOut`]. /// [`AnnouncerResult::TimedOut`].
pub fn timed_out(self) -> AnnouncerResult { pub fn timed_out(self) -> AnnouncerResult {
match self.is_target_reached() { match self.is_target_reached() {
@ -144,7 +144,7 @@ impl Announcer {
/// Check if the [`Announcer`] can continue synchronizing with more nodes. /// Check if the [`Announcer`] can continue synchronizing with more nodes.
/// If there are no more nodes, then [`NoNodes`] is returned in the /// If there are no more nodes, then [`NoNodes`] is returned in the
/// [`ControlFlow::Break`], otherwise the [`Announcer`] is returned as-is in /// [`ControlFlow::Break`]; otherwise, the [`Announcer`] is returned as-is in
/// the [`ControlFlow::Continue`]. /// the [`ControlFlow::Continue`].
// TODO(finto): I'm not sure this is needed with the change to the target // TODO(finto): I'm not sure this is needed with the change to the target
// logic. Since we can reach the replication factor OR the preferred seeds, // logic. Since we can reach the replication factor OR the preferred seeds,

View File

@ -187,7 +187,7 @@ where
// The fact that the parent OID is a hash over all previous history // The fact that the parent OID is a hash over all previous history
// makes it *incredibly unlikely* or rather *practically impossible* // makes it *incredibly unlikely* or rather *practically impossible*
// that the same `/refs` blob re-appears in previous history. // that the same `/refs` blob re-appears in previous history.
// Thus, we can spare oureselves walking the history. // Thus, we can spare ourselves walking the history.
return Ok(head); return Ok(head);
} }
@ -386,7 +386,7 @@ impl Commit {
// for `rad/refs/sigrefs-parent` to target. The zero OID would // for `rad/refs/sigrefs-parent` to target. The zero OID would
// be a candidate, but it is filtered out in [`Refs`]. // be a candidate, but it is filtered out in [`Refs`].
// Upgrading to `FeatureLevel::Parent` is not a good idea // Upgrading to `FeatureLevel::Parent` is not a good idea
// either, otherwise any history containing this commit // either; otherwise, any history containing this commit
// would be at that level from the root onwards. // would be at that level from the root onwards.
// Pattern 2: // Pattern 2:

View File

@ -22,7 +22,7 @@ pub struct MockStorage {
pub info: crate::git::UserInfo, pub info: crate::git::UserInfo,
/// All refs keyed by RID. /// All refs keyed by RID.
/// Each value is a map of refs keyed by node Id (public key). /// Each value is a map of refs keyed by node ID (public key).
pub repos: HashMap<RepoId, MockRepository>, pub repos: HashMap<RepoId, MockRepository>,
} }

View File

@ -2,7 +2,7 @@
set -e set -e
# Attempt to install `asciidoctor` on Debian, Arch Linux and MacOS. # Attempt to install `asciidoctor` on Debian, Arch Linux and macOS.
install() { install() {
os="$(uname)" os="$(uname)"
@ -16,7 +16,7 @@ install() {
# Arch Linux # Arch Linux
pacman -Sy --noconfirm asciidoctor pacman -Sy --noconfirm asciidoctor
fi ;; fi ;;
Darwin) # MacOS Darwin) # macOS
if command -v brew >/dev/null 2>&1; then if command -v brew >/dev/null 2>&1; then
brew install asciidoctor brew install asciidoctor
fi ;; fi ;;

View File

@ -58,7 +58,7 @@ This will give us the following workflow for constructing test scenarios:
- [ ] Isolation between simulations and main network. - [ ] Isolation between simulations and main network.
- [ ] Different node versions within a simulation. - [ ] Different node versions within a simulation.
- [ ] Cross platform ([Windows](https://github.com/dockur/windows), Linux & [MacOS](https://github.com/dockur/macos)). - [ ] Cross platform ([Windows](https://github.com/dockur/windows), Linux & [macOS](https://github.com/dockur/macos)).
- [ ] Realistic load generation. - [ ] Realistic load generation.
- [ ] Invariant assertion across simulation network. - [ ] Invariant assertion across simulation network.
- [ ] Teardown and Artifact collection. - [ ] Teardown and Artifact collection.