--- # GNOME settings, extensions, and setup. # Check for special software that may need added to favorites. - name: Workstation | Account Management | GNOME | Checks | Defaults set_fact: browser: "com.github.Eloston.UngoogledChromium.desktop" - name: Workstation | Account Management | GNOME | Checks | Brave | Locate shell: which brave-browser register: brave ignore_errors: yes - name: Workstation | Account Management | GNOME | Checks | Brave | Set As Browser set_fact: browser: brave-browser.desktop when: not brave.failed # Make sure Gnome-Tweaks is installed - name: Workstation | Account Management | GNOME | Install Dependencies package: name: - "{{ gnome_tweaks }}" - "{{ dconf_editor }}" - "{{ psutil }}" state: present ## Dash to Dock Extension ## # Note: Validate DtD by checking /org/gnome/shell/enabled-extensions for dash-to-dock@micxgx.gmail.com - name: Workstation | Account Management | GNOME | Dash To Dock | Check shell: "cd ~/.local/share/gnome-shell/extensions/dash-to-dock@micxgx.gmail.com/" become_user: ling register: dash_to_dock_exists ignore_errors: yes # Install # # https://micheleg.github.io/dash-to-dock/download.html - name: Workstation | Account Management | GNOME | Dash To Dock | Install | Clone Repo git: repo: https://github.com/micheleg/dash-to-dock.git dest: "~/TRASH/dash-to-dock/" clone: yes force: no version: master become_user: ling when: dash_to_dock_exists.failed - name: Workstation | Account Management | GNOME | Dash To Dock | Install | Make shell: "cd ~/TRASH/dash-to-dock/; make; make install" become_user: ling when: dash_to_dock_exists.failed - name: Workstation | Account Management | GNOME | Dash To Dock | Read Enabled Extension Array dconf: key: /org/gnome/shell/enabled-extensions state: read become_user: ling register: gnome_enabled_extensions when: dash_to_dock_exists.failed # https://ansible-docs.readthedocs.io/zh/stable-2.0/rst/playbooks_filters.html#filters-for-formatting-data - name: Workstation | Account Management | GNOME | Dash To Dock | Variables 1 set_fact: gnome_enabled_extensions: "{{ gnome_enabled_extensions.value | replace('@as ', '') }}" dash_to_dock_ext_comma: "" when: gnome_enabled_extensions is defined - name: Workstation | Account Management | GNOME | Dash To Dock | Variables 2 set_fact: dash_to_dock_ext_comma: ", " when: gnome_enabled_extensions is defined and gnome_enabled_extensions != "[]" and gnome_enabled_extensions != [] - name: Workstation | Account Management | GNOME | Dash To Dock | Variables 3 set_fact: dash_to_dock_ext_name: "{{ dash_to_dock_ext_comma }}'dash-to-dock@micxgx.gmail.com']" when: gnome_enabled_extensions is defined - debug: var: dash_to_dock_ext_name when: gnome_enabled_extensions is defined - debug: var: gnome_enabled_extensions when: gnome_enabled_extensions is defined - debug: msg: "{{ gnome_enabled_extensions | replace(']', dash_to_dock_ext_name) }}" when: gnome_enabled_extensions is defined - name: Workstation | Account Management | GNOME | Dash To Dock | Enable dconf: key: /org/gnome/shell/enabled-extensions value: "{{ gnome_enabled_extensions | replace(']', dash_to_dock_ext_name) }}" state: present become_user: ling when: gnome_enabled_extensions is defined # Settings # - name: Workstation | Account Management | GNOME | Dash To Dock | Dock Position dconf: key: /org/gnome/shell/extensions/dash-to-dock/dock-position value: "'LEFT'" state: present become_user: ling - name: Workstation | Account Management | GNOME | Dash To Dock | Dock Fixed dconf: key: /org/gnome/shell/extensions/dash-to-dock/dock-fixed value: true state: present become_user: ling - name: Workstation | Account Management | GNOME | Dash To Dock | Icon Size dconf: key: /org/gnome/shell/extensions/dash-to-dock/dash-max-icon-size value: "32" state: present become_user: ling - name: Workstation | Account Management | GNOME | Favorites (Linux) dconf: key: /org/gnome/shell/favorite-apps value: "['org.gnome.Terminal.desktop', 'gnome-system-monitor.desktop', 'org.gnome.Nautilus.desktop', '{{ browser }}', 'org.mozilla.Thunderbird.desktop', 'org.telegram.desktop.desktop', 'com.discordapp.Discord.desktop', 'rhythmbox.desktop', 'io.lbry.lbry-app.desktop', 'codium.desktop', 'com.visualstudio.code-oss.desktop', 'org.shotcut.Shotcut.desktop', 'com.valvesoftware.Steam.desktop', 'net.lutris.Lutris.desktop']" state: present become_user: ling when: ansible_system == "Linux" - name: Workstation | Account Management | GNOME | Favorites (FreeBSD) dconf: key: /org/gnome/shell/favorite-apps value: "['org.gnome.Terminal.desktop', 'org.gnome.Nautilus.desktop', 'firefox.desktop', 'org.mozilla.Thunderbird.desktop', 'code-oss.desktop']" state: present become_user: ling when: ansible_system == "FreeBSD" ## Top Bar Settings ## # (Battery Percentage, Clock Weekday+Seconds, Calendar Week Numbers) - name: Workstation | Account Management | GNOME | Interface - Show Date dconf: key: /org/gnome/desktop/interface/clock-show-date value: "true" state: present become_user: ling - name: Workstation | Account Management | GNOME | Interface - 24h Format dconf: key: /org/gnome/desktop/interface/clock-format value: "'24h'" state: present become_user: ling - name: Workstation | Account Management | GNOME | Interface - Show Seconds dconf: key: /org/gnome/desktop/interface/clock-show-seconds value: "true" state: present become_user: ling - name: Workstation | Account Management | GNOME | Interface - Show Weekday dconf: key: /org/gnome/desktop/interface/clock-show-weekday value: "true" state: present become_user: ling - name: Workstation | Account Management | GNOME | Interface - 24h Format dconf: key: /org/gnome/desktop/interface/show-battery-percentage value: "true" state: present become_user: ling - name: Workstation | Account Management | GNOME | Interface - Show Week Date dconf: key: /org/gnome/desktop/calendar/show-weekdate value: "true" state: present become_user: ling # Never Prompt for Removal Media # Dark theme? #Pop-dark on Pop #Adwaita-dark on everything else # Window Titlebars (Titlebar Buttons Minimize) - name: Workstation | Account Management | GNOME | Window Buttons dconf: key: /org/gnome/desktop/wm/preferences/button-layout value: "'appmenu:minimize,close'" state: present become_user: ling # Security - name: Workstation | Account Management | GNOME | Privacy - Camera dconf: key: /org/gnome/desktop/privacy/disable-camera value: "true" state: present become_user: ling - name: Workstation | Account Management | GNOME | Privacy - Microphone dconf: key: /org/gnome/desktop/privacy/disable-microphone value: "true" state: present become_user: ling # Schemas to try after looking at gsettings list-schemas | sort # org.gnome.ControlCenter -- not very interesting # org.gnome.desktop.default-applications -- nothing?? Where do we set Firefox and Evolution? # org.gnome.desktop.interface -- Good stuff in here. # org.gnome.desktop.peripherals -- Nothing :( # org.gnome.desktop.privacy -- Good stuff here too!! Cool! # org.gnome.desktop.session # org.gnome.desktop.wm.keybindings # org.gnome.desktop.wm.preferences # org.gnome.power-manager # org.gnome.SessionManager # org.gnome.shell # org.gnome.shell.extensions.pop-shell # org.gnome.shell.keybindings