diff options
author | Egor Tensin <Egor.Tensin@gmail.com> | 2023-01-26 16:17:50 +0100 |
---|---|---|
committer | Egor Tensin <Egor.Tensin@gmail.com> | 2023-01-26 16:17:50 +0100 |
commit | cd0db89e0a8eb389a305001171f6a835d3caa6fb (patch) | |
tree | 87607d4fdf1921365bee0e7f380c63fefbdf50fd | |
parent | my_server: one step instead of three (diff) | |
download | maintenance-cd0db89e0a8eb389a305001171f6a835d3caa6fb.tar.gz maintenance-cd0db89e0a8eb389a305001171f6a835d3caa6fb.zip |
shorten long command lines
-rw-r--r-- | roles/pacman/tasks/main.yml | 5 | ||||
-rw-r--r-- | roles/rate_mirrors/tasks/main.yml | 6 | ||||
-rw-r--r-- | roles/snap/tasks/main.yml | 6 |
3 files changed, 14 insertions, 3 deletions
diff --git a/roles/pacman/tasks/main.yml b/roles/pacman/tasks/main.yml index 1669920..e628873 100644 --- a/roles/pacman/tasks/main.yml +++ b/roles/pacman/tasks/main.yml @@ -31,7 +31,10 @@ when: not git_status.stdout - name: All changes in /etc are in pacman.d/gnupg? - shell: git status --porcelain=v1 | cut -c 4- | grep -G -v '^pacman.d/gnupg/' + shell: | + git status --porcelain=v1 \ + | cut -c 4- \ + | grep -G -v '^pacman.d/gnupg/' args: chdir: /etc register: only_gnupg diff --git a/roles/rate_mirrors/tasks/main.yml b/roles/rate_mirrors/tasks/main.yml index 7aff26e..8777fbd 100644 --- a/roles/rate_mirrors/tasks/main.yml +++ b/roles/rate_mirrors/tasks/main.yml @@ -16,7 +16,11 @@ - name: Rate pacman mirrors shell: | - . /etc/os-release && rate-mirrors --allow-root --disable-comments --save=/etc/pacman.d/mirrorlist "$ID" + . /etc/os-release && rate-mirrors \ + --allow-root \ + --disable-comments \ + --save=/etc/pacman.d/mirrorlist \ + "$ID" - when: etc_versioned block: diff --git a/roles/snap/tasks/main.yml b/roles/snap/tasks/main.yml index 755a695..f3be9ba 100644 --- a/roles/snap/tasks/main.yml +++ b/roles/snap/tasks/main.yml @@ -9,7 +9,11 @@ failed_when: false - name: All changes in /etc are snap changes? - shell: git status --porcelain=v1 | cut -c 4- | grep -G -v '^systemd/system/' | grep -G -v '/snap\.\|snap-' + shell: | + git status --porcelain=v1 \ + | cut -c 4- \ + | grep -G -v '^systemd/system/' \ + | grep -G -v '/snap\.\|snap-' args: chdir: /etc register: only_snap |