Skip to content

Commit

Permalink
Warm-up gpg-agent password cache for Git
Browse files Browse the repository at this point in the history
  • Loading branch information
ondrejmirtes committed Dec 9, 2019
1 parent 22102ad commit 27fa410
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions .travis.yml
@@ -1,5 +1,5 @@
os: linux
dist: xenial
dist: bionic
language: php

stages:
Expand All @@ -11,7 +11,7 @@ php:
- 7.1
- 7.2
- 7.3
- 7.4snapshot
#- 7.4
- master

env:
Expand Down Expand Up @@ -50,7 +50,11 @@ jobs:
- |
openssl aes-256-cbc -K $encrypted_bd816b4f73f9_key -iv $encrypted_bd816b4f73f9_iv -in build/key.gpg.enc -out build/key.gpg -d && \
echo $GPG_PASSPHRASE | gpg --batch --passphrase-fd 0 --import build/key.gpg && \
rm build/key.gpg
rm build/key.gpg && \
echo default-cache-ttl 3600 >> ~/.gnupg/gpg-agent.conf && \
echo allow-preset-passphrase >> ~/.gnupg/gpg-agent.conf && \
sudo apt-get -q install --no-install-recommends -y gnupg-agent && \
echo $GPG_PASSPHRASE | /usr/lib/gnupg/gpg-preset-passphrase --preset 084DFEB449D61EB57A0BD96FEDCC231388521DDE
script:
- |
composer install --working-dir=compiler && \
Expand All @@ -63,7 +67,9 @@ jobs:
git config user.email "ondrej@mirtes.cz" && \
git config user.name "Ondrej Mirtes" && \
git config --global user.signingkey 9511B99BD25BF787 && \
git add phpstan phpstan.phar && \
gpg --batch -ab phpstan.phar && \
gpg --verify phpstan.phar.asc && \
git add phpstan phpstan.phar phpstan.phar.asc && \
git commit -S -m "Updated PHPStan to commit ${TRAVIS_COMMIT}" -m "${GIT_LOG}" && \
git push --quiet origin master
- stage: test
Expand Down

0 comments on commit 27fa410

Please sign in to comment.