{"id":26278736,"url":"https://github.com/textpattern/textpattern-toolbelt","last_synced_at":"2025-10-14T02:13:40.694Z","repository":{"id":50219683,"uuid":"44581195","full_name":"textpattern/textpattern-toolbelt","owner":"textpattern","description":"A collection of tools which help to develop Textpattern CMS.","archived":false,"fork":false,"pushed_at":"2025-03-26T15:48:51.000Z","size":224,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":7,"default_branch":"main","last_synced_at":"2025-04-29T10:26:15.285Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://textpattern.com","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/textpattern.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2015-10-20T04:02:33.000Z","updated_at":"2025-03-26T15:48:54.000Z","dependencies_parsed_at":"2024-01-15T08:53:11.260Z","dependency_job_id":"c6453670-50e2-4b47-81cb-c00bcf8d59ce","html_url":"https://github.com/textpattern/textpattern-toolbelt","commit_stats":{"total_commits":191,"total_committers":7,"mean_commits":"27.285714285714285","dds":0.5602094240837696,"last_synced_commit":"0e79f2d24605344481aa2e6bb1d482bbd9b6713f"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/textpattern%2Ftextpattern-toolbelt","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/textpattern%2Ftextpattern-toolbelt/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/textpattern%2Ftextpattern-toolbelt/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/textpattern%2Ftextpattern-toolbelt/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/textpattern","download_url":"https://codeload.github.com/textpattern/textpattern-toolbelt/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252793559,"owners_count":21805053,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-03-14T13:17:42.833Z","updated_at":"2025-10-14T02:13:35.658Z","avatar_url":"https://github.com/textpattern.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Developer Toolbelt for Textpattern CMS\n\nA collection of tools which help make [Textpattern CMS](https://textpattern.com/) releases.\n\n## Contributing\n\nPlease see the [Contributing documentation](https://docs.textpattern.com/development/contributing) for details on how to get involved with the project.\n\n## Legal\n\nLicensed under the [GPLv2 license](https://github.com/textpattern/textpattern/blob/main/LICENSE.txt).\n\n## Textpattern release build process\n\nThis process prepares a development branch of Textpattern for beta, release candidate or production release. Follow the steps carefully to ensure a smooth onward journey.\n\n#### Notes\n\n* Semantic versioning is used, with `major.minor.patch` nomenclature.\n* Development code is suffixed `-dev`.\n* Development code can become a beta release, release candidate and / or production release.\n* Beta releases are suffixed `-beta`, `-beta.2`, `-beta.3` and so on.\n* Release candidates are suffixed `-rc1`, `-rc2`, `-rc3` and so on.\n* References to `x.y.z` below refer to the Textpattern version number and may be suffixed as mentioned.\n* *There's no need to push the `release-x.y.z` branch upstream* unless you wish someone else to take over your work. Keeping it local is fine.\n\n### Preflight requirements\n\n[WIP]\n\n* Local instance of PHP CLI, `gzip`, `shasum`, `tar`, `xz` and `zip`.\n  * Checks: `php -v`, `gzip -V`, `shasum -v`, `tar --version`, `xz --version` and `zip -v`.\n* Know the intended next release version for resetting the repo after launch.\n* Know the respective `textpattern.com` file IDs for the `.zip`, `.tar.gz` and `.tar.xz` archives.\n\nSome versions of macOS do not include PHP by default. PHP for macOS can be installed using [Homebrew](https://brew.sh) or [MacPorts](https://www.macports.org).\n\nSome versions of macOS do not include `xz` by default. `xz` for macOS can be obtained from https://github.com/donmccaughey/xz_pkg.\n\n### Step 0: Ensure everything is up-to-date\n\nOn [textpattern/textpattern](https://github.com/textpattern/textpattern/), update `HISTORY.txt` with final added / changed / fixed release notes, but *do not set the release date*. Merge to other branch(es) where appropriate, ensure all branches (i.e. `main`, `dev`, and any feature branches) are up-to-date where appropriate:\n\n```bash\ngit checkout branch-name\ngit pull\n```\n\n### Step 1: Create release branch based on feature branch\n\nNavigate to the branch from which to prepare a release, and create a `release-x.y.z` branch for the new version:\n\n```bash\ngit checkout dev\n```\n\n_or_:\n\n```bash\ngit checkout vx.y.z\n```\n\nthen:\n\n```bash\ngit checkout -b release-x.y.z\n```\n\n### Step 2: Set version numbers for all but `textpattern/lib/constants.php`\n\nUpdate version number(s) and remove any references to 'upcoming' in:\n\n* `README.txt`\n* `INSTALL.txt`\n* `UPGRADE.txt`\n* `package.json`\n* `README.md` (including the download file IDs - add 3 usually, but check for beta release(s)).\n* The `version` preference value in `textpattern/vendors/Textpattern/DB/Data/core.prefs`.\n* The `textpattern.version` value in `textpattern/textpattern.js`.\n* Theme manifests:\n  * `textpattern/setup/themes/[default-theme-name]/manifest.json`\n  * `textpattern/setup/themes/zero/manifest.json`\n* Admin theme manifests:\n  * `textpattern/admin-themes/[theme-name]/manifest.json`\n\nThese are usually done in advance of release by updating the admin-theme repos (typically @philwareham) and pulling the changes in (e.g. from the `x.y.z` branch, issue: `npm run get-hive-admin-theme`).\n\n### Step 3: Verify setup \u0026 update scripts match\n\nEnsure the contents of `textpattern/setup` directory is completely in sync with the `textpattern/update` scripts. Most of this is handled automatically but any per-user prefs or values injected from the setup process may need to be added manually.\n\nVerify that multi-site files such as `.htaccess`, `.htaccess-dist` and `css.php` are up-to-date with their root counterparts.\n\n### Step 4: Commit history and versions\n\nCommit all changes with a commit message of the format `HISTORY and version numbers for x.y.z`.\n\n### Step 5: Update version number\n\nEdit `textpattern/lib/constants.php` to update the version number.\n\n**Most importantly:**\n\nRelease type | Note\n------------ | ----\nStable | Set `$txp_is_dev` to `false`.\nBeta | Leave `$txp_is_dev` at `true`.\n\n### Step 6: Update checksums\n\nRun `checksums.php` from `textpattern-toolbelt` and point it at the `textpattern` directory inside your working branch (not the root):\n\n```php\nphp /path/to/textpattern-toolbelt/release/checksums.php /path/to/working-branch-repo/textpattern rebuild\n```\n\nCommit with message of the format `Checksums for x.y.z`.\n\n### Step 7: Test!\n\nCopy the entire bundle to a local directory and test. Things to look for:\n\n1. New installation / setup works.\n2. Upgrade from (populated) recent versions works.\n3. Multi-site installations work.\n4. Automated installations work.\n5. Version numbers are reported correctly throughout.\n6. The High Diagnostics panel reports everything correctly.\n7. Public tags provide expected output.\n8. Runs on as many versions of PHP, MySQL (and own-brand remixes), Apache, Nginx.\n9. Interface UI strings are all assigned English labels.\n10. Left over files that need deleting.\n\nFix anything that doesn't work, and commit atomic changes to the `release-x.y.z` branch. Run checksums again if required.\n\n### Step 8: Update history\n\nUpdate `HISTORY.txt` to tag the release with a date stamp and commit with message of the format `This is x.y.z`.\n\n### Step 9: Merge to the main repo and push it upstream\n\nMerge to `main`:\n\n```bash\ngit checkout main\ngit merge release-x.y.z\ngit push\n```\n\n### Step 10: Build the archives\n\nRun the archive build script. It will build three archive files (`textpattern-x.y.z.zip`, `textpattern-x.y.z.tar.gz` and  `textpattern-x.y.z.tar.xz`) with corresponding SHA256 checksum files in a temporary location and report where that is. Supply a second argument if you wish to override this destination.\n\n```bash\ncd /path/to/working-branch-repo\nbash /path/to/textpattern-toolbelt/release/txp-release.sh x.y.z\n```\n\n### Step 11: Verify archives\n\nOpen the temporary build location and verify archives have been built correctly. Decompress them to check.\n\nUpload the archives to https://virustotal.com for sanity check of files and generated checksums.\n\n### Step 12: Build release on GitHub\n\nPrepare a release for version `x.y.z` on GitHub:\n* Set the tag to just the vanilla version number `x.y.z` along with any required `-beta` or `-rc` suffix.\n* **Vital**: Ensure the target select box is `main`.\n* Use the same tag name for the release Title, but prefix it with a lower case `v`.\n* Attach archives and SHA256 checksums.\n* If it's a beta or release candidate, ensure the `Pre-release` checkbox is set.\n\nUse `git pull` to bring the new tag down to your local repo's `main` branch.\n\n### Step 13: Add archives to textpattern.com\n\nUpload archives to `textpattern.com` website. Ensure they comply with the semantic filename versioning rules.\n\nFor each uploaded file, select the appropriate file category:\n\n```\nCurrent release (Zip format)\nCurrent release (Gzip format)\nCurrent release (Xz format)\nCurrent beta release (Zip format)\nCurrent beta release (Gzip format)\nCurrent beta release (Xz format)\n```\n\nMake sure the `Title` and `Description` fields are filled out correctly (see previous files for examples of this). `Title` holds the release version number. `Description` houses the SHA256 token.\n\n### Step 14: Adjust archive category assignment\n\nRemove the category assignment from previous uploads of a beta / stable releases. Note you can have a stable release and a beta release at the same time, but it's good housekeeping to remove old categories from previous releases. Everything is built automatically based on these category assignments.\n\n### Step 15: Finalise the release blog article\n\nWhen writing the corresponding article, use the shortcode as follows:\n\n```html\nnotextile. \u003ctxp::media_file filename=\"textpattern-x.y.z.zip\" /\u003e\n\u003ctxp::media_file filename=\"textpattern-x.y.z.tar.gz\" /\u003e\n\u003ctxp::media_file filename=\"textpattern-x.y.z.tar.xz\" /\u003e\n```\n\n### Step 16: Update orientation information\n\nAdd a section to the 'Get started' article when a beta is available (remove it from here at the end of the beta cycle but leave it in its dedicated article for posterity).\n\nUpdate the release notes link in [Get started with Textpattern](https://textpattern.com/start) to point to the announcement blog post.\n\n### Step 17: Prepare for next version: set version numbers and commit\n\nPrepare for ongoing development:\n\n```bash\ngit checkout release-x.y.z\n```\n\nEdit the following files to bump version number to next intended release. Ensure they have `-dev` suffix. If this release is a beta or release candidate, it's okay to revert the version number to the same `x.y.z-dev` it was before.\n\n* `package.json`.\n* `textpattern/lib/constants.php` (also set `$txp_is_dev` to `true` if it was previously `false`).\n* The `version` preference value in `textpattern/vendors/Textpattern/DB/Data/core.prefs`.\n* The `textpattern.version` value in `textpattern/textpattern.js`.\n\nCommit to ensure the version change is applied, using a suitable commit message of the format 'Back to dev' or 'Towards x.y.z'.\n\n### Step 18: Merge `release-x.y.z` back into `dev`\n\nMerge release to `dev` so changes in the release are recorded:\n\n```bash\ngit checkout dev\ngit merge release-x.y.z\ngit push\n```\n\n### Step 19: Tidy up branches\n\nDelete release branch as it has served its purpose:\n\n```bash\ngit branch -d release-x.y.z\n```\n\nYou might have to use `-D` switch if the branch deletion complains it's 'unmerged'. That's because we just modified it ready for returning to `dev`. It depends if the release branch was pushed upstream or not. If so:\n\n```bash\ngit push origin --delete release-x.y.z\n```\n\nIf you've just released a feature branch (i.e. patch, not minor/major dev release) then there will be the old `vx.y.z` branch on your local and remote servers. Once you're absolutely sure that the merge back to dev from `release-x.y.z` has completed and pushed to the server successfully, you can remove your local and remote `vx.y.z` branches:\n\n```bash\ngit branch -d vx.y.z\ngit push origin --delete vx.y.z\n```\n\n### Step 20: Update `textpattern.com` web server configuration\n\n* note: only for production releases, ping @petecooper if you're stuck.\n\nThe `textpattern.com` configuration is [here](https://github.com/textpattern/server-config/blob/main/live/servers/files/triton.textpattern.net/opt/nginx/servers-available/www.textpattern.com.conf), search for `#start release vars`.\n\n* set `txpver_1b8835e8` variable to release version in semver format (e.g. `1.2.3`).\n* set `$targzid_1b8835e8` to the Textpattern file ID for the `.tar.gz` archive (e.g `457`).\n* set `$tarxzid_1b8835e8` to the Textpattern file ID for the `.tar.xz` archive (e.g `458`).\n* set `$zipid_1b8835e8` to the Textpattern file ID for the `.zip` archive (e.g `456`).\n* upload the file to overwrite the existing `/etc/nginx/servers-available/www.textpattern.com.conf` (or modify in place).\n* restart Nginx (i.e. `sudo systemctl restart nginx`).\n\nCheck downloads for the following:\n\n* https://textpattern.com/latest.tar.gz\n* https://textpattern.com/latest.tar.xz\n* https://textpattern.com/latest.zip\n* https://textpattern.com/pophelp-download\n* https://textpattern.com/textpack-download\n\n### Step 21: Tell everyone\n\nPost announcements and gratitude to blog / forum / Twitter / relevant social media. See `announcements.md` for more details.\n\n### Step 22: Update links to latest version in docs, etc\n\nSearch through all `textpattern.com` articles to update any outdated version numbers (in case articles were written in advance or features got moved between versions, or reference the download itself).\n\nUpdate version in `rpc.textpattern.com` (Extensions -\u003e TXP Version).\n\n### Step 23: Relax\n\nLight cigar, pour brandy and wait for the fallout. [Go to bed](https://web.archive.org/web/20040313194455/http%3A//www.textism.com/article/781/Textpattern) if appropriate.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftextpattern%2Ftextpattern-toolbelt","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftextpattern%2Ftextpattern-toolbelt","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftextpattern%2Ftextpattern-toolbelt/lists"}