This repository has been archived by the owner on Aug 16, 2024. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
107 lines (93 loc) · 2.49 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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
language: php
branches:
only:
- master
- /^(?:(\d+)\.)?(?:(\d+)\.)?(\*|\d+)$/
services:
- mysql
cache:
apt: true
yarn: true
directories:
- $HOME/.composer/cache/files
addons:
apt:
packages:
- nginx
hosts:
- wp.dev
php:
- 7.1
- 7.2
- nightly
env:
global:
- COMPOSER_NO_INTERACTION=1
matrix:
- WP_VERSION=nightly
- WP_VERSION=latest
- WP_VERSION=4.9.3
- WP_VERSION=4.8.5
matrix:
allow_failures:
- php: nightly
- env: WP_VERSION=nightly
fast_finish: true
before_install:
# Disable xDebug to speed up the build unless test coverage is needed
- if [[ $(phpenv version-name) != "nightly" ]]; then phpenv config-rm xdebug.ini; fi
# Install helper scripts
- travis_retry composer global require --prefer-dist --no-suggest typisttech/travis-nginx-wordpress:"^3.0"
- export PATH=$HOME/.composer/vendor/bin:$PATH
- tnw-install-nginx
- tnw-install-wordpress
- tnw-prepare-codeception
# Build the production plugin
- travis_retry composer build
# Install the medium plugin
- wp plugin install medium --force --activate --path=/tmp/wordpress
# Activate the plugin
- wp plugin install ./release/remove-medium-cross-links.zip --force --activate --path=/tmp/wordpress
# Export a dump of plugin-activated database to the _data folder
- wp db export $TRAVIS_BUILD_DIR/tests/_data/dump.sql --path=/tmp/wordpress
install:
- travis_retry composer install --prefer-dist --no-suggest
script:
- vendor/bin/codecept run
before_deploy:
- unzip -qo release/remove-medium-cross-links.zip -d build
deploy:
- provider: releases
api_key: $GITHUB_ACCESS_TOKEN
file: release/remove-medium-cross-links.zip
skip_cleanup: true
on:
condition: "$WP_VERSION = latest"
php: 7.1
tags: true
repo: TypistTech/remove-medium-cross-links
- provider: wordpress-plugin
edge:
source: TypistTech/dpl
branch: add-wordpress-plugin-deployment
slug: remove-medium-cross-links
username: tangrufus
build_dir: build
assets_dir: assets
skip_cleanup: true
on:
condition: "$WP_VERSION = latest"
php: 7.1
tags: true
repo: TypistTech/remove-medium-cross-links
- provider: pages
skip_cleanup: true
github_token: $GITHUB_ACCESS_TOKEN
local_dir: build
target_branch: nightly
project_name: "Remove Medium Cross Links"
on:
branch: master
condition: "$WP_VERSION = latest"
php: 7.2
repo: TypistTech/remove-medium-cross-links