Repository: starship/starship
File: src/bug_report.rs (Rust)

Code before:
use std::fs;
use std::path::PathBuf;
use std::time::Duration;

pub fn create() {
    println!("{}\n", shadow::VERSION.trim());
    let os_info = os_info::get();

    let environment = Environment {
        os_type: os_info.os_type(),
        os_version: os_info.version().clone(),
        shell_info: get_shell_info(),
        terminal_info: get_terminal_info(),
        starship_config: get_starship_config(),
    };

    let issue_body = get_github_issue_body(&environment);

    println!(
        "{}\n{issue_body}\n\n",
        Style::new().bold().paint("Generated bug report:")
    );
    println!("Forward the pre-filled report above to GitHub in your browser?");
    println!("{} To avoid any sensitive data from being exposed, please review the included information before proceeding. Data forwarded to GitHub is subject to GitHub's privacy policy.", Style::new().bold().paint("Warning:"));
    println!(
        "Enter `{}`, or anything else to decline, and `{}` to confirm your choice:\n",
        Style::new().bold().paint("y"),
        Style::new().bold().paint("Enter key")
    );

    let mut input = String::new();
    let _ = std::io::stdin().read_line(&mut input);

    if input.trim() == "y" {
        let link = make_github_issue_link(&issue_body);
        if let Err(e) = open::that(&link) {
            println!("Failed to open issue report in your browser: {}", e);
            println!("Please copy the above report and open an issue manually, or try opening the following link:\n{link}");
        }
    } else {
        println!("Will not open an issue in your browser! Please copy the above report and open an issue manually.");
    }
    println!("Thanks for using the Starship bug report tool!");
}

const UNKNOWN_SHELL: &str = "<unknown shell>";
const UNKNOWN_TERMINAL: &str = "<unknown terminal>";
const UNKNOWN_VERSION: &str = "<unknown version>";
const UNKNOWN_CONFIG: &str = "<unknown config>";
const GITHUB_CHAR_LIMIT: usize = 8100; // Magic number accepted by Github


Review comment (suggestion):
Nitpick but maybe this should be something like 
```suggestion
        "Enter `{}` to accept, or anything else to decline, and `{}` to confirm your choice:\n",
```


Code after:
use std::fs;
use std::path::PathBuf;
use std::time::Duration;

pub fn create() {
    println!("{}\n", shadow::VERSION.trim());
    let os_info = os_info::get();

    let environment = Environment {
        os_type: os_info.os_type(),
        os_version: os_info.version().clone(),
        shell_info: get_shell_info(),
        terminal_info: get_terminal_info(),
        starship_config: get_starship_config(),
    };

    let issue_body = get_github_issue_body(&environment);

    println!(
        "{}\n{issue_body}\n\n",
        Style::new().bold().paint("Generated bug report:")
    );
    println!("Forward the pre-filled report above to GitHub in your browser?");
    println!("{} To avoid any sensitive data from being exposed, please review the included information before proceeding. Data forwarded to GitHub is subject to GitHub's privacy policy.", Style::new().bold().paint("Warning:"));
    println!(
        "Enter `{}` to accept, or anything else to decline, and `{}` to confirm your choice:\n",
        Style::new().bold().paint("y"),
        Style::new().bold().paint("Enter key")
    );

    let mut input = String::new();
    let _ = std::io::stdin().read_line(&mut input);

    if input.trim().to_lowercase() == "y" {
        let link = make_github_issue_link(&issue_body);
        if let Err(e) = open::that(&link) {
            println!("Failed to open issue report in your browser: {}", e);
            println!("Please copy the above report and open an issue manually, or try opening the following link:\n{link}");
        }
    } else {
        println!("Will not open an issue in your browser! Please copy the above report and open an issue manually.");
    }
    println!("Thanks for using the Starship bug report tool!");
}

const UNKNOWN_SHELL: &str = "<unknown shell>";
const UNKNOWN_TERMINAL: &str = "<unknown terminal>";
const UNKNOWN_VERSION: &str = "<unknown version>";
const UNKNOWN_CONFIG: &str = "<unknown config>";
const GITHUB_CHAR_LIMIT: usize = 8100; // Magic number accepted by Github