pub struct Config {
    pub git_protocol: GitProtocol,
    pub editor: Option<String>,
    pub prompt: Prompt,
    pub pager: Option<String>,
    pub aliases: HashMap<String, String>,
    pub http_unix_socket: Option<String>,
    pub browser: Option<String>,
}
Expand description

Config representation for gh CLI.

Fields

git_protocol: GitProtocol

What protocol to use when performing git operations.

editor: Option<String>

What editor gh should run when creating issues, pull requests, etc. If blank, will refer to environment.

prompt: Prompt

When to interactively prompt. This is a global config that cannot be overridden by hostname.

pager: Option<String>

A pager program to send command output to, e.g. “less”. Set the value to “cat” to disable the pager.

aliases: HashMap<String, String>

Aliases allow you to create nicknames for gh commands.

http_unix_socket: Option<String>

The path to a unix socket through which send HTTP connections. If blank, HTTP traffic will be handled by default transport.

browser: Option<String>

What web browser gh should use when opening URLs. If blank, will refer to environment.

Implementations

Loads a config from the default path.

Loads all host configs from the specified path.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Deserialize this value from the given Serde deserializer. Read more

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

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

The resulting type after obtaining ownership.

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

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

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.