feat(step): Add atuin step (#1367)
This commit is contained in:
@@ -25,6 +25,7 @@ pub enum Step {
|
|||||||
Aqua,
|
Aqua,
|
||||||
Asdf,
|
Asdf,
|
||||||
Atom,
|
Atom,
|
||||||
|
Atuin,
|
||||||
Audit,
|
Audit,
|
||||||
AutoCpufreq,
|
AutoCpufreq,
|
||||||
Bin,
|
Bin,
|
||||||
@@ -202,6 +203,11 @@ impl Step {
|
|||||||
)))]
|
)))]
|
||||||
runner.execute(*self, "apm", || generic::run_apm(ctx))?
|
runner.execute(*self, "apm", || generic::run_apm(ctx))?
|
||||||
}
|
}
|
||||||
|
Atuin =>
|
||||||
|
{
|
||||||
|
#[cfg(unix)]
|
||||||
|
runner.execute(*self, "atuin", || unix::run_atuin(ctx))?
|
||||||
|
}
|
||||||
Audit => {
|
Audit => {
|
||||||
#[cfg(target_os = "dragonfly")]
|
#[cfg(target_os = "dragonfly")]
|
||||||
runner.execute(*self, "DragonFly Audit", || dragonfly::audit_packages(ctx))?;
|
runner.execute(*self, "DragonFly Audit", || dragonfly::audit_packages(ctx))?;
|
||||||
@@ -764,6 +770,7 @@ pub(crate) fn default_steps() -> Vec<Step> {
|
|||||||
Sdkman,
|
Sdkman,
|
||||||
Rcm,
|
Rcm,
|
||||||
Maza,
|
Maza,
|
||||||
|
Atuin,
|
||||||
]);
|
]);
|
||||||
|
|
||||||
#[cfg(not(any(
|
#[cfg(not(any(
|
||||||
|
|||||||
@@ -934,6 +934,14 @@ pub fn run_maza(ctx: &ExecutionContext) -> Result<()> {
|
|||||||
ctx.execute(maza).arg("update").status_checked()
|
ctx.execute(maza).arg("update").status_checked()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn run_atuin(ctx: &ExecutionContext) -> Result<()> {
|
||||||
|
let atuin = require("atuin-update")?;
|
||||||
|
|
||||||
|
print_separator("atuin");
|
||||||
|
|
||||||
|
ctx.execute(atuin).status_checked()
|
||||||
|
}
|
||||||
|
|
||||||
pub fn reboot(ctx: &ExecutionContext) -> Result<()> {
|
pub fn reboot(ctx: &ExecutionContext) -> Result<()> {
|
||||||
match ctx.sudo() {
|
match ctx.sudo() {
|
||||||
Some(sudo) => sudo.execute(ctx, "reboot")?.status_checked(),
|
Some(sudo) => sudo.execute(ctx, "reboot")?.status_checked(),
|
||||||
|
|||||||
Reference in New Issue
Block a user