Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prepare for code-quality checks #6

Merged
merged 31 commits into from
Aug 13, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
786da42
Normalize composer.json
carstingaxion Jun 22, 2023
0ff729f
Clean up code for ft/code-quality checks
carstingaxion Jun 22, 2023
4e174a5
Clean up
carstingaxion Jun 23, 2023
6bc7ba8
Give a structural overview of composer deps
carstingaxion Jun 23, 2023
468f99e
Remove explicit 'repositories' because we are using packagist now
carstingaxion Jul 5, 2023
927ea62
Update install instructions
carstingaxion Jul 5, 2023
389c205
Remove already loaded bleedingEdge phpstan conf
carstingaxion Jul 5, 2023
a34d9ad
Upgrading figuren-theater/code-quality (dev-main 76d37ab => 0.4.5)
carstingaxion Jul 5, 2023
72726a1
Default files for equal org-wide standards
carstingaxion Jul 5, 2023
5c1b7f8
Fix CS errors and phpstan violations to resolve #7
carstingaxion Jul 8, 2023
dd1128d
Exclude rule via config, instead of inside in files
carstingaxion Jul 12, 2023
364f2fe
Remove explicit 'install.php' 'repositories' because we are using pac…
carstingaxion Jul 12, 2023
e9569b1
Fix: Remove wrong LICENSE link
carstingaxion Jul 13, 2023
e5c073d
Remove explicit 'ft-maintenance' 'repositories' because we are using …
carstingaxion Jul 16, 2023
9120d9b
Fix misused CS configuration to make sure phpcs can be run by gh actions
carstingaxion Jul 16, 2023
c85f324
Make sure to use the latest version of code-quality tools (esp. durin…
carstingaxion Jul 16, 2023
8cd916b
Remove explicit 'ft-them(es|ing)' 'repositories' because we are using…
carstingaxion Jul 19, 2023
d6f878d
Rename file for CS
carstingaxion Aug 11, 2023
b7dba21
Ignore the need for a dedicated folder for just the external .env lib…
carstingaxion Aug 11, 2023
0247730
Add .lock file to allow dependabot to work
carstingaxion Aug 11, 2023
376c472
Fix relative link
carstingaxion Aug 11, 2023
5623295
Fix (or ignore) phpstan issues
carstingaxion Aug 11, 2023
6a9a2b8
Ignore the need for a dedicated folder for more files
carstingaxion Aug 11, 2023
e5b8619
Add CHANGELOG.md file with an Unreleased-Heading
carstingaxion Aug 11, 2023
2f52a76
Enable dependabot for gh actions as well
carstingaxion Aug 11, 2023
fb94fe8
NEW project-management actions
carstingaxion Aug 11, 2023
b76e154
NEW code-quality actions
carstingaxion Aug 11, 2023
8b85196
Fix CS issues
carstingaxion Aug 13, 2023
602282d
IGNORE 2 deprecated initiation files from CS checks
carstingaxion Aug 13, 2023
2f1585c
Fix and ignore phpstan issues
carstingaxion Aug 13, 2023
012a23d
Fix CS issues
carstingaxion Aug 13, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,11 @@ updates:
- dependency-type: "direct"
open-pull-requests-limit: 10

- package-ecosystem: github-actions
directory: "/"
schedule:
interval: weekly
open-pull-requests-limit: 10

# maybe interesting later
# https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file#composer-repository
13 changes: 13 additions & 0 deletions .github/workflows/build-test-measure.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: Build, test & measure

on:
workflow_call:
pull_request:
push:
branches:
['main']

jobs:
call-workflow-build-test-measure:
uses: figuren-theater/code-quality/.github/workflows/build-test-measure.yml@main
secrets: inherit
12 changes: 12 additions & 0 deletions .github/workflows/prerelease-changelog.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
name: 'pre-Release Changelog Update'

on:
workflow_call:
release:
types: [prereleased]

jobs:
call-workflow-update-changelog:
uses: figuren-theater/.github/.github/workflows/prerelease-changelog-update.yml@main
secrets: inherit

12 changes: 12 additions & 0 deletions .github/workflows/release-drafter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
name: Draft or update the next release

on:
push:
# branches to consider in the event; optional, defaults to all
branches:
- main

jobs:
call-workflow-release-drafter:
uses: figuren-theater/.github/.github/workflows/release-drafter.yml@main
secrets: inherit
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
.DS_Store
phpcs.xml
phpunit.xml
Thumbs.db
wp-cli.local.yml
node_modules/
Expand Down
2 changes: 1 addition & 1 deletion .maintenance
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<?php $upgrading = time(); ?>
<?php $upgrading = time();
39 changes: 39 additions & 0 deletions .phpcs.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
<?xml version="1.0"?>
<ruleset name="ft-platform">
<description>Coding standards for ft-platform</description>

<file>.</file>

<exclude-pattern>content/mu-plugins/FT/*</exclude-pattern>
<exclude-pattern>content/mu-plugins/(.*)-ft-platform-(.*)\.php</exclude-pattern>

<!--
<exclude-pattern>*/bin/*</exclude-pattern>
<exclude-pattern>*/tests/*</exclude-pattern>
<exclude-pattern>*/vendor/*</exclude-pattern>
-->

<!-- Use figuren.theater Coding Standards -->
<rule ref="figurentheater" />

<!-- Allmost impossible to do wp-configs another way -->
<rule ref="PSR1.Files.SideEffects.FoundWithSymbols">
<exclude-pattern>wp-config\.php</exclude-pattern>
<exclude-pattern>wp-config\.(.*)\.php</exclude-pattern>
</rule>

<!-- Ignore the need for a dedicated folder -->
<rule ref="HM.Files.NamespaceDirectoryName.NoIncDirectory">
<exclude-pattern>lib/dotenv/class-dotenv\.php</exclude-pattern>
</rule>

<!--
<rule ref="WordPress.WP.I18n">
<properties>
<property name="text_domain" type="array">
<element value="figurentheater"/>
</property>
</properties>
</rule> -->

</ruleset>
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Changelog

All notable changes to this project will be documented in this file.

## [Unreleased](https://github.com/figuren-theater/ft-platform/compare/0.1.0...HEAD)



31 changes: 25 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,6 @@
1. Add this repository to your `composer.json`
```json
"repositories": [
{
"type": "git",
"url": "https://github.com/figuren-theater/ft-platform"
},
{
"type": "git",
"url": "https://github.com/figuren-theater/ft-platform-collection"
Expand All @@ -45,10 +41,33 @@
3. Save the `.env.example` with all needed DB credentials, API keys, etc. as `.env` into the *new docroot*.
4. Create a symlink from `/content/v` to `/vendor` on the production server.

## Structure
- [ft-platform](https://github.com/figuren-theater/ft-platform/)
- [ft-core](https://github.com/figuren-theater/ft-core/)
- [WordPress](https://www.wordpress.org/)
- [ft-platform-collection](https://github.com/figuren-theater/ft-platform-collection/)
- [ft-admin-ui](https://github.com/figuren-theater/ft-admin-ui)
- [ft-coresites](https://github.com/figuren-theater/ft-coresites)
- [ft-data](https://github.com/figuren-theater/ft-data)
- [ft-interactive](https://github.com/figuren-theater/ft-interactive)
- [ft-maintenance](https://github.com/figuren-theater/ft-maintenance)
- [ft-media](https://github.com/figuren-theater/ft-media)
- [ft-onboarding](https://github.com/figuren-theater/ft-onboarding)
- [ft-options](https://github.com/figuren-theater/ft-options)
- [ft-performance](https://github.com/figuren-theater/ft-performance)
- [ft-privacy](https://github.com/figuren-theater/ft-privacy)
- [ft-routes](https://github.com/figuren-theater/ft-routes)
- [ft-security](https://github.com/figuren-theater/ft-security)
- [ft-seo](https://github.com/figuren-theater/ft-seo)
- [ft-site-editing](https://github.com/figuren-theater/ft-site-editing)
- [ft-themes](https://github.com/figuren-theater/ft-themes)
- [ft-theming](https://github.com/figuren-theater/ft-theming)


## Built with & uses

- [dependabot](/.github/dependabot.yml)
- [Build, test & measure](https://github.com/figuren-theater/code-quality/blob/main/.github/workflows/build-test-measure.yml) - a custom, but *required* status check for code-quality on all *push*s and *pull_request*s
- [figuren-theater/code-quality](https://github.com/figuren-theater/code-quality/) - a *required* status check for healthier code and standardized quality on all code changes

## Versioning

Expand All @@ -64,7 +83,7 @@ who participated in this project.

## License

This project is licensed under the [GPL-3.0-or-later](LICENSE.md), see the [LICENSE](LICENSE) file for
This project is licensed under the **GPL-3.0-or-later**, see the [LICENSE](/LICENSE) file for
details

## Acknowledgments
Expand Down
130 changes: 63 additions & 67 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
{
"name": "figuren-theater/ft-platform",
"description": "figuren.theater platform",
"type": "project",
"homepage": "https://websites.fuer.figuren.theater",
"keywords": ["wordpress", "multisite"],
"license": "GPL-3.0-or-later",
"type": "project",
"keywords": [
"wordpress",
"multisite"
],
"authors": [
{
"name": "figuren.theater",
Expand All @@ -17,11 +19,22 @@
"role": "Developer"
}
],
"homepage": "https://websites.fuer.figuren.theater",
"support": {
"email": "info@figuren.theater",
"issues": "https://github.com/figuren-theater/ft-platform/issues",
"source": "https://github.com/figuren-theater/ft-platform"
},
"require": {
"php": ">=8.0.19",
"figuren-theater/ft-core": "^1"
},
"require-dev": {
"figuren-theater/code-quality": "*"
},
"provide": {
"georgestephanis/application-passwords": "*"
},
"repositories": [
{
"type": "git",
Expand Down Expand Up @@ -55,18 +68,10 @@
"type": "git",
"url": "https://github.com/figuren-theater/altis-core"
},
{
"type": "git",
"url": "https://github.com/figuren-theater/code-quality"
},
{
"type": "git",
"url": "https://github.com/figuren-theater/ft-admin-ui"
},
{
"type": "git",
"url": "https://github.com/figuren-theater/ft-core"
},
{
"type": "git",
"url": "https://github.com/figuren-theater/ft-core-block-domaincheck"
Expand All @@ -79,10 +84,6 @@
"type": "git",
"url": "https://github.com/figuren-theater/ft-interactive"
},
{
"type": "git",
"url": "https://github.com/figuren-theater/ft-maintenance"
},
{
"type": "git",
"url": "https://github.com/figuren-theater/ft-media"
Expand All @@ -99,10 +100,6 @@
"type": "git",
"url": "https://github.com/figuren-theater/ft-onboarding"
},
{
"type": "git",
"url": "https://github.com/figuren-theater/install.php"
},
{
"type": "git",
"url": "https://github.com/figuren-theater/ft-options"
Expand Down Expand Up @@ -139,10 +136,6 @@
"type": "git",
"url": "https://github.com/figuren-theater/ft-network-block-editor"
},
{
"type": "git",
"url": "https://github.com/figuren-theater/ft-themes"
},
{
"type": "git",
"url": "https://github.com/figuren-theater/twentytwentytwo-ft-core"
Expand All @@ -151,10 +144,6 @@
"type": "git",
"url": "https://github.com/figuren-theater/twentytwenty-ft-core"
},
{
"type": "git",
"url": "https://github.com/figuren-theater/ft-theming"
},
{
"type": "git",
"url": "https://github.com/figuren-theater/BLOGS"
Expand All @@ -181,27 +170,32 @@
},
{
"type": "composer",
"url" : "https://wpackagist.org"
"url": "https://wpackagist.org"
},
{
"type": "composer",
"url": "https://packagist.org"
}
],
"prefer-stable": true,
"minimum-stability": "dev",
"extra": {
"wordpress-install-dir": "wp",
"installer-paths": {
"content/plugins/{$name}": ["type:wordpress-plugin"],
"content/themes/twentytwentytwo-ft-core": ["figuren-theater/twentytwentytwo-ft-core"],
"content/themes/figuren-theater": ["figuren-theater/twentytwenty-ft-core"],
"content/parent-themes/{$name}": ["type:wordpress-theme"],
"content/mu-plugins/Figuren_Theater": ["figuren-theater/deprecated__Figuren_Theater__v2"],
"content/mu-plugins/FT/{$name}": ["vendor:figuren-theater"],
"content/mu-plugins/{$name}": ["type:wordpress-muplugin"],
"wp": ["type:wordpress-core"]
"prefer-stable": true,
"config": {
"allow-plugins": {
"dealerdirect/phpcodesniffer-composer-installer": true,
"johnpbloch/wordpress-core-installer": true,
"composer/installers": true,
"figuren-theater/*": true,
"altis/*": true,
"koodimonni/composer-dropin-installer": true,
"inpsyde/wp-translation-downloader": true,
"phpstan/extension-installer": true,
"ergebnis/composer-normalize": true
},
"optimize-autoloader": true,
"preferred-install": "dist",
"sort-packages": true
},
"extra": {
"dropin-paths": {
"content": [
"package:figuren-theater/ft-privacy:inc/koko-analytics/k.php",
Expand All @@ -217,40 +211,42 @@
"package:figuren-theater/ft-data:templates/htdocs/vendor/rss-bridge/rss-bridge/config.ini.php"
]
},
"installer-paths": {
"content/plugins/{$name}": [
"type:wordpress-plugin"
],
"content/themes/twentytwentytwo-ft-core": [
"figuren-theater/twentytwentytwo-ft-core"
],
"content/themes/figuren-theater": [
"figuren-theater/twentytwenty-ft-core"
],
"content/parent-themes/{$name}": [
"type:wordpress-theme"
],
"content/mu-plugins/Figuren_Theater": [
"figuren-theater/deprecated__Figuren_Theater__v2"
],
"content/mu-plugins/FT/{$name}": [
"vendor:figuren-theater"
],
"content/mu-plugins/{$name}": [
"type:wordpress-muplugin"
],
"wp": [
"type:wordpress-core"
]
},
"wordpress-install-dir": "wp",
"wp-translation-downloader": {
"languageRootDir": "content/languages",
"languages": [
"de_AT",
"de_CH",
"de_CH_informal",
"de_DE",
"de_DE_formal"
],
"languageRootDir": "content/languages"
}
},
"config": {
"optimize-autoloader": true,
"sort-packages": true,
"preferred-install": "dist",
"allow-plugins": {
"dealerdirect/phpcodesniffer-composer-installer": true,
"johnpbloch/wordpress-core-installer": true,
"composer/installers": true,
"figuren-theater/*": true,
"altis/*": true,
"koodimonni/composer-dropin-installer": true,
"inpsyde/wp-translation-downloader": true,
"phpstan/extension-installer": true
]
}
},
"require": {
"php": ">=8.0.19",
"figuren-theater/ft-core": "^1"
},
"provide": {
"georgestephanis/application-passwords": "*"
},
"require-dev": {
"figuren-theater/code-quality": "dev-main"
}
}
Loading