mirror of
https://github.com/lostisland/faraday.git
synced 2025-10-05 00:05:35 -04:00
Only try to cache dependencies when Amazon secret is available
Fixes the case when someone forks the repo and runs Travis on their own. Also, allows the use-case of restoring dependencies only without necessarily trying to cache them.
This commit is contained in:
parent
b5ea93a0cc
commit
62a5781b92
@ -39,7 +39,7 @@ fi
|
||||
|
||||
bundle "$@"
|
||||
|
||||
if [ ! -f "$cache_name" ]; then
|
||||
if [ ! -f "$cache_name" ] && [ -n "$AMAZON_SECRET_ACCESS_KEY" ]; then
|
||||
echo "Caching \`${bundle_path}' to S3"
|
||||
tar czf "$cache_name" "$bundle_path"
|
||||
script/s3-put "$cache_name" "${AMAZON_S3_BUCKET}:${TRAVIS_REPO_SLUG}/${cache_name}"
|
||||
|
Loading…
x
Reference in New Issue
Block a user