30 lines
1.2 KiB
YAML
30 lines
1.2 KiB
YAML
|
|
---
|
||
|
|
#########
|
||
|
|
# Greenfoot und BlueJ.
|
||
|
|
|
||
|
|
- name: Determine installed bluej version
|
||
|
|
shell: "dpkg -l bluej 2> /dev/null | grep ii | awk '{print $3}'"
|
||
|
|
register: command_output
|
||
|
|
- set_fact:
|
||
|
|
bluej_installed_version: "{{ command_output.stdout }}"
|
||
|
|
|
||
|
|
- name: Determine installed greenfoot version
|
||
|
|
shell: "dpkg -l greenfoot 2> /dev/null | grep ii | awk '{print $3}'"
|
||
|
|
register: command_output
|
||
|
|
- set_fact:
|
||
|
|
greenfoot_installed_version: "{{ command_output.stdout }}"
|
||
|
|
|
||
|
|
- name: Install bluej if necessary
|
||
|
|
ansible.builtin.apt:
|
||
|
|
deb: "{{ mirror_javadev }}/bluej-{{ bluej_target_version }}.deb"
|
||
|
|
when: (mirror_javadev is defined and mirror_javadev | length > 0) and
|
||
|
|
(bluej_target_version is defined and bluej_target_version | length > 0 ) and
|
||
|
|
(bluej_installed_version != bluej_target_version )
|
||
|
|
|
||
|
|
- name: Install greenfoot if necessary
|
||
|
|
ansible.builtin.apt:
|
||
|
|
deb: "{{ mirror_javadev }}/greenfoot-{{ greenfoot_target_version }}.deb"
|
||
|
|
when: (mirror_javadev is defined and mirror_javadev | length > 0) and
|
||
|
|
(greenfoot_target_version is defined and greenfoot_target_version | length > 0 ) and
|
||
|
|
(greenfoot_installed_version != greenfoot_target_version )
|