Added venv check
This commit is contained in:
parent
e1d80ce73f
commit
a456bf734c
1
.gitignore
vendored
1
.gitignore
vendored
@ -1,3 +1,4 @@
|
||||
.stfolder
|
||||
main.retry
|
||||
private
|
||||
.env
|
||||
|
1
requirements.txt
Normal file
1
requirements.txt
Normal file
@ -0,0 +1 @@
|
||||
ansible
|
6
sync.sh
6
sync.sh
@ -8,7 +8,11 @@ if [ -z "$1" ]; then
|
||||
echo "Example: $0 default,vim"
|
||||
exit 1
|
||||
fi
|
||||
ansible-playbook -i 'localhost,' main.yml --tags $1
|
||||
if [ -f .env/bin/activate ]; then
|
||||
echo "Found virtualenv. Sourcing..."
|
||||
source .env/bin/activate
|
||||
fi
|
||||
ansible-playbook -i 'localhost,' main.yml --tags "$1"
|
||||
# Could also sync vim:
|
||||
# ansible-playbook -i hosts main.yml --tags default,vim
|
||||
# vim +'call Initialize()' +'qa'
|
||||
|
Loading…
Reference in New Issue
Block a user