-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.travis.yml
50 lines (42 loc) · 1.1 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
language: php
sudo: false
cache:
directories:
- $HOME/.composer/cache/files
matrix:
fast_finish: true
include:
- php: 5.6
- php: 7.1
before_install:
- composer self-update
- curl -LSs https://box-project.github.io/box2/installer.php | php
- mv box.phar box
- chmod 755 box
install:
- composer install --prefer-source --no-interaction
- ls -lat vendor
script:
- mkdir ./bin
- ./vendor/bin/phpunit
- rm -rf vendor
- composer install --no-dev
- ls -lat vendor
- if [ $(phpenv version-name) = "5.6" ]; then ~/.phpenv/versions/5.6/bin/php box build; fi
- ls -lat ./bin
before_deploy: # Set up git user name and tag this commit
- git config --local user.name "TravisCI-marczhermo"
- git config --local user.email "[email protected]"
- export TRAVIS_TAG=${TRAVIS_TAG:-$(date +'%Y%m%d%H%M%S')-$(git log --format=%h -1)}
- echo $TRAVIS_TAG
- git tag $TRAVIS_TAG
deploy:
provider: releases
api_key: "$GITHUB_OATH_TOKEN"
file: "./bin/nautpie.phar"
skip_cleanup: true
overwrite: true
draft: true
on:
branch: master
condition: $(phpenv version-name) = "5.6"