Selaa lähdekoodia

Fix system-wide prompt

tags/2016.12
Filip Pytloun 9 vuotta sitten
vanhempi
commit
973163e2ea
2 muutettua tiedostoa jossa 4 lisäystä ja 4 poistoa
  1. +1
    -1
      linux/files/prompt.sh
  2. +3
    -3
      linux/system/prompt.sls

+ 1
- 1
linux/files/prompt.sh Näytä tiedosto

@@ -7,7 +7,7 @@
[[ $- == *i* ]] || return 0

{%- for user, prompt in system.prompt.iteritems() %}
{% if user != default %}
{% if user != "default" %}
if [ "$USERNAME" == "{{ user }}" ]; then
export PS1="{{ prompt }} "
return 0

+ 3
- 3
linux/system/prompt.sls Näytä tiedosto

@@ -9,16 +9,16 @@
/etc/bash.bashrc:
file.replace:
- pattern: ".*PS1=.*"
- repl: "# Prompt is set by /etc/profile.d/prompt.sh"
- repl: ": # Prompt is set by /etc/profile.d/prompt.sh"

/etc/skel/.bashrc:
file.replace:
- pattern: ".*PS1=.*"
- repl: "# Prompt is set by /etc/profile.d/prompt.sh"
- repl: ": # Prompt is set by /etc/profile.d/prompt.sh"

/root/.bashrc:
file.replace:
- pattern: ".*PS1=.*"
- repl: "# Prompt is set by /etc/profile.d/prompt.sh"
- repl: ": # Prompt is set by /etc/profile.d/prompt.sh"

{%- endif %}

Loading…
Peruuta
Tallenna