Skip to content

Commit

Permalink
Drop TravisCI for GitHub Actions
Browse files Browse the repository at this point in the history
  • Loading branch information
jbboehr committed Nov 13, 2020
1 parent 2770f82 commit 98244be
Show file tree
Hide file tree
Showing 12 changed files with 99 additions and 211 deletions.
4 changes: 4 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,7 @@ indent_size = 2

[package.xml]
indent_size = 1

[*.yml]
indent_size = 4
indent_style = space
2 changes: 1 addition & 1 deletion .gitattributes
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
/.ci/* linguist-documentation=true
/.github/* linguist-documentation=true
/tests/mustache-spec*.phpt linguist-generated=true
4 changes: 2 additions & 2 deletions .github/workflows/docker.sh → .github/scripts/docker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

set -e -o pipefail

source .ci/vars.sh
source .ci/fold.sh
source .github/scripts/vars.sh
source .github/scripts/fold.sh

# config
export DOCKER_NAME=${DOCKER_NAME:-"alpine"}
Expand Down
File renamed without changes.
8 changes: 4 additions & 4 deletions .github/workflows/linux.sh → .github/scripts/linux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

set -e -o pipefail

source .ci/vars.sh
source .ci/fold.sh
source .github/scripts/vars.sh
source .github/scripts/fold.sh

# config
export PHP_VERSION=${PHP_VERSION:-"7.4"}
Expand All @@ -14,11 +14,11 @@ export SUDO=sudo
function install_apt_packages() (
${SUDO} add-apt-repository ppa:ondrej/php
${SUDO} apt-get update
${SUDO} apt-get install -y libjson-c-dev libyaml-dev php${PHP_VERSION}-dev
${SUDO} apt-get install -y libjson-c-dev libyaml-dev php${PHP_VERSION}-dev lcov
)

cifold "install apt packages" install_apt_packages

# source and execute script used in travis
source .ci/travis_php.sh
source .github/scripts/suite.sh
run_all
4 changes: 2 additions & 2 deletions .github/workflows/osx.sh → .github/scripts/osx.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

set -e -o pipefail

source .ci/vars.sh
source .ci/fold.sh
source .github/scripts/vars.sh
source .github/scripts/fold.sh

# config
export PHP_VERSION=${PHP_VERSION:-"7.4"}
Expand Down
21 changes: 5 additions & 16 deletions .ci/travis_php.sh → .github/scripts/suite.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/env bash

source .ci/vars.sh
source .ci/fold.sh
source .github/scripts/vars.sh
source .github/scripts/fold.sh

export COVERAGE=${COVERAGE:-true}
export LIBMUSTACHE_VERSION=${LIBMUSTACHE_VERSION:-master}
Expand All @@ -26,19 +26,10 @@ function install_libmustache() (
make all install
)

function install_coveralls_lcov() (
set -o errexit -o pipefail -o xtrace

gem install coveralls-lcov
)

function before_install() (
set -o errexit -o pipefail

# Don't install this unless we're actually on travis
if [[ "${COVERAGE}" = "true" ]] && [[ "${TRAVIS}" = "true" ]]; then
cifold "install coveralls-lcov" install_coveralls_lcov
fi
return 0
)

function build_php_mustache() (
Expand Down Expand Up @@ -91,7 +82,7 @@ function script() (
cifold "main test suite" test_php_mustache
)

function upload_coverage() (
function process_coverage() (
set -o errexit -o pipefail -o xtrace

lcov --no-checksum --directory . --capture --compat-libtool --output-file coverage.info
Expand All @@ -100,15 +91,13 @@ function upload_coverage() (
--remove coverage.info "/home/travis/build/include/*" \
--compat-libtool \
--output-file coverage.info

coveralls-lcov coverage.info
)

function after_success() (
set -o errexit -o pipefail

if [[ "${COVERAGE}" = "true" ]]; then
cifold "upload coverage" upload_coverage
cifold "upload coverage" process_coverage
fi
)

Expand Down
File renamed without changes.
119 changes: 33 additions & 86 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
@@ -1,95 +1,42 @@

name: docker

on:
push:
branches:
- master
- github-actions
- ci
- master
- github-actions
- ci
pull_request:
branches:
- master
- master

jobs:
debian_php72:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I am putting everything in a FSCKING BASH SCRIPT
env:
PHP_VERSION: "7.2"
DOCKER_NAME: debian
run: bash ./.github/workflows/docker.sh
debian_php73:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I am putting everything in a FSCKING BASH SCRIPT
env:
PHP_VERSION: "7.3"
DOCKER_NAME: debian
run: bash ./.github/workflows/docker.sh
debian_php74:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I am putting everything in a FSCKING BASH SCRIPT
env:
PHP_VERSION: "7.4"
DOCKER_NAME: debian
run: bash ./.github/workflows/docker.sh
debian_php80:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I am putting everything in a FSCKING BASH SCRIPT
env:
PHP_VERSION: "8.0-rc"
DOCKER_NAME: debian
run: bash ./.github/workflows/docker.sh
alpine_php72:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I am putting everything in a FSCKING BASH SCRIPT
env:
PHP_VERSION: "7.2"
DOCKER_NAME: alpine
run: bash ./.github/workflows/docker.sh
alpine_php73:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I am putting everything in a FSCKING BASH SCRIPT
env:
PHP_VERSION: "7.3"
DOCKER_NAME: alpine
run: bash ./.github/workflows/docker.sh
alpine_php74:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I am putting everything in a FSCKING BASH SCRIPT
env:
PHP_VERSION: "7.4"
DOCKER_NAME: alpine
run: bash ./.github/workflows/docker.sh
alpine_php80:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I am putting everything in a FSCKING BASH SCRIPT
env:
PHP_VERSION: "8.0-rc"
DOCKER_NAME: alpine
run: bash ./.github/workflows/docker.sh
fedora_phpdefault:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I am putting everything in a FSCKING BASH SCRIPT
env:
DOCKER_NAME: fedora
TEST_PHP_EXECUTABLE: /usr/bin/php
run: bash ./.github/workflows/docker.sh
docker:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
PHP_VERSION:
- "7.2"
- "7.3"
- "7.4"
# - "8.0-rc"
DOCKER_NAME:
- "alpine"
- "debian"
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I am putting everything in a FSCKING BASH SCRIPT
env:
PHP_VERSION: ${{ matrix.PHP_VERSION }}
DOCKER_NAME: ${{ matrix.DOCKER_NAME }}
run: bash ./.github/scripts/docker.sh
fedora:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I am putting everything in a FSCKING BASH SCRIPT
env:
DOCKER_NAME: fedora
TEST_PHP_EXECUTABLE: /usr/bin/php
run: bash ./.github/scripts/docker.sh
60 changes: 28 additions & 32 deletions .github/workflows/linux.yml
Original file line number Diff line number Diff line change
@@ -1,37 +1,33 @@
name: linux

on:
push:
branches:
- master
- github-actions
- ci
pull_request:
branches:
- master
push:
branches:
- master
- github-actions
- ci
pull_request:
branches:
- master

jobs:
php72:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I'm putting everything in a FSCKING BASH SCRIPT
env:
PHP_VERSION: "7.2"
run: bash ./.github/workflows/linux.sh
php73:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I'm putting everything in a FSCKING BASH SCRIPT
env:
PHP_VERSION: "7.3"
run: bash ./.github/workflows/linux.sh
php74:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I'm putting everything in a FSCKING BASH SCRIPT
env:
PHP_VERSION: "7.4"
run: bash ./.github/workflows/linux.sh
linux:
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
PHP_VERSION: ["7.2", "7.3", "7.4", "8.0"]
COVERAGE: ["true", "false"]
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I'm putting everything in a FSCKING BASH SCRIPT
env:
PHP_VERSION: ${{ matrix.PHP_VERSION }}
COVERAGE: ${{ matrix.COVERAGE }}
run: bash ./.github/scripts/linux.sh
- name: Coveralls
if: ${{ matrix.COVERAGE == 'true' }}
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
path-to-lcov: ./coverage.info
52 changes: 20 additions & 32 deletions .github/workflows/osx.yml
Original file line number Diff line number Diff line change
@@ -1,37 +1,25 @@
name: osx

on:
push:
branches:
- master
- github-actions
- ci
pull_request:
branches:
- master
push:
branches:
- master
- github-actions
- ci
pull_request:
branches:
- master

jobs:
php72:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I'm putting everything in a FSCKING BASH SCRIPT
env:
PHP_VERSION: "7.2"
run: bash ./.github/workflows/osx.sh
php73:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I'm putting everything in a FSCKING BASH SCRIPT
env:
PHP_VERSION: "7.3"
run: bash ./.github/workflows/osx.sh
php74:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I'm putting everything in a FSCKING BASH SCRIPT
env:
PHP_VERSION: "7.4"
run: bash ./.github/workflows/osx.sh
osx:
runs-on: macos-latest
strategy:
fail-fast: false
matrix:
PHP_VERSION: ["7.2", "7.3", "7.4"]
steps:
- uses: actions/checkout@v2
- name: I am tired of writing this shit in YAML and learning a new DSL for every CI service so I'm putting everything in a FSCKING BASH SCRIPT
env:
PHP_VERSION: ${{ matrix.PHP_VERSION }}
run: bash ./.github/scripts/osx.sh
Loading

0 comments on commit 98244be

Please sign in to comment.