Skip to content

Conversation

@MGatner
Copy link
Member

@MGatner MGatner commented Mar 7, 2020

Description
This PR is "phase 1" of automating releases, targeting the distribution repos.

  • A new GitHub Action is defined, triggered by release publication
  • Release scripts are retired in favor of a new deploy scripts in .github/scripts
  • Repo files are differentiated by intended project use (see also Unnecessary files in the download installation #2606)
  • Docs updated for the release workflow
  • A number of bugs fixed that either included wrong files or failed to remove legacy files

Checklist:

  • Securely signed commits
  • Component(s) with PHPdocs
  • Unit testing, with >80% coverage
  • User guide updated
  • Conforms to style guide

@MGatner
Copy link
Member Author

MGatner commented Mar 7, 2020

Due to the nature of the trigger, this change is not easily tested. I created forks of the three repos codeigniter4, framework, and appstarter and temporarily pointed the Action at those. You can review the successful test:

@MGatner MGatner requested a review from lonnieezell March 7, 2020 03:24
@MGatner MGatner mentioned this pull request Mar 7, 2020
# Prepare the target
cd $TARGET
git checkout master
rm -rf *
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This command scares me :) Can you explain it is doing. Seems like you checkout master branch then delete everything?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The way the old script worked it would copy in the chosen files (like we do below) pre-wiping any directories (this was the bugged part from the cprm typo). Where that fails is when there are files that are renamed or removed (notice we have license.txt and a duplicate legacy LICENSE because of this). Using the modified version above it checks out the target repo (AppStarter or framework) and rebuilds the repo from scratch (* ignores files with leading periods so it doesn’t affect the .git directory). Also, it’s just a new commit so we could always back up one and nothing is lost!

@lonnieezell
Copy link
Member

Other than the delete the entire server command making me nervous it all looks good. :)

@MGatner
Copy link
Member Author

MGatner commented Mar 13, 2020

Come on @lonnieezell, you know you want to.....

@lonnieezell
Copy link
Member

Oh, all right @MGatner :)

@lonnieezell lonnieezell merged commit 0f953bb into codeigniter4:develop Mar 16, 2020
@MGatner MGatner deleted the releases branch November 28, 2020 18:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

User Guide is not in HTML in the download file Unnecessary files in the download installation

2 participants