Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e161d3cd3c | ||
|
|
318f935b43 | ||
|
|
3dc245245d |
2
Cargo.lock
generated
2
Cargo.lock
generated
@@ -1946,7 +1946,7 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "topgrade"
|
name = "topgrade"
|
||||||
version = "10.1.0"
|
version = "10.1.2"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"anyhow",
|
"anyhow",
|
||||||
"cfg-if",
|
"cfg-if",
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ categories = ["os"]
|
|||||||
keywords = ["upgrade", "update"]
|
keywords = ["upgrade", "update"]
|
||||||
license-file = "LICENSE"
|
license-file = "LICENSE"
|
||||||
repository = "https://github.com/topgrade-rs/topgrade"
|
repository = "https://github.com/topgrade-rs/topgrade"
|
||||||
version = "10.1.0"
|
version = "10.1.2"
|
||||||
authors = ["Roey Darwish Dror <roey.ghost@gmail.com>", "Thomas Schönauer <t.schoenauer@hgs-wt.at>"]
|
authors = ["Roey Darwish Dror <roey.ghost@gmail.com>", "Thomas Schönauer <t.schoenauer@hgs-wt.at>"]
|
||||||
exclude = ["doc/screenshot.gif"]
|
exclude = ["doc/screenshot.gif"]
|
||||||
edition = "2021"
|
edition = "2021"
|
||||||
|
|||||||
@@ -24,6 +24,7 @@ To remedy this, **Topgrade** detects which tools you use and runs the appropriat
|
|||||||
|
|
||||||
- Arch Linux: [AUR](https://aur.archlinux.org/packages/topgrade) package.
|
- Arch Linux: [AUR](https://aur.archlinux.org/packages/topgrade) package.
|
||||||
- NixOS: _topgrade_ package in `nixpkgs`.
|
- NixOS: _topgrade_ package in `nixpkgs`.
|
||||||
|
- Void Linux: _topgrade_ package
|
||||||
- macOS: [Homebrew](https://formulae.brew.sh/formula/topgrade) or [MacPorts](https://ports.macports.org/port/topgrade/).
|
- macOS: [Homebrew](https://formulae.brew.sh/formula/topgrade) or [MacPorts](https://ports.macports.org/port/topgrade/).
|
||||||
|
|
||||||
Other systems users can either use `cargo install` or use the compiled binaries from the release page.
|
Other systems users can either use `cargo install` or use the compiled binaries from the release page.
|
||||||
|
|||||||
@@ -424,19 +424,19 @@ pub struct CommandLineArgs {
|
|||||||
no_retry: bool,
|
no_retry: bool,
|
||||||
|
|
||||||
/// Do not perform upgrades for the given steps
|
/// Do not perform upgrades for the given steps
|
||||||
#[clap(long = "disable", arg_enum, multiple_values = true)]
|
#[clap(long = "disable", value_name = "STEP", arg_enum, multiple_values = true)]
|
||||||
disable: Vec<Step>,
|
disable: Vec<Step>,
|
||||||
|
|
||||||
/// Perform only the specified steps (experimental)
|
/// Perform only the specified steps (experimental)
|
||||||
#[clap(long = "only", arg_enum, multiple_values = true)]
|
#[clap(long = "only", value_name = "STEP", arg_enum, multiple_values = true)]
|
||||||
only: Vec<Step>,
|
only: Vec<Step>,
|
||||||
|
|
||||||
/// Run only specific custom commands
|
/// Run only specific custom commands
|
||||||
#[clap(long = "custom-commands")]
|
#[clap(long = "custom-commands", value_name = "NAME", multiple_values = true)]
|
||||||
custom_commands: Vec<String>,
|
custom_commands: Vec<String>,
|
||||||
|
|
||||||
/// Set environment variables
|
/// Set environment variables
|
||||||
#[clap(long = "env", multiple_values = true)]
|
#[clap(long = "env", value_name = "NAME=VALUE", multiple_values = true)]
|
||||||
env: Vec<String>,
|
env: Vec<String>,
|
||||||
|
|
||||||
/// Output logs
|
/// Output logs
|
||||||
@@ -452,7 +452,14 @@ pub struct CommandLineArgs {
|
|||||||
skip_notify: bool,
|
skip_notify: bool,
|
||||||
|
|
||||||
/// Say yes to package manager's prompt
|
/// Say yes to package manager's prompt
|
||||||
#[clap(short = 'y', long = "yes", arg_enum, multiple_values = true, min_values = 0)]
|
#[clap(
|
||||||
|
short = 'y',
|
||||||
|
long = "yes",
|
||||||
|
value_name = "STEP",
|
||||||
|
arg_enum,
|
||||||
|
multiple_values = true,
|
||||||
|
min_values = 0
|
||||||
|
)]
|
||||||
yes: Option<Vec<Step>>,
|
yes: Option<Vec<Step>>,
|
||||||
|
|
||||||
/// Don't pull the predefined git repos
|
/// Don't pull the predefined git repos
|
||||||
@@ -460,11 +467,11 @@ pub struct CommandLineArgs {
|
|||||||
disable_predefined_git_repos: bool,
|
disable_predefined_git_repos: bool,
|
||||||
|
|
||||||
/// Alternative configuration file
|
/// Alternative configuration file
|
||||||
#[clap(long = "config")]
|
#[clap(long = "config", value_name = "PATH")]
|
||||||
config: Option<PathBuf>,
|
config: Option<PathBuf>,
|
||||||
|
|
||||||
/// A regular expression for restricting remote host execution
|
/// A regular expression for restricting remote host execution
|
||||||
#[clap(long = "remote-host-limit")]
|
#[clap(long = "remote-host-limit", value_name = "REGEX")]
|
||||||
remote_host_limit: Option<Regex>,
|
remote_host_limit: Option<Regex>,
|
||||||
|
|
||||||
/// Show the reason for skipped steps
|
/// Show the reason for skipped steps
|
||||||
|
|||||||
@@ -18,11 +18,7 @@ pub fn self_update() -> Result<()> {
|
|||||||
.repo_owner("topgrade-rs")
|
.repo_owner("topgrade-rs")
|
||||||
.repo_name("topgrade")
|
.repo_name("topgrade")
|
||||||
.target(target)
|
.target(target)
|
||||||
.bin_name(if cfg!(windows) {
|
.bin_name(if cfg!(windows) { "topgrade.exe" } else { "topgrade" })
|
||||||
"topgrade-rs.exe"
|
|
||||||
} else {
|
|
||||||
"topgrade-rs"
|
|
||||||
})
|
|
||||||
.show_output(false)
|
.show_output(false)
|
||||||
.show_download_progress(true)
|
.show_download_progress(true)
|
||||||
.current_version(self_update_crate::cargo_crate_version!())
|
.current_version(self_update_crate::cargo_crate_version!())
|
||||||
|
|||||||
@@ -607,10 +607,12 @@ pub fn run_protonup_update(ctx: &ExecutionContext) -> Result<()> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
pub fn run_distrobox_update(ctx: &ExecutionContext) -> Result<()> {
|
pub fn run_distrobox_update(ctx: &ExecutionContext) -> Result<()> {
|
||||||
|
let distrobox = require("distrobox")?;
|
||||||
|
|
||||||
print_separator("Distrobox");
|
print_separator("Distrobox");
|
||||||
match (
|
match (
|
||||||
match (
|
match (
|
||||||
ctx.run_type().execute("distrobox").arg("upgrade"),
|
ctx.run_type().execute(distrobox).arg("upgrade"),
|
||||||
ctx.config().distrobox_containers(),
|
ctx.config().distrobox_containers(),
|
||||||
) {
|
) {
|
||||||
(r, Some(c)) => {
|
(r, Some(c)) => {
|
||||||
@@ -626,7 +628,8 @@ pub fn run_distrobox_update(ctx: &ExecutionContext) -> Result<()> {
|
|||||||
(r, true) => r.arg("--root"),
|
(r, true) => r.arg("--root"),
|
||||||
(r, false) => r,
|
(r, false) => r,
|
||||||
}
|
}
|
||||||
.check_run()
|
.check_run()?;
|
||||||
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn run_config_update(ctx: &ExecutionContext) -> Result<()> {
|
pub fn run_config_update(ctx: &ExecutionContext) -> Result<()> {
|
||||||
|
|||||||
Reference in New Issue
Block a user