Make WordPress Core

Opened 2 years ago

Closed 2 years ago

Last modified 2 years ago

#56898 closed defect (bug) (fixed)

Create a GitHub Action workflow that prepares bundled themes for release

Reported by: desrosj's profile desrosj Owned by: desrosj's profile desrosj
Milestone: 6.1 Priority: normal
Severity: normal Version:
Component: Build/Test Tools Keywords: has-patch
Focuses: Cc:

Description

Releasing new versions of bundled themes is a very manual process. A contributor must:

  • verify that the readme.txt file has been updated properly
  • ensure versions are bumped properly in appropriate locations
  • create a new ZIP file for each theme
  • A Core SVN committer must upload each theme to the directory on release day.

Some of this can be automated to make this process easier.

Change History (14)

#2 @desrosj
2 years ago

I've created a workflow that:

  • Confirms no file modifications after running theme build scripts (where appropriate).
  • Allows any organization member to trigger the workflow to generate ZIP files.

This seems like a great starting point. In the future, there could be more release related checks and confirmations.

This ticket was mentioned in Slack in #core by audrasjb. View the logs.


2 years ago

This ticket was mentioned in Slack in #core by chaion07. View the logs.


2 years ago

@desrosj commented on PR #3521:


2 years ago
#5

I've made a few changes. Mainly, I separated the parts that test theme build scripts into a separate job. This eliminates the need for having different working-directorys, and for checking which theme is being tested. I'm going to get this committed and we can make improvements as needed.

#6 @desrosj
2 years ago

#56659 was marked as a duplicate.

#7 @desrosj
2 years ago

  • Owner set to desrosj
  • Resolution set to fixed
  • Status changed from new to closed

In 54699:

Build/Test Tools: Introduce a workflow for testing and building default themes.

This introduces a GitHub Action workflow that performs the following steps for default themes:

  • Test installing npm dependencies and running the build script (for relevant themes).
  • Create ZIP files for the .org Theme directory and uploads them as workflow artifacts.

The workflow will only run on limited occasions, one of those being when Twenty Nineteen, Twenty Twenty, or Twenty Twenty-One is edited. These are the themes with build scripts that need to be tested for issues.

It can also be manually run through the GitHub Actions UI for occasions when the ZIP files are needed for a release.

Props peterwilsoncc, desrosj
Fixes #56898.

#9 @desrosj
2 years ago

This does not need to be backported. The workflow can be manually triggered in the the GitHub Actions UI and accepts a branch, which will allow the themes to be bundled for the 6.1 branch.

This ticket was mentioned in Slack in #core by sergey. View the logs.


2 years ago

#11 @desrosj
2 years ago

  • Resolution fixed deleted
  • Status changed from closed to reopened

Looks like the theme folders are being nested in the ZIP. Reopening to adjust.

This ticket was mentioned in PR #3546 on WordPress/wordpress-develop by @desrosj.


2 years ago
#12

  • GitHub Action artifacts are always zipped. This update prevents zipping a ZIP file (double zipping).
  • Only the theme's directory should be included in the workflow. Not src/wp-content/theme/THEMENAME.

Trac ticket: https://core.trac.wordpress.org/ticket/56898

#13 @desrosj
2 years ago

  • Resolution set to fixed
  • Status changed from reopened to closed

In 54740:

Build/Test Tools: Don’t ZIP theme ZIP files.

When uploading artifacts during GitHub Action workflows, all files uploaded to an artifact name are zipped. When a ZIP file is uploaded, the result is a horrifying state of ZIP-ception.

This changes the workflow to upload all of the needed theme files to the artifact instead of a singular ZIP file created prior to uploading.

This also fixes a bug where ZIP files generated have the desired theme nested within src/wp-content/themes instead of just containing the theme files.

Props ndiego, wildworks, desrosj, bgardner, colorful-tones.
Fixes #56898.

Note: See TracTickets for help on using tickets.