Remove configuration wrapper for prusa-slicer

This commit is contained in:
Przemek Grondek 2024-08-15 17:14:48 +02:00
parent 46c17770df
commit 6a1251fa1e
3 changed files with 8 additions and 44 deletions

View File

@ -1,26 +0,0 @@
- name: checkout prusa profiles repo
git:
repo: "{{ prusa_slicer.repo }}"
dest: "{{ ansible_user_dir }}/.config/PrusaSlicer"
clone: yes
update: yes
- name: Install wrapper
become: yes
copy:
src: usr/local/bin/prusa-slicer.wrapper
dest: /usr/local/bin/prusa-slicer.wrapper
mode: '0755'
- name: clean link
become: yes
file:
path: "/usr/local/bin/prusa-slicer"
state: absent
- name: Create symbolic link to wrapper
become: yes
file:
src: "/usr/local/bin/prusa-slicer.wrapper"
dest: "/usr/local/bin/prusa-slicer"
state: link

View File

@ -1,6 +1,12 @@
- name: Install prusa-slicer [Ubuntu]
when: ansible_distribution == "Ubuntu"
block:
- name: Remove old version/symbolic link
become: yes
file:
path: "/usr/local/bin/prusa-slicer"
state: absent
- name: "Get PrusaSlicer version"
uri:
url: https://api.github.com/repos/prusa3d/PrusaSlicer/releases/latest
@ -12,7 +18,7 @@
when: ansible_architecture == "x86_64"
get_url:
url: "{{ (git_info.json | json_query('assets[*].browser_download_url') | select('match', '.*x64-GTK3.*AppImage'))[0] }}"
dest: /usr/local/bin/prusa-slicer.real
dest: /usr/local/bin/prusa-slicer
mode: 0755
- name: Install on arm64
@ -20,22 +26,9 @@
become: yes
get_url:
url: "{{ (git_info.json | json_query('assets[*].browser_download_url') | select('match', '.*armv7l-GTK2.*AppImage'))[0] }}"
dest: /usr/local/bin/prusa-slicer.real
dest: /usr/local/bin/prusa-slicer
mode: 0755
- name: Clean symbolic link
become: yes
file:
path: "/usr/local/bin/prusa-slicer"
state: absent
- name: Create symbolic link to real app
become: yes
file:
src: "/usr/local/bin/prusa-slicer.real"
dest: "/usr/local/bin/prusa-slicer"
state: link
- name: Install prusa-slicer [Arch]
when: ansible_distribution == "Archlinux"
shell:

View File

@ -1,4 +1 @@
- include_tasks: install-program.yml
- include_tasks: config-repository.yml
when: ansible_distribution == "Ubuntu"