https://github.com/jazzsequence/dtp-test
WordPress + Composer push-to-pantheon workflow that only tracks the wp-content directory
https://github.com/jazzsequence/dtp-test
Last synced: 9 months ago
JSON representation
WordPress + Composer push-to-pantheon workflow that only tracks the wp-content directory
- Host: GitHub
- URL: https://github.com/jazzsequence/dtp-test
- Owner: jazzsequence
- Created: 2025-04-09T14:46:08.000Z (12 months ago)
- Default Branch: main
- Last Pushed: 2025-05-19T18:02:31.000Z (10 months ago)
- Last Synced: 2025-06-12T16:11:14.045Z (10 months ago)
- Language: PHP
- Homepage: https://dev-cxr-dtp-test.pantheonsite.io/
- Size: 106 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Deploy to Pantheon test
[](https://github.com/jazzsequence/dtp-test/actions/workflows/test.yml)
[](https://dev-cxr-dtp-test.pantheonsite.io)
This is a WordPress repository configured to test deployments to Pantheon via GitHub actions. In this use case, Composer is being used to manage dependencies (plugins and themes) and Pantheon is used to manage WordPress core updates.
Because we don't want to change the WordPress filesystem, the WordPress core files are not part of this repository, only custom code that we maintain is. To manage this, the following is added to `.git/info/exclude` to ensure that we don't need to maintain the WordPress core code in the GitHub repository.
```
# Ignore WordPress core directories
wp-admin/
wp-includes/
# Ignore WordPress core files in the root directory
index.php
wp-*.php # Ignore all php files that begin with wp-* (e.g. wp-login.php).
xmlrpc.php
license.txt
readme.html
# Ignore the pantheon *upstream* yml file.
# pantheon.yml *should* be in version control.
pantheon.upstream.yml
# *Don't* ignore wp-config.php
!wp-config.php
```
This allows those files to be safely deleted locally, not managed in the GitHub repository, but left alone in the Pantheon repository.
In order to not overwrite the WordPress core filesystem, the [`push-to-pantheon`](https://github.com/jazzsequence/dtp-test/blob/main/.github/workflows/push-to-pantheon.yml) workflow is pulling down files from the Pantheon site repository and overlaying changes from this repository on top of them.