pub struct ReviewConfig {
pub context: usize,
pub context_step: usize,
pub diff: DiffLayout,
pub theme: ThemeName,
pub editor: Option<String>,
}Expand description
[review] — how the terminal reviewer looks, and how much of a file it
shows around a hunk.
Presentation only: it can widen what is displayed around a hunk and can never change which hunks exist. Enumeration is total and runs before any of this (ADR 0005, 0012).
Fields§
§context: usizeContext lines shown either side of a hunk before any expansion.
context_step: usizeLines one z at a context boundary row pulls in.
diff: DiffLayoutWhich diff layout a review opens in, before the reader says otherwise.
A DEFAULT, not a setting: s still toggles, and the toggle is recorded
per review. A review that has recorded a choice keeps it whatever this
says, so changing it never moves a layout under someone mid-read.
theme: ThemeNameWhich palette to wear. Default: dark.
editor: Option<String>The command that opens a file at a line when the reader presses e.
{file} and {line} say where the path and the line go. A command
naming neither gets the path appended and opens the file at the top.
Unset falls back to $VISUAL and then $EDITOR, which the application
layer reads — the environment is an adapter’s to touch, not this
module’s (ADR 0038).
Trait Implementations§
Source§impl Clone for ReviewConfig
impl Clone for ReviewConfig
Source§impl Debug for ReviewConfig
impl Debug for ReviewConfig
Source§impl Default for ReviewConfig
impl Default for ReviewConfig
Source§impl<'de> Deserialize<'de> for ReviewConfig
impl<'de> Deserialize<'de> for ReviewConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl Eq for ReviewConfig
Source§impl PartialEq for ReviewConfig
impl PartialEq for ReviewConfig
Source§impl Serialize for ReviewConfig
impl Serialize for ReviewConfig
impl StructuralPartialEq for ReviewConfig
Auto Trait Implementations§
impl Freeze for ReviewConfig
impl RefUnwindSafe for ReviewConfig
impl Send for ReviewConfig
impl Sync for ReviewConfig
impl Unpin for ReviewConfig
impl UnsafeUnpin for ReviewConfig
impl UnwindSafe for ReviewConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.