Skip to content

Commit

Permalink
attempt to install prusa-slicer with snap
Browse files Browse the repository at this point in the history
  • Loading branch information
capsulecorplab committed Nov 19, 2023
1 parent bfa1450 commit 420ab27
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 15 deletions.
Binary file not shown.
Binary file not shown.
23 changes: 8 additions & 15 deletions playbook.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -251,23 +251,16 @@

vars:
- prusaslicer_version: "2.6.0"
- prusaslicer_dir: "PrusaSlicer-{{ prusaslicer_version }}+linux-x64-GTK3-202306191220"

tasks:
- name: Join parts of PrusaSlicer tarball
shell: cat /home/kasm-default-profile/install_files/{{ prusaslicer_dir }}.tar.bz2.parta* > /home/kasm-default-profile/install_files/{{ prusaslicer_dir }}.tar.bz2
- name: Extract PrusaSlicer for 64-bit Linux to /opt
unarchive:
src: /home/kasm-default-profile/install_files/{{ prusaslicer_dir }}.tar.bz2
dest: /opt
remote_src: yes
creates: /opt/{{ prusaslicer_dir }}/bin/prusa-slicer
- name: Create symlink for prusa-slicer in /usr/local/bin
shell: ln -srv /opt/{{ prusaslicer_dir }}/bin/prusa-slicer /usr/local/bin/prusa-slicer
- name: Create local application folder for PrusaSlicer
shell: mkdir -p /home/kasm-default-profile/.local/share/applications/
- name: Configure PrusaSlicer desktop shortcut
shell: echo "[Desktop Entry]\nName=PrusaSlicer\nGenericName=PrusaSlicer\nExec=/usr/local/bin/prusa-slicer\nIcon=/opt/{{ prusaslicer_dir }}/resources/icons/PrusaSlicer.png\nTerminal=false\nType=Application\nStartupNotify=false\nCategories=Application;Development;" > /home/kasm-default-profile/.local/share/applications/prusaslicer.desktop
- name: Install snap
apt:
name: snap
update_cache: yes
- name: Test snap installation
shell: snap install hello-world
- name: Install prusa-slicer {{ prusaslicer_version }}
shell: snap install prusa-slicer --channel={{ prusaslicer_version }}/stable --classic
- name: Get prusa-slicer version
shell: prusa-slicer --help | grep PrusaSlicer- | awk '{ print $1 '}
register: installed_prusaslicer_version
Expand Down

0 comments on commit 420ab27

Please sign in to comment.