2020-05-11 07:55:35 +00:00
|
|
|
# Install GoBulleTrain,
|
|
|
|
# Highly configurable prompt builder for Bash, ZSH and PowerShell written in Go.
|
|
|
|
|
|
|
|
Make sure go directory exists:
|
|
|
|
file.directory:
|
2020-08-01 13:08:06 +00:00
|
|
|
- name: {{ salt['user.info']( pillar['username']).home }}/go
|
|
|
|
- user: {{ pillar['username'] }}
|
2020-05-11 07:55:35 +00:00
|
|
|
- group: users
|
|
|
|
- mode: "0755"
|
|
|
|
|
2020-08-01 13:08:06 +00:00
|
|
|
{% if not salt['file.directory_exists']('{}/go/src/github.com/jtyr/gbt'.format(salt['user.info']( pillar'username']).home)) %}
|
2020-05-11 07:55:35 +00:00
|
|
|
Go get GBT:
|
|
|
|
cmd.run:
|
|
|
|
- name: go get github.com/jtyr/gbt/cmd/gbt
|
2020-08-01 13:08:06 +00:00
|
|
|
- runas: {{ pillar['username'] }}
|
2020-05-11 07:55:35 +00:00
|
|
|
- env:
|
2020-08-01 13:08:06 +00:00
|
|
|
- GOPATH: {{ salt['user.info']( pillar['username']).home }}/go
|
2020-05-11 07:55:35 +00:00
|
|
|
{% endif %}
|