From 8cdd185e0949ae8ece48c780215f06f925adcfe6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Przemys=C5=82aw=20Grondek?= Date: Sat, 11 May 2024 02:04:56 +0200 Subject: [PATCH] Fix installing IntelliJ --- roles/dev-java/tasks/arch.yml | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) diff --git a/roles/dev-java/tasks/arch.yml b/roles/dev-java/tasks/arch.yml index fa88c3a..59bdcaa 100644 --- a/roles/dev-java/tasks/arch.yml +++ b/roles/dev-java/tasks/arch.yml @@ -4,17 +4,29 @@ name: - jdk17-openjdk -- name: "[Arch] Build pkgs IntelliJ" +- name: "[Arch] Download IntelliJ" shell: cmd: yay -Sw --needed --noconfirm intellij-idea-ultimate-edition -- name: "[Arch] Install IntelliJ" - become: yes +- name: "[Arch] Build IntelliJ" shell: chdir: "{{ ansible_user_dir }}/.cache/yay/intellij-idea-ultimate-edition" cmd: - makepkg -i --noconfirm + makepkg --noconfirm + +- name: "[Arch] Query version" + shell: + cmd: + yay -Ss intellij-idea-ultimate-edition | head -1 | awk '{print $2}' + register: version + +- name: "[Arch] Install IntelliJ" + become: yes + community.general.pacman: + name: + - "{{ ansible_user_dir }}/.cache/yay/intellij-idea-ultimate-edition/intellij-idea-ultimate-edition-{{ version.stdout }}-x86_64.pkg.tar.zst" + - "{{ ansible_user_dir }}/.cache/yay/intellij-idea-ultimate-edition/intellij-idea-ultimate-edition-jre-{{ version.stdout }}-x86_64.pkg.tar.zst" - name: "[Arch] Create symbolic link" become: yes