|
1 | 1 | # tasks file |
2 | 2 | --- |
3 | 3 | - name: install dependencies |
4 | | - apt: |
| 4 | + ansible.builtin.apt: |
5 | 5 | name: "{{ gnu_parallel_dependencies }}" |
6 | 6 | state: "{{ apt_install_state | default('latest') }}" |
7 | 7 | update_cache: true |
|
13 | 13 | - gnu-parallel-install-dependencies |
14 | 14 |
|
15 | 15 | - name: remove (distro version) |
16 | | - apt: |
| 16 | + ansible.builtin.apt: |
17 | 17 | name: parallel |
18 | 18 | state: absent |
19 | 19 | purge: true |
|
25 | 25 | - gnu-parallel-remove-distro |
26 | 26 |
|
27 | 27 | - name: create (download) directory |
28 | | - file: |
| 28 | + ansible.builtin.file: |
29 | 29 | path: "{{ gnu_parallel_download_path }}" |
30 | 30 | state: directory |
31 | 31 | owner: root |
|
38 | 38 | - gnu-parallel-install-download |
39 | 39 |
|
40 | 40 | - name: download (latest) |
41 | | - get_url: |
| 41 | + ansible.builtin.get_url: |
42 | 42 | url: "{{ gnu_parallel_download_url }}" |
43 | 43 | dest: "{{ gnu_parallel_download_path }}/{{ gnu_parallel_download_url | basename }}" |
44 | 44 | owner: root |
|
52 | 52 | - gnu-parallel-install-download |
53 | 53 |
|
54 | 54 | - name: create (build) directory |
55 | | - file: |
| 55 | + ansible.builtin.file: |
56 | 56 | path: "{{ gnu_parallel_build_path }}" |
57 | 57 | state: directory |
58 | 58 | owner: root |
|
65 | 65 | - gnu-parallel-install-build |
66 | 66 |
|
67 | 67 | - name: version check |
68 | | - shell: > |
| 68 | + ansible.builtin.shell: > |
69 | 69 | tar -jtf {{ gnu_parallel_download_path }}/{{ gnu_parallel_download_url | basename }} | head -n 1 |
70 | 70 | args: |
71 | 71 | warn: false |
|
78 | 78 | - gnu-parallel-install-build |
79 | 79 |
|
80 | 80 | - name: extract |
81 | | - unarchive: |
| 81 | + ansible.builtin.unarchive: |
82 | 82 | src: "{{ gnu_parallel_download_path }}/{{ gnu_parallel_download_url | basename }}" |
83 | 83 | dest: "{{ gnu_parallel_build_path }}" |
84 | 84 | creates: "{{ gnu_parallel_build_path }}/{{ _version_check.stdout }}" |
|
93 | 93 | - block: |
94 | 94 |
|
95 | 95 | - name: configure |
96 | | - command: > |
| 96 | + ansible.builtin.command: > |
97 | 97 | ./configure |
98 | 98 | args: |
99 | 99 | chdir: "{{ gnu_parallel_build_path }}/{{ _version_check.stdout }}" |
100 | 100 | tags: |
101 | 101 | - gnu-parallel-install-build-configure |
102 | 102 |
|
103 | 103 | - name: make |
104 | | - command: > |
| 104 | + ansible.builtin.command: > |
105 | 105 | make -j{{ ansible_processor_cores + 1 }} |
106 | 106 | args: |
107 | 107 | chdir: "{{ gnu_parallel_build_path }}/{{ _version_check.stdout }}" |
108 | 108 | tags: |
109 | 109 | - gnu-parallel-install-build-make |
110 | 110 |
|
111 | 111 | - name: make install |
112 | | - command: > |
| 112 | + ansible.builtin.command: > |
113 | 113 | make install |
114 | 114 | args: |
115 | 115 | chdir: "{{ gnu_parallel_build_path }}/{{ _version_check.stdout }}" |
|
124 | 124 | - gnu-parallel-install-build |
125 | 125 |
|
126 | 126 | - name: silence citation notice |
127 | | - copy: |
| 127 | + ansible.builtin.copy: |
128 | 128 | src: root/.parallel |
129 | 129 | dest: "{{ ansible_env.HOME }}/" |
130 | 130 | owner: "{{ ansible_env.USER }}" |
|
136 | 136 | - gnu-parallel-silence-citation-notice |
137 | 137 |
|
138 | 138 | - name: verify |
139 | | - command: > |
| 139 | + ansible.builtin.command: > |
140 | 140 | parallel --version |
141 | 141 | changed_when: false |
142 | 142 | tags: |
|
0 commit comments