Skip to content

Commit

Permalink
CON
Browse files Browse the repository at this point in the history
TRIBUTING and readme and vn
  • Loading branch information
pwtyler committed May 17, 2023
1 parent 64cb904 commit 15ad78a
Show file tree
Hide file tree
Showing 4 changed files with 69 additions and 19 deletions.
47 changes: 47 additions & 0 deletions CONTRIBUTING.MD
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
## Contributing ##

The best way to contribute to the development of this plugin is by participating on the GitHub project:

https://github.com/pantheon-systems/plugin-pipeline-example

Pull requests and issues are welcome!

## Workflow

Development and releases are structured around two branches, `main` and `release`. The `main` branch is the main branch for the repository, and is the source and destination for feature branches.

We prefer to squash commits (i.e. avoid merge PRs) from a feature branch into `main` when merging, and to include the PR # in the commit message. PRs to `main` should also include any relevent updates to the changelog in readme.txt. For example, if a feature constitutes a minor or major version bump, that version update should be discussed and made as part of approving and merging the feature into `main`.

`main` should be stable and usable, though possibly a few commits ahead of the public release on wp.org.

The `release` branch matches the latest stable release deployed to [wp.org](wp.org).

## Testing

Every push lints and tests with PHPCS and PHPUnit. This project uses [Pantheon WP Coding Standards](https://github.com/pantheon-systems/Pantheon-WP-Coding-Standards).

## Release Process

1. From `main`, checkout a new branch `release_X.Y.Z`.
1. Make a release commit:
* Drop the `-dev` from the version number in `README.md`, `readme.txt`, and `rossums-universal-robots.php`.
* Update the "Latest" heading in the changelog to the new version number with the date
* Commit these changes with the message `Release X.Y.Z`
* Push the release branch up.
1. Open a Pull Request to merge `release_X.Y.Z` into `release`. Your PR should consist of all commits to `main` since the last release, and one commit to update the version number. The PR name should also be `Release X.Y.Z`.
1. After all tests pass and you have received approval from a [CODEOWNER](./CODEOWNERS), merge the PR into `release`. "Rebase and merge" is preferred in this case. _Never_ squash to `release`.
1. Pull `release` locally, create a new tag (based on version number from previous steps), and push up. The tag should _only_ be the version number. It _should not_ be prefixed `v` (i.e. `X.Y.Z`, not `vX.Y.X`).
* `git tag X.Y.Z`
* `git push --tags`
1. Confirm that the necessary assets are present in the newly created tag, and test on a WP install if desired.
1. Create a [new release](https://github.com/pantheon-systems/plugin-pipeline-example/releases/new) using the tag created in the previous steps, naming the release with the new version number, and targeting the tag created in the previous step. Paste the release changelog from the `Changelog` section of [the readme](readme.txt) into the body of the release, including the links to the closed issues if applicable.
1. Wait for the [_Release rossums-universal-robots plugin to wp.org_ action](https://github.com/pantheon-systems/rossums-universal-robots/actions/workflows/wordpress-plugin-deploy.yml) to finish deploying to the WordPress.org plugin repository. If all goes well, users with SVN commit access for that plugin will receive an emailed diff of changes.
1. Check WordPress.org: Ensure that the changes are live on [the plugin repository](https://wordpress.org/plugins/rossums-universal-robots/). This may take a few minutes.
1. Following the release, prepare the next dev version with the following steps:
* `git checkout main`
* `git rebase release`
* Update the version number in all locations, incrementing the version by one patch version, and add the `-dev` flag (e.g. after releasing `1.2.3`, the new verison will be `1.2.4-dev`)
* Add a new `### X.Y.X-dev` heading to the changelog
* `git add -A .`
* `git commit -m "Prepare X.Y.X-dev"`
* `git push origin main`
19 changes: 17 additions & 2 deletions README.MD
Original file line number Diff line number Diff line change
@@ -1,2 +1,17 @@
# Rossums Universal Robots - A Demo Plugin
See the robots hard at work.
# Rossums Universal Robots
Contributors: [getpantheon](https://profiles.wordpress.org/getpantheon)
Donate link: https://example.com/
Tags: comments, spam
Requires at least: 4.5
Tested up to: 6.2.1
Requires PHP: 5.6
Stable tag: 0.1.0-dev
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

See the robots hard at work.

## Changelog

### 0.1.0-dev
* Initial Release [[1](https://github.com/pantheon-systems/plugin-pipeline-example/pull/1)]
20 changes: 4 additions & 16 deletions readme.txt
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
=== Rossums Universal Robots ===
Contributors: (this should be a list of wordpress.org userid's)
Contributors: [getpantheon](https://profiles.wordpress.org/getpantheon)
Donate link: https://example.com/
Tags: comments, spam
Requires at least: 4.5
Tested up to: 6.2.1
Requires PHP: 5.6
Stable tag: 0.1.0
Stable tag: 0.1.0-dev
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Expand Down Expand Up @@ -68,20 +68,8 @@ directory take precedence. For example, `/assets/screenshot-1.png` would win ove

== Changelog ==

= 1.0 =
* A change since the previous version.
* Another change.

= 0.5 =
* List versions from most recent at top to oldest at bottom.

== Upgrade Notice ==

= 1.0 =
Upgrade notices describe the reason a user should upgrade. No more than 300 characters.

= 0.5 =
This version fixes a security related bug. Upgrade immediately.
= 0.1.0-dev =
* Initial Release [[1](https://github.com/pantheon-systems/plugin-pipeline-example/pull/1)]

== Arbitrary section ==

Expand Down
2 changes: 1 addition & 1 deletion rossums-universal-robots.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
* Author URI: pantheon.io
* Text Domain: rossums-universal-robots
* Domain Path: /languages
* Version: 0.1.0
* Version: 0.1.0-dev
*
* @package Rossums_Universal_Robots
*/
Expand Down

0 comments on commit 15ad78a

Please sign in to comment.