Skip to content

Commit

Permalink
Merge branch 'develop' into trunk
Browse files Browse the repository at this point in the history
  • Loading branch information
felipeelia committed Dec 11, 2024
2 parents 4a8ec0a + 2a7b388 commit a5364a7
Show file tree
Hide file tree
Showing 22 changed files with 15,874 additions and 16,377 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/build-and-tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,18 +10,18 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Set PHP version
uses: shivammathur/setup-php@v2
with:
php-version: '8.2'
coverage: none

- name: install node v18
uses: actions/setup-node@v3
- name: install node v20
uses: actions/setup-node@v4
with:
node-version: 18
node-version: 20

- name: Build
run: |
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/build-with-vendor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,18 +12,18 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Set PHP version
uses: shivammathur/setup-php@v2
with:
php-version: '8.2'
coverage: none

- name: install node v18
uses: actions/setup-node@v3
- name: install node v20
uses: actions/setup-node@v4
with:
node-version: 18
node-version: 20

- name: Build
run: |
Expand All @@ -37,7 +37,7 @@ jobs:
run: npm run build:zip

- name: Make artifacts available
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: elasticpress-labs
retention-days: 2
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Linting
env:
COMPOSER_VERSION: "2"
COMPOSER_CACHE: "${{ github.workspace }}/.composer-cache"
NODE_VERSION: "18"
NODE_VERSION: "20"
NODE_CACHE: "${{ github.workspace }}/node_modules_cache"

on:
Expand All @@ -22,20 +22,20 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- name: Set standard 10up cache directories
run: |
sudo npm config set cache "${{ env.NODE_CACHE }}" --global
- name: Prepare npm cache
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: ${{ env.NODE_CACHE }}
key: npm-${{ env.NODE_VERSION }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
npm-${{ env.NODE_VERSION }}-
- name: "install node v${{ env.NODE_VERSION }}"
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: ${{ env.NODE_VERSION }}

Expand All @@ -51,13 +51,13 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Set standard 10up cache directories
run: |
composer config -g cache-dir "${{ env.COMPOSER_CACHE }}"
- name: Prepare composer cache
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: ${{ env.COMPOSER_CACHE }}
key: composer-${{ env.COMPOSER_VERSION }}-${{ hashFiles('**/composer.lock') }}
Expand Down
26 changes: 9 additions & 17 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@ name: Test
env:
COMPOSER_VERSION: "2"
COMPOSER_CACHE: "${{ github.workspace }}/.composer-cache"
NODE_VERSION: "18"
NODE_CACHE: "${{ github.workspace }}/node_modules_cache"

on:
schedule:
Expand All @@ -24,29 +22,17 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Start MySQL
run: sudo systemctl start mysql.service

- name: Configure sysctl limits
run: |
sudo swapoff -a
sudo sysctl -w vm.swappiness=1
sudo sysctl -w fs.file-max=262144
sudo sysctl -w vm.max_map_count=262144
- name: Setup Elasticsearch
uses: getong/[email protected]
with:
elasticsearch version: '7.10.1'


- name: Set standard 10up cache directories
run: |
composer config -g cache-dir "${{ env.COMPOSER_CACHE }}"
- name: Prepare composer cache
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: ${{ env.COMPOSER_CACHE }}
key: composer-${{ env.COMPOSER_VERSION }}-${{ hashFiles('**/composer.lock') }}
Expand All @@ -62,6 +48,12 @@ jobs:
- name: Install dependencies
run: composer install

- name: Spin up Elasticsearch
run: git clone https://github.com/10up/ElasticPress.git elasticpress-plugin && cd elasticpress-plugin && npm run es:start

- name: Check ES response
run: curl --connect-timeout 5 --max-time 10 --retry 5 --retry-max-time 40 --retry-all-errors http://127.0.0.1:8890

- name: Setup WP Tests
run: |
bash bin/install-wp-tests.sh wordpress_test root root 127.0.0.1
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/wordpress-latest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,6 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: WordPress version checker
uses: skaut/wordpress-version-checker@v1.2.0
uses: skaut/wordpress-version-checker@v2.2.2
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
7 changes: 2 additions & 5 deletions .lintstagedrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,10 @@
"*.css": [
"10up-toolkit lint-style"
],
"*.js": [
"10up-toolkit lint-js"
],
"*.jsx": [
"*.{js,jsx}": [
"10up-toolkit lint-js"
],
"*.php": [
"./vendor/bin/phpcs --extensions=php --warning-severity=8 -s"
"./vendor/bin/phpcs --extensions=php --runtime-set testVersion 7.4- -s"
]
}
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
18
20
1 change: 0 additions & 1 deletion .stylelintignore

This file was deleted.

2 changes: 1 addition & 1 deletion .stylelintrc
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"extends": "@10up/stylelint-config"
"extends": [ "@10up/stylelint-config" ]
}
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,18 @@ All notable changes to this project will be documented in this file, per [the Ke
### Security
-->

## [2.3.1] - 2024-12-11

### Added
- ElasticPress as a plugin dependency. Props [@jeffpaul](https://github.com/jeffpaul) via [#104](https://github.com/10up/ElasticPress/pull/104).

### Changed
- Bumped actions/upload-artifact from v3 to v4. Props [@iamdharmesh](https://github.com/iamdharmesh) via [#106](https://github.com/10up/ElasticPress/pull/106).
- Update versions of GitHub Actions, composer, and node packages. Props [@felipeelia](https://github.com/felipeelia) via [#110](https://github.com/10up/ElasticPress/pull/110) and [#111](https://github.com/10up/ElasticPress/pull/111).

## Fixed
- Textdomain in the Users feature. Props [@burhandodhy](https://github.com/burhandodhy) via [#114](https://github.com/10up/ElasticPress/pull/114).

## [2.3.0] - 2024-03-04

This version introduces the new *External Content* feature. Check [our blog post](https://www.elasticpress.io/blog/2024/03/pew-research-center-external-files-as-a-source-for-your-search) for more info.
Expand Down Expand Up @@ -115,6 +127,7 @@ This version introduces the new *External Content* feature. Check [our blog post
- Initial plugin release.

[Unreleased]: https://github.com/10up/ElasticPressLabs/compare/trunk...develop
[2.3.1]: https://github.com/10up/ElasticPressLabs/compare/2.3.0...2.3.1
[2.3.0]: https://github.com/10up/ElasticPressLabs/compare/2.2.0...2.3.0
[2.2.0]: https://github.com/10up/ElasticPressLabs/compare/2.1.1...2.2.0
[2.1.1]: https://github.com/10up/ElasticPressLabs/compare/2.1.0...2.1.1
Expand Down
8 changes: 4 additions & 4 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,12 @@ The `develop` branch is the development branch which means it contains the next
## Release instructions

1. Branch: Starting from `develop`, cut a release branch named `release/X.Y.Z` for your changes.
1. Version bump: Bump the version number in `elasticpresslabs.php`, `/languages/ElasticPressLabs.pot`, `package-lock.json`, `package.json`, `readme.txt`, and any other relevant files if it does not already reflect the version being released. In `elasticpresslabs.php` update both the plugin "Version:" property and the plugin `ELASTICPRESS_LABS_VERSION` constant.
1. Version bump: Bump the version number in `elasticpresslabs.php`, `/languages/elasticpress-labs.pot`, `package-lock.json`, `package.json`, `readme.txt`, and any other relevant files if it does not already reflect the version being released. In `elasticpresslabs.php` update both the plugin "Version:" property and the plugin `ELASTICPRESS_LABS_VERSION` constant.
1. Changelog: Add/update the changelog in `CHANGELOG.md` and `readme.txt`, ensuring to link the [X.Y.Z] release reference in the footer of `CHANGELOG.md` (e.g., https://github.com/10up/ElasticPressLabs/compare/X.Y.Z-1...X.Y.Z).
1. Props: Update `CREDITS.md` file with any new contributors, confirm maintainers are accurate.
1. Readme updates: Make any other readme changes as necessary. `README.md` is geared toward GitHub and `readme.txt` contains WordPress.org-specific content. The two are slightly different.
1. New files: Check to be sure any new files/paths that are unnecessary in the production version are included in `.gitattributes`.
1. POT file: Run `wp i18n make-pot . languages/ElasticPressLabs.pot` and commit the file. In case of errors, try to disable Xdebug (see [#3079](https://github.com/10up/ElasticPress/pull/3079#issuecomment-1291028290).)
1. POT file: Run `wp i18n make-pot . languages/elasticpress-labs.pot` and commit the file. In case of errors, try to disable Xdebug (see [#3079](https://github.com/10up/ElasticPress/pull/3079#issuecomment-1291028290).)
1. Release date: Double check the release date in both changelog files.
1. Merge: Merge the release branch/PR into `develop`, then make a non-fast-forward merge from `develop` into `trunk` (`git checkout trunk && git merge --no-ff develop`). `trunk` contains the stable development version.
1. Test: While still on the `trunk` branch, test for functionality locally.
Expand All @@ -49,12 +49,12 @@ The `develop` branch is the development branch which means it contains the next
There may be cases where we have an urgent/important fix that ideally gets into a release quickly without any other changes (e.g., a "hotfix") so as to reduce (1) the amount or testing before being confident in the release and (2) to reduce the chance of unintended side effects from the extraneous non-urgent/important changes. In cases where code has previously been merged into `develop` but that ideally is not part of a hotfix, the normal release instructions above will not suffice as they would release all code merged to `develop` alongside the intended urgent/important "hotfix" change(s). In case of needing to release a "hotfix" the following are the recommended steps to take.

1. Branch: Starting from `trunk`, cut a hotfix release branch named `hotfix/X.Y.Z` for your hotfix change(s).
1. Version bump: Bump the version number in `elasticpresslabs.php`, `/languages/ElasticPressLabs.pot`, `package-lock.json`, `package.json`, `readme.txt`, and any other relevant files if it does not already reflect the version being released. In `elasticpresslabs.php` update both the plugin "Version:" property and the plugin `ELASTICPRESS_LABS_VERSION` constant.
1. Version bump: Bump the version number in `elasticpresslabs.php`, `/languages/elasticpress-labs.pot`, `package-lock.json`, `package.json`, `readme.txt`, and any other relevant files if it does not already reflect the version being released. In `elasticpresslabs.php` update both the plugin "Version:" property and the plugin `ELASTICPRESS_LABS_VERSION` constant.
1. Changelog: Add/update the changelog in `CHANGELOG.md` and `readme.txt`, ensuring to link the [X.Y.Z] release reference in the footer of `CHANGELOG.md` (e.g., https://github.com/10up/ElasticPressLabs/compare/X.Y.Z-1...X.Y.Z).
1. Props: Update `CREDITS.md` file with any new contributors, confirm maintainers are accurate.
1. Readme updates: Make any other readme changes as necessary. `README.md` is geared toward GitHub and `readme.txt` contains WordPress.org-specific content. The two are slightly different.
1. New files: Check to be sure any new files/paths that are unnecessary in the production version are included in `.gitattributes`.
1. POT file: Run `wp i18n make-pot . lang/elasticpress.pot` and commit the file.
1. POT file: Run `wp i18n make-pot . lang/elasticpress-labs.pot` and commit the file.
1. Release date: Double check the release date in both changelog files.
1. Merge: Merge the release branch/PR into `trunk`. `trunk` contains the stable development version.
1. Test: While still on the `trunk` branch, test for functionality locally.
Expand Down
1 change: 1 addition & 0 deletions CREDITS.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ Thank you to all the people who have already contributed to this repository via
[Burhan Nasir (@burhandodhy)](https://github.com/burhandodhy),
[Mohammed Razzaq (@MARQAS)](https://github.com/MARQAS),
[Eric Caron (@ecaron)](https://github.com/ecaron),
[Dharmesh Patel (@iamdharmesh)](https://github.com/iamdharmesh),
and
[Felipe Elia (@felipeelia)](https://github.com/felipeelia).

Expand Down
Loading

0 comments on commit a5364a7

Please sign in to comment.