From 08b60b62b6202d7d016fb52c433b37f215d77e3c Mon Sep 17 00:00:00 2001 From: Hyperling Date: Fri, 2 Oct 2026 19:20:36 -0700 Subject: [PATCH] flutter, remove PATH changes from user and root rc files and put in user's profile files. --- tasks/workstation/linux/software/flutter.yml | 25 +++++++++++++++----- 1 file changed, 19 insertions(+), 6 deletions(-) diff --git a/tasks/workstation/linux/software/flutter.yml b/tasks/workstation/linux/software/flutter.yml index f72800d..9f2721a 100644 --- a/tasks/workstation/linux/software/flutter.yml +++ b/tasks/workstation/linux/software/flutter.yml @@ -126,10 +126,7 @@ state: absent when: coding -## Configure Environment ## - -# # Flutter, TBD/TODO for ~/.bash_profile and ~/.zprofile. -# export PATH="$PATH:$HOME/development/flutter/bin" +## Configure Environment ## - name: Workstation | Linux | Software | Flutter | Modify PATH (.bashrc) ansible.builtin.blockinfile: @@ -137,7 +134,7 @@ block: | export PATH="$PATH:{{ flutter_bin_location }}" marker: '# {mark} MANAGED BY ANSIBLE | Flutter' - state: present + state: absent create: true backup: true loop: @@ -154,7 +151,7 @@ block: | export PATH="$PATH:{{ flutter_bin_location }}" marker: '# {mark} MANAGED BY ANSIBLE | Flutter' - state: present + state: absent create: true backup: true loop: @@ -165,6 +162,22 @@ and user_root.home != "" and user_user.home != "" +- name: Workstation | Linux | Software | Flutter | Modify PATH (profiles) + ansible.builtin.blockinfile: + path: "{{ user_user.home }}/{{ item }}" + block: | + export PATH="$PATH:{{ flutter_bin_location }}" + marker: '# {mark} MANAGED BY ANSIBLE | Flutter' + state: present + create: true + backup: true + loop: + - ".bash_profile" + - ".zprofile" + ignore_errors: true + when: coding + and user_user.home != "" + ## Test SDK ## - name: Workstation | Linux | Software | Flutter | Doctor Report