1
0
mirror of https://github.com/gjkcz/ansible-void.git synced 2026-03-13 14:10:13 +01:00

Install Flatpak

This commit is contained in:
2026-02-25 16:21:24 +01:00
parent 3e8f039a46
commit a4f804996b
2 changed files with 54 additions and 3 deletions

View File

@@ -3,6 +3,10 @@ timeout_blank: 1800
timeout_lock: 30
grub_timeout: 10
flatpak_install:
- com.prusa3d.PrusaSlicer
- cc.arduino.IDE2
xbps_install:
# General
- htop
@@ -24,8 +28,6 @@ xbps_install:
- nano
- emacs
- vscode
- arduino
- arduino-cli
- idle-python3
- platformio
- openjdk
@@ -65,7 +67,6 @@ xbps_install:
- asciiquarium
- cbonsai
- cmatrix
# - openarena
# GNOME
# A custom list intead of `gnome-apps` meta package
- eog
@@ -93,3 +94,6 @@ xbps_install:
- gnome-dictionary
xbps_remove:
- gnome-apps
- arduino # Old version; Install flatpak for v2
- arduino-cli
- PrusaSlicer # Removed from Void repos; Install Flatpak

View File

@@ -123,6 +123,53 @@
command: 'vkpurge rm all'
- name: Flatpak
hosts: all
tags: flatpak
tasks:
- name: Install Flatpak
package:
name: flatpak
state: present
- name: Add Flathub remote
community.general.flatpak_remote:
name: flathub
state: present
flatpakrepo_url: https://flathub.org/repo/flathub.flatpakrepo
method: system
- name: Install Flatpak applications
community.general.flatpak:
name: "{{ item }}"
state: present
remote: flathub
method: system
loop: "{{ flatpak_install }}"
- name: Update all installed Flatpaks
command: flatpak update -y
register: flatpak_update
changed_when: "'Nothing to do.' not in flatpak_update.stdout"
- name: Ensure Flatpak export paths are in XDG_DATA_DIRS
copy:
dest: /etc/profile.d/flatpak.sh
mode: '0644'
content: |
# Flatpak desktop file integration
if [ -d /var/lib/flatpak/exports/share ]; then
XDG_DATA_DIRS="/var/lib/flatpak/exports/share:${XDG_DATA_DIRS:-/usr/local/share:/usr/share}"
fi
if [ -d "$HOME/.local/share/flatpak/exports/share" ]; then
XDG_DATA_DIRS="$HOME/.local/share/flatpak/exports/share:$XDG_DATA_DIRS"
fi
export XDG_DATA_DIRS
- name: Gnome
hosts: all
tags: