This repository has been archived by the owner on Nov 15, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(ci): migration to github actions
- Loading branch information
1 parent
4ef0759
commit 6875aac
Showing
2 changed files
with
60 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
name: Release | ||
on: [push, pull_request] | ||
|
||
jobs: | ||
test: | ||
name: Test @ PHP ${{ matrix.php-version }} - x86 - ubuntu-latest | ||
# Support [skip ci] out of box with github actions Workaround | ||
# Only works for push https://github.com/actions/runner/issues/774 | ||
if: github.event_name == 'pull_request' || (github.event_name == 'push' && contains(toJson(github.event.commits), '[skip ci]') == false) | ||
strategy: | ||
matrix: | ||
php-version: | ||
- 7.4 | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
- name: Setup NodeJS LTS | ||
uses: actions/setup-node@v2 | ||
- name: Install dependencies | ||
run: | | ||
npm prune | ||
npm i | ||
- name: Install Dependencies::PHP${{ matrix.php-version }} | ||
run: | | ||
echo "$HOME/.composer/vendor/bin" >> $GITHUB_PATH | ||
composer global require dealerdirect/phpcodesniffer-composer-installer roave/security-advisories:dev-master squizlabs/php_codesniffer phpcompatibility/php-compatibility | ||
# TODO migrate the below to gulp calls | ||
- name: Check PHP Compatibility | ||
run: phpcs --standard=PHPCompatibility -q -n --colors --runtime-set testVersion ${{ matrix.php-version }} --extensions=php --ignore=node_modules,vendor,templates_c . || exit 1; | ||
- name: Check PSR12 Standard | ||
run: phpcs --standard=PSR12 -q -n --colors --extensions=php,inc,lib --ignore=node_modules,vendor,templates_c . | ||
- name: Check Linting | ||
run: npm run lint | ||
release: | ||
name: Release @ NodeJS LTS - x86 - ubuntu-latest | ||
runs-on: ubuntu-latest | ||
needs: | ||
- test | ||
if: github.ref == 'refs/heads/master' && github.event_name == 'push' | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
persist-credentials: false | ||
- name: Setup NodeJS LTS | ||
uses: actions/setup-node@v2 | ||
- name: Install dependencies | ||
run: | | ||
npm prune | ||
npm i | ||
- name: Release | ||
env: | ||
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | ||
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} | ||
WHMCSMP_LOGIN: ${{ secrets.WHMCSMP_LOGIN }} | ||
WHMCSMP_PASSWORD: ${{ secrets.WHMCSMP_PASSWORD }} | ||
WHMCSMP_PRODUCTID: ${{ secrets.WHMCSMP_PRODUCTID_ISPAPI_DOMAINCHECKER }} | ||
run: npx semantic-release |
This file was deleted.
Oops, something went wrong.