-
Notifications
You must be signed in to change notification settings - Fork 155
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Feature/travis ci to GitHub actions (#282) * Updates Composer/NPM Dependencies & Adds New GitHub Actions * Moves All CI/CI Functionality to GitHub Actions - Updates Composer & NPM dependencies to newer versions. - Updates default development environment WordPress version to 5.6.x. - Fixes missing updated to the language POT file. - Moves to using a GitHub Release for WordPress.org deployment. - Removes TravisCI configuration. * Fixes Login Page XSS Issue (#283) - Adds escaping to the errot output message. - Adds escaping to the login button output. * Patch Version Bump & Changelog Updates for Release
- Loading branch information
Showing
21 changed files
with
4,054 additions
and
3,423 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,49 @@ | ||
name: Internationalization | ||
|
||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- dev | ||
- main | ||
- 'release/**' | ||
- 'feature/**' | ||
- 'fix/**' | ||
|
||
env: | ||
WP_MULTISITE: 0 | ||
|
||
jobs: | ||
check: | ||
name: Setup & Check | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout Code | ||
uses: actions/checkout@v2 | ||
|
||
- name: Setup Node Environment | ||
uses: actions/setup-node@v1 | ||
# https://github.com/marketplace/actions/setup-node-js-environment | ||
with: | ||
node-version: 12.x | ||
|
||
- name: Cache node modules | ||
uses: actions/cache@v2 | ||
env: | ||
npm-cache-name: cache-node-modules | ||
with: | ||
# npm cache files are stored in `~/.npm` on Linux/macOS | ||
path: ~/.npm | ||
key: ${{ runner.os }}-build-${{ env.npm-cache-name }}-${{ hashFiles('**/package-lock.json') }} | ||
restore-keys: | | ||
${{ runner.os }}-build-${{ env.npm-cache-name }}- | ||
${{ runner.os }}-build- | ||
${{ runner.os }}- | ||
- name: NPM Install | ||
run: npm install | ||
|
||
- name: Check i18n Compliance | ||
run: npm run i18n:check |
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,50 @@ | ||
name: Coding Standards | ||
|
||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- dev | ||
- main | ||
- 'release/**' | ||
- 'feature/**' | ||
- 'fix/**' | ||
|
||
env: | ||
PHP_VERSION: 7.3 | ||
WP_MULTISITE: 0 | ||
|
||
jobs: | ||
check: | ||
name: Setup & Check | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout Code | ||
uses: actions/checkout@v2 | ||
|
||
- name: Setup PHP Environment | ||
uses: shivammathur/setup-php@v2 | ||
# https://github.com/marketplace/actions/setup-php-action | ||
with: | ||
php-version: ${{ env.PHP_VERSION }} | ||
tools: composer:v1 | ||
|
||
- name: Cache Composer dependencies | ||
uses: actions/cache@v2 | ||
env: | ||
composer-cache-name: cache-vendor | ||
with: | ||
path: ~/vendor | ||
key: ${{ runner.os }}-build-${{ env.composer-cache-name }}-${{ hashFiles('**/composer.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-build-${{ env.composer-cache-name }}- | ||
${{ runner.os }}-build- | ||
${{ runner.os }}- | ||
- name: Install Composer Dependencies | ||
run: composer install | ||
|
||
- name: Check WordPress Coding Standards | ||
run: composer run-script lint |
This file was deleted.
Oops, something went wrong.
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,76 @@ | ||
name: PR Unit Testing | ||
|
||
on: | ||
# Allows you to run this workflow manually from the Actions tab | ||
workflow_dispatch: | ||
# Triggers the workflow on pull request events | ||
pull_request: | ||
|
||
env: | ||
PHP_PREF_MIN_VERSION: '7.3' | ||
WP_STABLE_VERSION: '5.6.*' | ||
WP_MULTISITE: 0 | ||
|
||
jobs: | ||
test: | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
fail-fast: false | ||
matrix: | ||
include: | ||
- job-name: 'Latest Stable Requirements' | ||
bleeding-edge: false | ||
php-version: '7.3' | ||
wordpress-version: '5.6.*' | ||
wp-multisite-mode: 0 | ||
|
||
name: '${{ matrix.job-name }} (PHP:${{ matrix.php-version }}/WP:${{ matrix.wordpress-version }})' | ||
|
||
steps: | ||
- name: Checkout Code | ||
uses: actions/checkout@v2 | ||
|
||
- name: Setup PHP Environment | ||
uses: shivammathur/setup-php@v2 | ||
# https://github.com/marketplace/actions/setup-php-action | ||
with: | ||
php-version: ${{ matrix.php-version }} | ||
tools: composer:v1 | ||
|
||
- name: Setup Node Environment | ||
uses: actions/setup-node@v1 | ||
# https://github.com/marketplace/actions/setup-node-js-environment | ||
with: | ||
node-version: 12.x | ||
|
||
- name: Cache Composer dependencies | ||
uses: actions/cache@v2 | ||
env: | ||
composer-cache-name: cache-vendor | ||
with: | ||
path: ~/vendor | ||
key: ${{ runner.os }}-build-${{ env.composer-cache-name }}-${{ hashFiles('**/composer.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-build-${{ env.composer-cache-name }}- | ||
${{ runner.os }}-build- | ||
${{ runner.os }}- | ||
- name: Require Specified WordPress Version | ||
run: composer require wordpress/wordpress:${{ matrix.wordpress-version }} --dev --prefer-source --update-with-all-dependencies | ||
|
||
- name: Update Composer Lockfile for Specified WordPress Version | ||
run: composer update wordpress/wordpress:${{ matrix.wordpress-version }} --lock --prefer-source | ||
|
||
- name: PHPUnit PHP 7.4 Support | ||
if: matrix.php-version == '7.4' | ||
run: | | ||
composer global require phpunit/php-code-coverage=dev-master | ||
composer global require sebastian/global-state:dev-master | ||
composer global require phpunit/phpunit=dev-master | ||
- name: NPM Setup | ||
run: npm install | ||
|
||
- name: Unit Tests | ||
run: npm run test |
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,54 @@ | ||
name: Prepare & Deploy a Release | ||
|
||
on: | ||
release: | ||
types: [published] | ||
|
||
env: | ||
WP_MULTISITE: 0 | ||
|
||
jobs: | ||
release: | ||
name: New Release | ||
|
||
if: github.repository == 'oidc-wp/openid-connect-generic' | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout Code | ||
uses: actions/checkout@v2 | ||
|
||
- name: Setup Node Environment | ||
uses: actions/setup-node@v1 | ||
# https://github.com/marketplace/actions/setup-node-js-environment | ||
with: | ||
node-version: 12.x | ||
|
||
- name: Cache Node Modules | ||
uses: actions/cache@v2 | ||
env: | ||
npm-cache-name: cache-node-modules | ||
with: | ||
# npm cache files are stored in `~/.npm` on Linux/macOS | ||
path: ~/.npm | ||
key: ${{ runner.os }}-build-${{ env.npm-cache-name }}-${{ hashFiles('**/package-lock.json') }} | ||
restore-keys: | | ||
${{ runner.os }}-build-${{ env.npm-cache-name }}- | ||
${{ runner.os }}-build- | ||
${{ runner.os }}- | ||
- name: NPM Install | ||
run: npm install | ||
|
||
- name: Prepare a WordPress.org Release | ||
run: npm run release | ||
|
||
- name: WordPress.org Plugin Deploy | ||
uses: nk-o/action-wordpress-plugin-deploy@master | ||
# https://github.com/marketplace/actions/wordpress-plugin-deploy | ||
env: | ||
SVN_PASSWORD: ${{ secrets.SVN_PASSWORD }} | ||
SVN_USERNAME: ${{ secrets.SVN_USERNAME }} | ||
SOURCE_DIR: dist/ | ||
SLUG: daggerhart-openid-connect-generic |
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,55 @@ | ||
name: Static Code Analysis | ||
|
||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- dev | ||
- main | ||
- 'release/**' | ||
- 'feature/**' | ||
- 'fix/**' | ||
|
||
env: | ||
PHP_VERSION: 7.3 | ||
WP_MODE: 'single' | ||
WP_MULTISITE: 0 | ||
WP_VERSION: '5.6.*' | ||
|
||
jobs: | ||
check: | ||
name: Setup & Check | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout Code | ||
uses: actions/checkout@v2 | ||
|
||
- name: Setup PHP Environment | ||
uses: shivammathur/setup-php@v2 | ||
# https://github.com/marketplace/actions/setup-php-action | ||
with: | ||
php-version: ${{ env.PHP_VERSION }} | ||
tools: composer:v1 | ||
|
||
- name: Cache Composer dependencies | ||
uses: actions/cache@v2 | ||
env: | ||
composer-cache-name: cache-vendor | ||
with: | ||
path: ~/vendor | ||
key: ${{ runner.os }}-build-${{ env.composer-cache-name }}-${{ hashFiles('**/composer.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-build-${{ env.composer-cache-name }}- | ||
${{ runner.os }}-build- | ||
${{ runner.os }}- | ||
- name: Require Specified WordPress Version | ||
run: composer require wordpress/wordpress:${{ env.WP_VERSION }} --dev --prefer-source --update-with-all-dependencies | ||
|
||
- name: Install Composer Dependencies | ||
run: composer install | ||
|
||
- name: Perform Static Analysis | ||
run: composer run-script analyze |
Oops, something went wrong.