--- - name: Enable 'universe' repo (Ubuntu and Mint only) command: add-apt-repository universe when: ansible_facts['distribution'] in ["Ubuntu", "Linux Mint"] changed_when: false ignore_errors: true - name: Remove Mint's nosnap.pref block (Mint only) file: path: /etc/apt/preferences.d/nosnap.pref state: absent when: ansible_facts['distribution'] == "Linux Mint" - name: Install Snap daemon apt: name: snapd state: present when: ansible_facts['os_family'] == "Debian" notify: restart snapd - name: Enable snapd socket on Debian systemd: name: snapd.socket enabled: true state: started when: ansible_facts['distribution'] == "Debian" - name: Force Ansible to reload facts setup: - name: Install VSCode IDE (Snap, all distros) community.general.snap: name: code classic: true state: present when: ansible_facts['os_family'] == "Debian" - name: Install Cursor (Snap, all distros) community.general.snap: name: cursor state: present when: ansible_facts['os_family'] == "Debian"