File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -66,7 +66,7 @@ process() {
66
66
cd " $1 "
67
67
68
68
# -- Git sanity checks --
69
- repoSlug=$( git remote -v | grep origin | head -n1 | sed ' s/.*github.com.\([^ ]*\) .*/\1 /' | sed ' s/\.git$ //' )
69
+ repoSlug=$( grep ' <connection> ' pom.xml 2> /dev/null | sed ' s/[^>]*>/ /' | sed ' s/<.* //' | cut -d ' / ' -f4,5 )
70
70
test " $repoSlug " && info " Repository = $repoSlug " || die ' Could not determine GitHub repository slug'
71
71
git fetch > /dev/null
72
72
git diff-index --quiet HEAD -- || die " Dirty working copy"
166
166
' #' * ) continue ;;
167
167
esac
168
168
info " Encrypting ${p%% =* } "
169
- echo yes | $EXEC travis encrypt " $p " --add env.global
169
+ echo yes | $EXEC travis encrypt " $p " --add env.global --repo $repoSlug
170
170
done < " $varsFile "
171
171
$EXEC git commit " $travisConfig " -m " Travis: add encrypted environment variables"
172
172
else
179
179
info " Encrypting $signingKeyDestFile "
180
180
# NB: We have to copy the file first, so that --add does the right thing.
181
181
$EXEC cp " $signingKeySourceFile " " $signingKeyDestFile "
182
- $EXEC travis encrypt-file " $signingKeyDestFile " " $signingKeyDestFile .enc" --add
182
+ $EXEC travis encrypt-file " $signingKeyDestFile " " $signingKeyDestFile .enc" --add --repo $repoSlug
183
183
$EXEC rm -f " $signingKeyDestFile "
184
184
$EXEC git add " $travisConfig " " $signingKeyDestFile .enc"
185
185
$EXEC git commit -m " Travis: add encrypted GPG signing keypair"
You can’t perform that action at this time.
0 commit comments