Skip to content

Commit

Permalink
Update PR-template & add github-folder contents
Browse files Browse the repository at this point in the history
  • Loading branch information
eebbi committed Nov 16, 2023
1 parent 719900f commit b147b3f
Show file tree
Hide file tree
Showing 7 changed files with 159 additions and 1 deletion.
40 changes: 40 additions & 0 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# Contribute To TMS Sara Hilden Theme

Community-made patches, localisations, bug reports and contributions are welcome and help make TMS Sara Hilden Theme even better!

When contributing please ensure you follow the guidelines below so that we can keep on top of things.

## Getting Started

- Submit a ticket for your issue, assuming one does not already exist.
- Raise it on our Issue Tracker.
- Clearly describe the issue including steps to reproduce the bug.
- Make sure you fill in the earliest version that you know has the issue as well as the version of WordPress you're using.

## Making Changes

- Fork the repository on GitHub.
- Make the changes to your forked repository.
- Add unit / integration tests where necessary.
- Ensure you stick to the [Geniem Oy WordPress Coding Standards][wpcs] and have properly documented any new functions.
- When committing, reference your issue (if present) and include a note about the fix.
- Push the changes to your fork and submit a pull request to the 'develop' branch of the ... repository.

### Checking Your Changes

- Run code standards: `composer lint-all`
- Automatically fix (most) lint errors: `composer lint-fix`

## Code Documentation

- Please make sure that every method is documented well, and the documentation follows the standards.

At this point you're waiting on us to merge your pull request. We'll review all pull requests, and make suggestions and changes if necessary.

# Additional Resources
- [General GitHub Documentation][gh-help]
- [GitHub Pull Request documentation][gh-pr]

[gh-pr]: http://help.github.com/send-pull-requests/
[gh-help]: https://help.github.com/
[wpcs]: https://github.com/devgeniem/geniem-rules-codesniffer
28 changes: 28 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
name: Bug report
about: Create a report to help us improve

---

## Describe the bug
<!-- A clear and concise description of what the bug is. -->

## To Reproduce
<!-- Steps to reproduce the behaviour:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error -->

## Expected behaviour
<!-- A clear and concise description of what you expected to happen. -->

## Screenshots
<!-- If applicable, add screenshots to help explain your problem. -->

## Environment

<!-- OS, browser, browser version, PHP version, WordPress version, active plugins, active theme, etc. -->

## Additional context
<!-- Add any other context about the problem here. -->
17 changes: 17 additions & 0 deletions .github/ISSUE_TEMPLATE/feature-request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
name: Feature request
about: Suggest an idea for this project

---

## Is your feature request related to a problem?
<!-- A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] -->

## Describe the solution you'd like
<!-- A clear and concise description of what you want to happen. -->

## Describe alternatives you've considered
<!-- A clear and concise description of any alternative solutions or features you've considered. -->

## Additional context
<!-- Add any other context or screenshots about the feature request here. -->
3 changes: 3 additions & 0 deletions .github/SUPPORT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Support for TMS Vapriikki Theme

The best place to get support for this project is on the Issue Tracker.
31 changes: 31 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# Please see the documentation for all configuration options:
# https://help.github.com/github/administering-a-repository/configuration-options-for-dependency-updates

version: 2
updates:
- package-ecosystem: "composer" # See documentation for possible values
directory: "/" # Location of package manifests
schedule:
interval: "daily"
# Prefix all commit messages with "Composer"
# include a list of updated dependencies
commit-message:
prefix: "Composer"
include: "scope"
# Specify labels for Composer pull requests
labels:
- "maintenance"
- "maintenance-composer"
- package-ecosystem: "npm"
directory: "/"
schedule:
interval: "daily"
# Prefix all commit messages with "NPM"
# include a list of updated dependencies
commit-message:
prefix: "NPM"
include: "scope"
# Specify labels for NPM pull requests
labels:
- "maintenance"
- "maintenance-npm"
4 changes: 3 additions & 1 deletion .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
Task: https://hiondigital.atlassian.net/browse/TMS-949
Severa-ID: 2108
Severa-kuvaus:
Task: https://hiondigital.atlassian.net/browse/TMS-

<!--- Provide a general summary of your changes in the Title above -->

Expand Down
37 changes: 37 additions & 0 deletions .github/workflows/phpcs-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: PHP CS Checks

on: [push]

jobs:
phpcs-check:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- name: Validate composer.json and composer.lock
run: composer validate

- name: Cache Composer packages
id: composer-cache
uses: actions/cache@v2
with:
path: vendor
key: ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }}
restore-keys: |
${{ runner.os }}-php-
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: 7.4
extensions: simplexml
coverage: xdebug
env:
COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Run PHPCS Check
run: |
composer install --prefer-dist --no-progress
composer require staabm/annotate-pull-request-from-checkstyle
./vendor/bin/phpcs -q --report=checkstyle | vendor/bin/cs2pr --graceful-warnings

0 comments on commit b147b3f

Please sign in to comment.