Skip to content

Commit b6c71ee

Browse files
committed
Add Release Please action to automate releases
1 parent 923c69c commit b6c71ee

13 files changed

+211
-16
lines changed

.github/CODEOWNERS

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# See https://docs.github.com/en/github/creating-cloning-and-archiving-repositories/about-code-owners
2+
3+
# These owners will be the default owners for everything in
4+
# the repo. Unless a later match takes precedence
5+
* @simonrjones

.github/workflows/release-please.yml

+32
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: release-please
2+
on:
3+
push:
4+
branches:
5+
- main
6+
jobs:
7+
release-please:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- name: Create release
11+
id: release
12+
uses: google-github-actions/release-please-action@v3
13+
with:
14+
release-type: simple
15+
extra-files: |
16+
wp-config.load.php
17+
18+
# Run only once a new release is created:
19+
- uses: actions/checkout@master
20+
if: ${{ steps.release.outputs.release_created }}
21+
- name: Create release files
22+
run: |
23+
zip -r wordpress-multi-env-config.zip wp-config.*
24+
if: ${{ steps.release.outputs.release_created }}
25+
- name: Upload release files
26+
uses: svenstaro/upload-release-action@v2
27+
with:
28+
file: ./wordpress-multi-env-config.zip
29+
asset_name: wordpress-multi-env-config0.zip
30+
tag: ${{ steps.release.outputs.tag_name }}
31+
overwrite: true
32+
if: ${{ steps.release.outputs.release_created }}

CODE_OF_CONDUCT.md

+108
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,108 @@
1+
# Code of Conduct
2+
3+
## Our Pledge
4+
5+
We as members, contributors, and leaders pledge to make participation in our community a harassment-free experience for
6+
everyone, regardless of age, body size, visible or invisible disability, ethnicity, sex characteristics, gender identity
7+
and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, religion,
8+
or sexual identity and orientation.
9+
10+
We pledge to act and interact in ways that contribute to an open, welcoming, diverse, inclusive, and healthy community.
11+
12+
## Our Standards
13+
14+
Examples of behavior that contributes to a positive environment for our community include:
15+
16+
* Demonstrating empathy and kindness toward other people
17+
* Being respectful of differing opinions, viewpoints, and experiences
18+
* Giving and gracefully accepting constructive feedback
19+
* Accepting responsibility and apologizing to those affected by our mistakes, and learning from the experience
20+
* Focusing on what is best not just for us as individuals, but for the overall community
21+
22+
Examples of unacceptable behavior include:
23+
24+
* The use of sexualized language or imagery, and sexual attention or
25+
advances of any kind
26+
* Trolling, insulting or derogatory comments, and personal or political attacks
27+
* Public or private harassment
28+
* Publishing others' private information, such as a physical or email
29+
address, without their explicit permission
30+
* Other conduct which could reasonably be considered inappropriate in a
31+
professional setting
32+
33+
## Enforcement Responsibilities
34+
35+
Community leaders are responsible for clarifying and enforcing our standards of acceptable behavior and will take
36+
appropriate and fair corrective action in response to any behavior that they deem inappropriate, threatening, offensive,
37+
or harmful.
38+
39+
Community leaders have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits,
40+
issues, and other contributions that are not aligned to this Code of Conduct, and will communicate reasons for
41+
moderation decisions when appropriate.
42+
43+
## Scope
44+
45+
This Code of Conduct applies within all community spaces, and also applies when an individual is officially
46+
representing the community in public spaces. Examples of representing our community include using an official e-mail
47+
address, posting via an official social media account, or acting as an appointed representative at an online or offline
48+
event.
49+
50+
## Enforcement
51+
52+
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported to the community leaders
53+
responsible for enforcement at [[email protected]](mailto:[email protected]).
54+
All complaints will be reviewed and investigated promptly and fairly.
55+
56+
All community leaders are obligated to respect the privacy and security of the reporter of any incident.
57+
58+
## Enforcement Guidelines
59+
60+
Community leaders will follow these Community Impact Guidelines in determining the consequences for any action they
61+
deem in violation of this Code of Conduct:
62+
63+
### 1. Correction
64+
65+
**Community Impact**: Use of inappropriate language or other behavior deemed unprofessional or unwelcome in the
66+
community.
67+
68+
**Consequence**: A private, written warning from community leaders, providing clarity around the nature of the
69+
violation and an explanation of why the behavior was inappropriate. A public apology may be requested.
70+
71+
### 2. Warning
72+
73+
**Community Impact**: A violation through a single incident or series of actions.
74+
75+
**Consequence**: A warning with consequences for continued behavior. No interaction with the people involved, including
76+
unsolicited interaction with those enforcing the Code of Conduct, for a specified period of time. This includes
77+
avoiding interactions in community spaces as well as external channels like social media. Violating these terms may
78+
lead to a temporary or permanent ban.
79+
80+
### 3. Temporary Ban
81+
82+
**Community Impact**: A serious violation of community standards, including sustained inappropriate behavior.
83+
84+
**Consequence**: A temporary ban from any sort of interaction or public communication with the community for a
85+
specified period of time. No public or private interaction with the people involved, including unsolicited interaction
86+
with those enforcing the Code of Conduct, is allowed during this period. Violating these terms may lead to a permanent
87+
ban.
88+
89+
### 4. Permanent Ban
90+
91+
**Community Impact**: Demonstrating a pattern of violation of community standards, including sustained inappropriate
92+
behavior, harassment of an individual, or aggression toward or disparagement of classes of individuals.
93+
94+
**Consequence**: A permanent ban from any sort of public interaction within the community.
95+
96+
## Attribution
97+
98+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 2.0,
99+
available at https://www.contributor-covenant.org/version/2/0/code_of_conduct.html.
100+
101+
Community Impact Guidelines were inspired by [Mozilla's code of conduct enforcement ladder](https://github.com/mozilla/diversity).
102+
103+
[homepage]: https://www.contributor-covenant.org
104+
105+
For answers to common questions about this code of conduct, see the FAQ at
106+
https://www.contributor-covenant.org/faq. Translations are available at https://www.contributor-covenant.org/translations.
107+
108+

CONTRIBUTING.md

+32
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
# Contributing
2+
3+
We welcome contributions to WordPress Multi-Environment Config.
4+
5+
All contributors must agree to our [Code of Conduct](CODE_OF_CONDUCT.md).
6+
7+
WordPress Multi-Environment Config is released under the MIT license and is copyright Studio 24 Ltd. All contributors must accept these license and copyright conditions.
8+
9+
## Issues
10+
11+
Please submit any issues to the [issues log](https://github.com/studio24/wordpress-multi-env-config/issues). You are
12+
welcome to fork the project and create suggested fixes.
13+
14+
## Pull Requests
15+
16+
All contributions must be made on a branch and must be merged into the main branch via Pull Requests.
17+
18+
All Pull Requests need at least one approval from the Studio 24 development team.
19+
20+
## Creating new releases
21+
22+
This repo uses [Release Please](https://github.com/marketplace/actions/release-please-action) to automatically create releases, based on [semantic versioning](https://semver.org/).
23+
24+
To create a new release use [conventional commits](https://www.conventionalcommits.org/en/v1.0.0/) in your commit message. This will automatically create a Release PR, which is kept up to date with further commits and you can merge it to create the new release when you are ready.
25+
26+
Use the following keywords in your commits:
27+
28+
* `fix:` this indicates a bug fix and creates a new patch version (e.g. 1.0.1).
29+
* `feat:` this indicates a new feature and creates a new minor version (e.g. 1.1.0).
30+
* To create a new major version (e.g. 2.0.0) either append an exclamation mark to `fix!:` or `feat!:` or add a footer of `BREAKING CHANGE:` with details of what breaking changes there are.
31+
32+
If the action fails to run you can view the action and select `Re-run all jobs` to re-run it.

SECURITY.md

+29
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
# Security Issues
2+
3+
If you think that you have found a security issue in Strata, please don't use the issue tracker and don't publish it
4+
publicly. Send urgent or sensitive reports directly to [[email protected]](mailto:[email protected])
5+
6+
## Resolving Process
7+
8+
If you submit a report, here’s what will happen:
9+
10+
* We’ll acknowledge your report.
11+
* We'll confirm the vulnerability and ask any follow up questions.
12+
* The team will work on a fix.
13+
* Once the issue is resolved, we’ll post a security update along with thanks and credit for the discovery.
14+
15+
Once a patch has been created we will:
16+
17+
* Publish a release for all maintained versions of Strata.
18+
* Update the public [security advisories database](https://github.com/FriendsOfPHP/security-advisories).
19+
20+
### Note
21+
22+
* While we are working on a patch, please do not reveal the issue publicly.
23+
* The resolution takes anywhere between a couple of days to a month depending on its complexity.
24+
25+
## Attribution
26+
27+
This Security Issues policy is inspired by
28+
[Basecamp security response](https://github.com/basecamp/policies/blob/master/security/vulnerability-response.md) and
29+
[Symfony security issues](https://symfony.com/doc/master/contributing/code/security.html).

version.txt

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
2.0.0

wp-config.default.php

+1-3
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,8 @@
77
*
88
* Please note if you add constants in this file (i.e. define statements)
99
* these cannot be overridden in environment config files so make sure these are only set once.
10-
*
10+
*
1111
* @package Studio 24 WordPress Multi-Environment Config
12-
* @version 2.0.0
13-
* @author Studio 24 Ltd <[email protected]>
1412
*/
1513

1614

wp-config.development.php

+1-3
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,8 @@
44
*
55
* Enter any WordPress config settings that are specific to this environment
66
* in this file.
7-
*
7+
*
88
* @package Studio 24 WordPress Multi-Environment Config
9-
* @version 2.0.0
10-
* @author Studio 24 Ltd <[email protected]>
119
*/
1210

1311

wp-config.env.php

-2
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33
* Setup environments
44
*
55
* @package Studio 24 WordPress Multi-Environment Config
6-
* @version 2.0.0
7-
* @author Studio 24 Ltd <[email protected]>
86
*/
97

108

wp-config.load.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* WordPress Multi-Environment Config - Load config settings
44
*
55
* @package Studio 24 WordPress Multi-Environment Config
6-
* @version 2.0.0
6+
* @version 2.0.0 (x-release-please-version)
77
* @author Studio 24 <[email protected]>
88
*/
99

wp-config.local.php

-2
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,6 @@
1010
* in this file.
1111
*
1212
* @package Studio 24 WordPress Multi-Environment Config
13-
* @version 2.0.0
14-
* @author Studio 24 Ltd <[email protected]>
1513
*/
1614

1715

wp-config.production.php

-2
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,6 @@
66
* in this file.
77
*
88
* @package Studio 24 WordPress Multi-Environment Config
9-
* @version 2.0.0
10-
* @author Studio 24 Ltd <[email protected]>
119
*/
1210

1311

wp-config.staging.php

+1-3
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,8 @@
44
*
55
* Enter any WordPress config settings that are specific to this environment
66
* in this file.
7-
*
7+
*
88
* @package Studio 24 WordPress Multi-Environment Config
9-
* @version 2.0.0
10-
* @author Studio 24 Ltd <[email protected]>
119
*/
1210

1311

0 commit comments

Comments
 (0)