Skip to main content

Settings

Struct Settings 

Source
pub struct Settings {
Show 55 fields pub last_changelog_version: Option<String>, pub default_provider: Option<String>, pub default_model: Option<String>, pub default_thinking_level: Option<ThinkingLevel>, pub model_thinking_levels: Option<IndexMap<String, ThinkingLevel>>, pub transport: Option<Transport>, pub steering_mode: Option<QueueMode>, pub follow_up_mode: Option<QueueMode>, pub theme: Option<String>, pub compaction: Option<CompactionSettings>, pub branch_summary: Option<BranchSummarySettings>, pub retry: Option<RetrySettings>, pub hide_thinking_block: Option<bool>, pub show_cache_miss_notices: Option<bool>, pub external_editor: Option<String>, pub shell_path: Option<String>, pub quiet_startup: Option<BoolOr<Header>>, pub default_project_trust: Option<DefaultProjectTrust>, pub shell_command_prefix: Option<String>, pub npm_command: Option<Vec<String>>, pub collapse_changelog: Option<bool>, pub enable_install_telemetry: Option<bool>, pub enable_analytics: Option<bool>, pub tracking_id: Option<String>, pub device_id: Option<String>, pub packages: Option<Vec<PackageSource>>, pub extensions: Option<Vec<String>>, pub skills: Option<Vec<String>>, pub prompts: Option<Vec<String>>, pub themes: Option<Vec<String>>, pub enable_skill_commands: Option<bool>, pub terminal: Option<TerminalSettings>, pub images: Option<ImageSettings>, pub enabled_models: Option<Vec<String>>, pub default_tools: Option<Vec<String>>, pub double_escape_action: Option<DoubleEscapeAction>, pub tree_filter_mode: Option<TreeFilterMode>, pub thinking_budgets: Option<ThinkingBudgets>, pub editor_padding_x: Option<u8>, pub output_pad: Option<u8>, pub autocomplete_max_visible: Option<u8>, pub show_hardware_cursor: Option<bool>, pub markdown: Option<MarkdownSettings>, pub warnings: Option<WarningSettings>, pub codemode: Option<CodemodeSettings>, pub session_dir: Option<String>, pub http_proxy: Option<String>, pub http_idle_timeout_ms: Option<NumberOr<String>>, pub cache_warming: Option<CacheWarming>, pub websocket_connect_timeout_ms: Option<NumberOr<String>>, pub tui_mode: Option<TuiMode>, pub fullscreen_exit_output: Option<FullscreenExitOutput>, pub fullscreen_scrollbar: Option<Scrollbar>, pub fullscreen_copy_on_select: Option<bool>, pub fullscreen_wheel_scroll_lines: Option<NumberOr<Auto>>,
}

Fields§

§last_changelog_version: Option<String>§default_provider: Option<String>§default_model: Option<String>§default_thinking_level: Option<ThinkingLevel>§model_thinking_levels: Option<IndexMap<String, ThinkingLevel>>

Keyed by provider/modelId.

§transport: Option<Transport>§steering_mode: Option<QueueMode>§follow_up_mode: Option<QueueMode>§theme: Option<String>§compaction: Option<CompactionSettings>§branch_summary: Option<BranchSummarySettings>§retry: Option<RetrySettings>§hide_thinking_block: Option<bool>§show_cache_miss_notices: Option<bool>§external_editor: Option<String>§shell_path: Option<String>§quiet_startup: Option<BoolOr<Header>>§default_project_trust: Option<DefaultProjectTrust>§shell_command_prefix: Option<String>§npm_command: Option<Vec<String>>

Command for npm operations, in argv form.

§collapse_changelog: Option<bool>§enable_install_telemetry: Option<bool>§enable_analytics: Option<bool>§tracking_id: Option<String>§device_id: Option<String>§packages: Option<Vec<PackageSource>>§extensions: Option<Vec<String>>

Paths or patterns; !, + and - prefixes filter.

§skills: Option<Vec<String>>§prompts: Option<Vec<String>>§themes: Option<Vec<String>>§enable_skill_commands: Option<bool>§terminal: Option<TerminalSettings>§images: Option<ImageSettings>§enabled_models: Option<Vec<String>>§default_tools: Option<Vec<String>>

Tool names; +name and -name adjust the inherited list.

§double_escape_action: Option<DoubleEscapeAction>§tree_filter_mode: Option<TreeFilterMode>§thinking_budgets: Option<ThinkingBudgets>§editor_padding_x: Option<u8>

0 to 3.

§output_pad: Option<u8>

0 or 1.

§autocomplete_max_visible: Option<u8>

3 to 20.

§show_hardware_cursor: Option<bool>§markdown: Option<MarkdownSettings>§warnings: Option<WarningSettings>§codemode: Option<CodemodeSettings>§session_dir: Option<String>§http_proxy: Option<String>§http_idle_timeout_ms: Option<NumberOr<String>>

Milliseconds; pi also accepts a numeric string or "disabled".

§cache_warming: Option<CacheWarming>§websocket_connect_timeout_ms: Option<NumberOr<String>>

Milliseconds; pi also accepts a numeric string or "disabled".

§tui_mode: Option<TuiMode>§fullscreen_exit_output: Option<FullscreenExitOutput>§fullscreen_scrollbar: Option<Scrollbar>§fullscreen_copy_on_select: Option<bool>§fullscreen_wheel_scroll_lines: Option<NumberOr<Auto>>

Implementations§

Source§

impl Settings

Source

pub fn image_auto_resize(&self) -> bool

pi’s getImageAutoResize: images.autoResize, on when unset.

Trait Implementations§

Source§

impl Clone for Settings

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Settings

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for Settings

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl<'de> Deserialize<'de> for Settings

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl PartialEq for Settings

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl Serialize for Settings

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for Settings

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.