Explorar el Código

pathappend

pull/1/head
padre
commit
9885ab9d34
Se han modificado 3 ficheros con 26 adiciones y 0 borrados
  1. +1
    -0
      tasks/main.yaml
  2. +14
    -0
      tasks/path.yaml
  3. +11
    -0
      templates/path/pathappend.service.j2

+ 1
- 0
tasks/main.yaml Ver fichero

@@ -3,6 +3,7 @@
- import_tasks: clean.yaml

- import_tasks: structure.yaml
- import_tasks: path.yaml
- import_tasks: ssh.yaml
- import_tasks: tmux.yaml
- import_tasks: pulseaudio.yaml


+ 14
- 0
tasks/path.yaml Ver fichero

@@ -0,0 +1,14 @@
---

- name: pathappend service
template:
src: path/pathappend.service.j2
dest: ~/.config/systemd/user/pathappend.service
notify: systemd daemon-reload

- name: pathappend service enabled and started
systemd:
name: pathappend.service
enabled: true
state: started
scope: user

+ 11
- 0
templates/path/pathappend.service.j2 Ver fichero

@@ -0,0 +1,11 @@
{{ ansible_managed | comment }}

[Unit]
Description=append home directory paths to PATH environment variable

[Service]
Type=oneshot
ExecStart=fish -c "set -x PATH ~/bin ~/.local/bin $PATH; systemctl --user import-environment PATH"

[Install]
WantedBy=default.target