-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rename run module to executable (#447)
- Loading branch information
Showing
47 changed files
with
221 additions
and
222 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
use super::{AnalyzeResult, AppDefinition}; | ||
use crate::configuration::Version; | ||
use crate::executables::{Executable, RunMethod}; | ||
use crate::hosting::github_releases; | ||
use crate::installation::Method; | ||
use crate::platform::Platform; | ||
use crate::prelude::*; | ||
use crate::run::Executable; | ||
use crate::{run, Log}; | ||
use crate::Log; | ||
use const_format::formatcp; | ||
|
||
pub(crate) struct Alphavet {} | ||
|
@@ -22,8 +22,8 @@ impl AppDefinition for Alphavet { | |
formatcp!("https://github.com/{ORG}/{REPO}") | ||
} | ||
|
||
fn run_method(&self, version: &Version, _platform: Platform) -> run::Method { | ||
run::Method::ThisApp { | ||
fn run_method(&self, version: &Version, _platform: Platform) -> RunMethod { | ||
RunMethod::ThisApp { | ||
install_methods: vec![Method::CompileGoSource { | ||
import_path: format!("github.com/{ORG}/{REPO}/cmd/alphavet@v{version}"), | ||
}], | ||
|
@@ -54,7 +54,7 @@ impl AppDefinition for Alphavet { | |
|
||
#[cfg(test)] | ||
mod tests { | ||
use crate::run; | ||
use crate::executables::RunMethod; | ||
|
||
#[test] | ||
fn install_methods() { | ||
|
@@ -72,7 +72,7 @@ mod tests { | |
cpu: Cpu::Arm64, | ||
}, | ||
); | ||
let want = run::Method::ThisApp { | ||
let want = RunMethod::ThisApp { | ||
install_methods: vec![Method::CompileGoSource { | ||
import_path: S("github.com/skx/alphavet/cmd/[email protected]"), | ||
}], | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
use super::{AnalyzeResult, AppDefinition}; | ||
use crate::configuration::Version; | ||
use crate::executables::{Executable, RunMethod}; | ||
use crate::installation::Method; | ||
use crate::platform::Platform; | ||
use crate::prelude::*; | ||
use crate::run::Executable; | ||
use crate::{run, Log}; | ||
use crate::Log; | ||
|
||
pub(crate) struct Deadcode {} | ||
|
||
|
@@ -17,8 +17,8 @@ impl AppDefinition for Deadcode { | |
"https://pkg.go.dev/golang.org/x/tools/cmd/deadcode" | ||
} | ||
|
||
fn run_method(&self, version: &Version, _platform: Platform) -> run::Method { | ||
run::Method::ThisApp { | ||
fn run_method(&self, version: &Version, _platform: Platform) -> RunMethod { | ||
RunMethod::ThisApp { | ||
install_methods: vec![Method::CompileGoSource { | ||
import_path: format!("golang.org/x/tools/cmd/deadcode@v{version}"), | ||
}], | ||
|
@@ -51,7 +51,7 @@ impl AppDefinition for Deadcode { | |
#[cfg(test)] | ||
mod tests { | ||
use crate::applications::deadcode::Deadcode; | ||
use crate::run; | ||
use crate::executables::RunMethod; | ||
|
||
#[test] | ||
fn install_methods() { | ||
|
@@ -68,7 +68,7 @@ mod tests { | |
cpu: Cpu::Arm64, | ||
}, | ||
); | ||
let want = run::Method::ThisApp { | ||
let want = RunMethod::ThisApp { | ||
install_methods: vec![Method::CompileGoSource { | ||
import_path: S("golang.org/x/tools/cmd/[email protected]"), | ||
}], | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
use super::{AnalyzeResult, AppDefinition}; | ||
use crate::configuration::Version; | ||
use crate::executables::{Executable, RunMethod}; | ||
use crate::hosting::github_releases; | ||
use crate::installation::Method; | ||
use crate::platform::Platform; | ||
use crate::prelude::*; | ||
use crate::run::Executable; | ||
use crate::{run, Log}; | ||
use crate::Log; | ||
use const_format::formatcp; | ||
|
||
pub(crate) struct Exhaustruct {} | ||
|
@@ -26,8 +26,8 @@ impl AppDefinition for Exhaustruct { | |
github_releases::latest(ORG, REPO, log) | ||
} | ||
|
||
fn run_method(&self, version: &Version, _platform: Platform) -> run::Method { | ||
run::Method::ThisApp { | ||
fn run_method(&self, version: &Version, _platform: Platform) -> RunMethod { | ||
RunMethod::ThisApp { | ||
install_methods: vec![Method::CompileGoSource { | ||
import_path: format!("github.com/{ORG}/{REPO}/v3/cmd/exhaustruct@v{version}"), | ||
}], | ||
|
@@ -54,7 +54,7 @@ impl AppDefinition for Exhaustruct { | |
#[cfg(test)] | ||
mod tests { | ||
use crate::applications::exhaustruct::Exhaustruct; | ||
use crate::run; | ||
use crate::executables::RunMethod; | ||
|
||
#[test] | ||
fn install_methods() { | ||
|
@@ -71,7 +71,7 @@ mod tests { | |
cpu: Cpu::Arm64, | ||
}, | ||
); | ||
let want = run::Method::ThisApp { | ||
let want = RunMethod::ThisApp { | ||
install_methods: vec![Method::CompileGoSource { | ||
import_path: S("github.com/GaijinEntertainment/go-exhaustruct/v3/cmd/[email protected]"), | ||
}], | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.