Skip to content

Instantly share code, notes, and snippets.

@pprince
Created April 18, 2016 21:33
Show Gist options
  • Save pprince/753a6eaa7c56a1975e027bd784142b6f to your computer and use it in GitHub Desktop.
Save pprince/753a6eaa7c56a1975e027bd784142b6f to your computer and use it in GitHub Desktop.
{% set home_dir = pillar['general']['my_home_dir'] %}
add-local-search-path:
file.replace:
- name: {{ home_dir }}/.bash_profile
- pattern: "^PATH=\\$PATH"
- repl: "PATH=$PATH:$HOME/usr/bin"
- unless: grep "\$HOME/usr/bin" {{ home_dir }}/.bash_profile
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment