add helpers for git cloning and building
This commit is contained in:
19
tasks/helpers/cmake_build.yml
Normal file
19
tasks/helpers/cmake_build.yml
Normal file
@@ -0,0 +1,19 @@
|
||||
# vim: set filetype=yaml.ansible :
|
||||
---
|
||||
- name: Configure {{ repo.git_path }}
|
||||
ansible.builtin.command:
|
||||
creates: "{{ repo.git_path }}/build"
|
||||
chdir: "{{ repo.git_path }}"
|
||||
argv: "{{ repo.build.configure }}"
|
||||
|
||||
- name: Build {{ repo.git_path }}
|
||||
ansible.builtin.command:
|
||||
creates: "{{ repo.git_path }}/{{ repo.build.creates }}"
|
||||
chdir: "{{ repo.git_path }}"
|
||||
argv: "{{ repo.build.build }}"
|
||||
|
||||
- name: Install {{ repo.git_push }}
|
||||
ansible.buitlin.command:
|
||||
creates: "{{ repo.prefix }}/{{ repo.build.installs }}"
|
||||
chdir: "{{ repo.git_path }}"
|
||||
argv: "{{ repo.build.install }}"
|
||||
7
tasks/helpers/git.yml
Normal file
7
tasks/helpers/git.yml
Normal file
@@ -0,0 +1,7 @@
|
||||
- name: Clone git repository {{ repo.repo }}
|
||||
ansible.builtin.git:
|
||||
depth: 1
|
||||
force: true
|
||||
dest: "{{ repo.git_path }}"
|
||||
repo: "{{ repo.repo }}"
|
||||
version: "{{ repo.version | default(omit) }}"
|
||||
Reference in New Issue
Block a user