Add hypothesis example DB to repo

This commit is contained in:
Markus Unterwaditzer 2016-09-26 21:39:33 +02:00
parent ce8e027346
commit 373f4b8e77
7 changed files with 47 additions and 2 deletions

1
.gitignore vendored
View file

@ -13,3 +13,4 @@ dist
docs/_build/
vdirsyncer/version.py
.hypothesis
!.hypothesis/examples

Binary file not shown.

View file

@ -1,4 +1,7 @@
{
"after_script": [
"if [ \"$BUILD_PRS\" = \"true\" ] || [ \"$TRAVIS_PULL_REQUEST\" = \"false\" ]; then\n scripts/upload-hypothesis-db.sh;\nfi"
],
"branches": {
"only": [
"auto",
@ -130,7 +133,7 @@
]
},
"script": [
"if [ \"$BUILD_PRS\" = \"true\" ] || [ \"$TRAVIS_PULL_REQUEST\" = \"false\" ]; then\n make -e $BUILD\nfi"
"if [ \"$BUILD_PRS\" = \"true\" ] || [ \"$TRAVIS_PULL_REQUEST\" = \"false\" ]; then\n make -e $BUILD;\nfi"
],
"sudo": true
}

BIN
scripts/id_travis.enc Normal file

Binary file not shown.

1
scripts/id_travis.pub Normal file
View file

@ -0,0 +1 @@
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDSr4wfP/dbLwHz04kD2S7DE1O0aOk523AUOsoxH0UE35ChNlu92hjLRtLBvfX9D9W9tGwOUwW3YtvMVmzaTE9uQdBH+7p/GuTt3fsAn23Rjm/TPENX83WvcDy2RopaMaTDmbBHPX75/LNVAbuhcyWBbgbOhxv+SHqFiqY3qpp6o1LnQk7dBcCrvtW0hkqviI1xxEtrR+iMVPXbc5Juquo7zqpV4FEUf7K9iGEAI1UaMIKGzfjfir7IEKuYl3ABSf3vOpkHGBlPACDvojsFw7pSeX9zWH8X/vjzgFKEwdHyMwS9rOVxAm3oRLuGu8m1KqQjfLp3D4+tGdb2rXeL5Z9Kr5jOidiiVz+iOq9V551YK53bO+PlO2m9uNnb2apiOgNds9FrjTSZXL0BqUZg7peEvkrFBHJc/lqu6yXfj8MsckUqF8A+g4LCNLA5/5gJXPHUVK/KtPUGk40hWAww+aohqZBBifhQ3DhAZwq2GPHh6ZNYo6QiC8zCYZsBGmgGcxMf0D7jloAE8SYDjCs63X60TRgxe8scu8A141MdGBdZh4AuL/mHOuQvVGcsP5NGOitSzsx6RvBb/+/sZh1xzwO56queRUWkjjhB9LdBTPB+D35f23QVjUNHN6XpaH7TrJKrpyGjjYqRnXU3BJRytBqIcP7Ll1ZM4yoHUBCU/0e+lQ== untitaker@chromebot

View file

@ -32,7 +32,11 @@ cfg['install'] = [script("""
""")]
cfg['script'] = [script("""
make -e $BUILD
make -e $BUILD;
""")]
cfg['after_script'] = [script("""
scripts/upload-hypothesis-db.sh;
""")]
matrix = []

36
scripts/upload-hypothesis-db.sh Executable file
View file

@ -0,0 +1,36 @@
#!/bin/sh
GIT_COMMIT_PATH="$(dirname $0)/../.hypothesis/examples"
set -e
_is_dirty() {
(! git diff-index --quiet HEAD $GIT_COMMIT_PATH) || [ "$(git status --porcelain $GIT_COMMIT_PATH | tail -n1)" != "" ]
}
[ -n "$REPO_DEPLOY_KEY" ] || (echo "No deploy key, exiting." && exit 0)
cd "$(dirname $0)"
openssl aes-256-cbc -K $encrypted_a527bcd44658_key -iv $encrypted_a527bcd44658_iv -in id_travis.enc -out /tmp/id_travis -d
chmod 600 /tmp/id_travis
eval `ssh-agent -s`
ssh-add /tmp/id_travis
cd ..
if _is_dirty; then
git config --global push.default simple
git config --global user.email "travis@pimutils.org"
git config --global user.name "Travis CI for pimutils"
git add -fA $GIT_COMMIT_PATH
git commit -m "Hypothesis examples"
for i in `seq 10`; do
echo "push: try $i"
if git push; then break; fi
git pull --rebase
done
else
echo "Nothing to commit"
fi