diff options
author | Larry Smith Jr <mrlesmithjr@gmail.com> | 2018-12-20 01:50:27 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-12-20 01:50:27 -0500 |
commit | d58696271f166b50faa2705fdda6337c1ffb493c (patch) | |
tree | 031334f41175d9a4ddfc9c0769b911f775360f26 /setup_travis_tests.sh | |
parent | c760a03786a2247c14129dfd22c0e0fe1357f094 (diff) | |
parent | 8273b06f4eb706a6e52d9806c30660c9bd6707d1 (diff) | |
download | ansible-rabbitmq-d58696271f166b50faa2705fdda6337c1ffb493c.tar.gz ansible-rabbitmq-d58696271f166b50faa2705fdda6337c1ffb493c.tar.zst ansible-rabbitmq-d58696271f166b50faa2705fdda6337c1ffb493c.zip |
Merge pull request #20 from mrlesmithjr/refactoring-code
Refactoring code
Diffstat (limited to 'setup_travis_tests.sh')
-rwxr-xr-x | setup_travis_tests.sh | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/setup_travis_tests.sh b/setup_travis_tests.sh new file mode 100755 index 0000000..302e659 --- /dev/null +++ b/setup_travis_tests.sh | |||
@@ -0,0 +1,18 @@ | |||
1 | #!/usr/bin/env bash | ||
2 | TRAVIS_TEST_VER="v1.6.2" | ||
3 | |||
4 | TAR_FILE="$TRAVIS_TEST_VER.tar.gz" | ||
5 | |||
6 | # Prompt for Ansible role name | ||
7 | read -r -p "Enter the Ansible role name: " input | ||
8 | |||
9 | # Update .travis.yml with Ansible role name | ||
10 | sed -i '' "s/replace_role/${input}/g" ".travis.yml" | ||
11 | |||
12 | # Update tests/test.yml with Ansible role name | ||
13 | sed -i '' "s/replace_role/${input}/g" "tests/test.yml" | ||
14 | |||
15 | # Cleanup | ||
16 | if [ -f $TAR_FILE ]; then | ||
17 | rm $TAR_FILE | ||
18 | fi | ||