From 45934922f139175cde00e83c3138ea80466bac14 Mon Sep 17 00:00:00 2001 From: shimeoki <79855381+shimeoki@users.noreply.github.com> Date: Sun, 29 Jun 2025 21:07:57 +0300 Subject: [PATCH] fix: pause in background_task (#1138) i found out that it worked incorrectly, so i fixed it based on other functions in the module --- modules/background_task/task.nu | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/modules/background_task/task.nu b/modules/background_task/task.nu index ba65d13..41f76b1 100644 --- a/modules/background_task/task.nu +++ b/modules/background_task/task.nu @@ -179,20 +179,20 @@ export def restart [ # # A paused group won't start any new tasks automatically. export def pause [ - ...ids: int # IDs of the tasks to pause. - --group (-g) # Pause a specific group - --all (-a) # Pause all groups. - --wait (-w) # Only pause the specified group and let already running tasks finish by themselves + ...ids: int # IDs of the tasks to pause. + --group (-g): string # Pause a specific group + --all (-a) # Pause all groups. + --wait (-w) # Only pause the specified group and let already running tasks finish by themselves ] { mut args = [] if $group != null { - $args = ($args | prepend "--group") + $args = ($args | prepend ["--group" $group]) } - if $all != null { + if $all { $args = ($args | prepend "--all") } - if $wait != null { + if $wait { $args = ($args | prepend "--wait") }