From d065eaf0fdf0c3f2716b069c0ed06e09f831a5f3 Mon Sep 17 00:00:00 2001 From: Jonathan Miller <1+jmiller@noreply.git.mokoconsulting.tech> Date: Thu, 11 Jun 2026 20:22:31 +0000 Subject: [PATCH 01/21] ci(pre-release): add chore/** branch trigger for pre-release builds --- .mokogitea/workflows/pre-release.yml | 495 ++++++++++++++------------- 1 file changed, 252 insertions(+), 243 deletions(-) diff --git a/.mokogitea/workflows/pre-release.yml b/.mokogitea/workflows/pre-release.yml index 9615a4e..24c47e0 100644 --- a/.mokogitea/workflows/pre-release.yml +++ b/.mokogitea/workflows/pre-release.yml @@ -1,243 +1,252 @@ -# Copyright (C) 2026 Moko Consulting -# -# SPDX-License-Identifier: GPL-3.0-or-later -# -# FILE INFORMATION -# DEFGROUP: Gitea.Workflow -# INGROUP: moko-platform.Release -# REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform -# PATH: /templates/workflows/universal/pre-release.yml.template -# VERSION: 05.01.00 -# BRIEF: Manual pre-release -- builds dev/alpha/beta/rc packages from any branch - -name: "Universal: Pre-Release" - -on: - pull_request: - types: [closed] - branches: - - dev - pull_request_target: - types: [synchronize, opened, reopened] - branches: - - main - workflow_dispatch: - inputs: - stability: - description: 'Pre-release channel' - required: true - type: choice - options: - - development - - alpha - - beta - - release-candidate - -permissions: - contents: write - -env: - GITEA_URL: ${{ vars.GITEA_URL || 'https://git.mokoconsulting.tech' }} - GITEA_ORG: ${{ vars.GITEA_ORG || github.repository_owner }} - GITEA_REPO: ${{ vars.GITEA_REPO || github.event.repository.name }} - -jobs: - build: - name: "Build Pre-Release (${{ inputs.stability || 'development' }})" - runs-on: release - if: >- - github.event_name == 'workflow_dispatch' || - (github.event_name == 'pull_request' && github.event.pull_request.merged == true && github.event.pull_request.base.ref == 'dev') || - (github.event_name == 'pull_request_target' && github.event.pull_request.base.ref == 'main') - - steps: - - name: Checkout - uses: actions/checkout@v4 - with: - fetch-depth: 0 - token: ${{ secrets.MOKOGITEA_TOKEN }} - ref: ${{ github.event_name == 'pull_request_target' && github.event.pull_request.head.sha || '' }} - - - name: Setup moko-platform tools - env: - MOKO_CLONE_TOKEN: ${{ secrets.MOKOGITEA_TOKEN }} - MOKO_CLONE_HOST: git.mokoconsulting.tech/MokoConsulting - run: | - # Use pre-installed /opt/moko-platform if available (updated by cron every 6h) - if [ -f /opt/moko-platform/cli/version_bump.php ] && [ -f /opt/moko-platform/cli/manifest_element.php ] && [ -f /opt/moko-platform/vendor/autoload.php ]; then - echo Using pre-installed /opt/moko-platform - echo MOKO_CLI=/opt/moko-platform/cli >> $GITHUB_ENV - else - echo Falling back to fresh clone - if ! command -v composer > /dev/null 2>&1; then - sudo apt-get update -qq && sudo apt-get install -y -qq php-cli php-mbstring php-xml php-zip php-curl composer > /dev/null 2>&1 - fi - rm -rf /tmp/moko-platform-api - CLONE_URL=https://x-access-token:${MOKO_CLONE_TOKEN}@${MOKO_CLONE_HOST}/moko-platform.git - git clone --depth 1 --branch main --quiet $CLONE_URL /tmp/moko-platform-api - cd /tmp/moko-platform-api && composer install --no-dev --no-interaction --quiet - echo MOKO_CLI=/tmp/moko-platform-api/cli >> $GITHUB_ENV - fi - - - name: Detect platform - id: platform - run: | - php ${MOKO_CLI}/manifest_read.php --path . --github-output - - - name: Resolve metadata and bump version - id: meta - run: | - # Auto-detect stability: RC for PRs targeting main, else use input or default to development - if [ "${{ github.event_name }}" = "pull_request_target" ] && [ "${{ github.event.pull_request.base.ref }}" = "main" ]; then - STABILITY="release-candidate" - else - STABILITY="${{ inputs.stability || 'development' }}" - fi - - case "$STABILITY" in - development) SUFFIX="-dev"; TAG="development" ;; - alpha) SUFFIX="-alpha"; TAG="alpha" ;; - beta) SUFFIX="-beta"; TAG="beta" ;; - release-candidate) SUFFIX="-rc"; TAG="release-candidate" ;; - esac - - # Bump version via CLI: patch for dev/alpha/beta, minor for RC - case "$STABILITY" in - release-candidate) BUMP="minor" ;; - *) BUMP="patch" ;; - esac - - php ${MOKO_CLI}/version_bump.php --path . $([ "$BUMP" = "minor" ] && echo "--minor") 2>/dev/null || true - - # Set stability suffix and verify consistency - VERSION=$(php ${MOKO_CLI}/version_read.php --path . 2>/dev/null || echo "00.00.01") - VERSION=$(echo "$VERSION" | sed 's/-\(dev\|alpha\|beta\|rc\)$//') - - php ${MOKO_CLI}/version_set_platform.php \ - --path . --version "$VERSION" --branch "${{ github.ref_name }}" --stability "$STABILITY" 2>/dev/null || true - php ${MOKO_CLI}/version_check.php --path . --fix 2>/dev/null || true - - # Ensure licensing tags (updateservers, dlid) if enabled in manifest.xml - php ${MOKO_CLI}/manifest_licensing.php --path . --fix 2>/dev/null || true - - # Append suffix for output - if [ -n "$SUFFIX" ]; then - VERSION="${VERSION}${SUFFIX}" - fi - - # Commit version bump - git config --local user.email "gitea-actions[bot]@mokoconsulting.tech" - git config --local user.name "gitea-actions[bot]" - git remote set-url origin "https://x-access-token:${{ secrets.MOKOGITEA_TOKEN }}@git.mokoconsulting.tech/${{ github.repository }}.git" - git add -A - git diff --cached --quiet || { - git commit -m "chore(version): pre-release bump to ${VERSION} [skip ci]" - git push origin HEAD 2>&1 - } - - # Auto-detect element via manifest_element.php - php ${MOKO_CLI}/manifest_element.php \ - --path . --version "$VERSION" --stability "$STABILITY" \ - --repo "${GITEA_REPO}" --github-output - - # Read back element outputs - EXT_ELEMENT=$(grep '^ext_element=' "$GITHUB_OUTPUT" | tail -1 | cut -d= -f2) - ZIP_NAME=$(grep '^zip_name=' "$GITHUB_OUTPUT" | tail -1 | cut -d= -f2) - [ -z "$EXT_ELEMENT" ] && EXT_ELEMENT=$(echo "${GITEA_REPO}" | tr '[:upper:]' '[:lower:]' | tr -d ' -') - [ -z "$ZIP_NAME" ] && ZIP_NAME="${EXT_ELEMENT}-${VERSION}.zip" - - echo "version=${VERSION}" >> "$GITHUB_OUTPUT" - echo "stability=${STABILITY}" >> "$GITHUB_OUTPUT" - echo "suffix=${SUFFIX}" >> "$GITHUB_OUTPUT" - echo "tag=${TAG}" >> "$GITHUB_OUTPUT" - echo "zip_name=${ZIP_NAME}" >> "$GITHUB_OUTPUT" - echo "ext_element=${EXT_ELEMENT}" >> "$GITHUB_OUTPUT" - - echo "=== Pre-Release: ${EXT_ELEMENT} ${VERSION}${SUFFIX} ===" - - - name: Create release - id: release - run: | - TAG="${{ steps.meta.outputs.tag }}" - VERSION="${{ steps.meta.outputs.version }}" - API_BASE="${GITEA_URL}/api/v1/repos/${GITEA_ORG}/${GITEA_REPO}" - php ${MOKO_CLI}/release_create.php \ - --path . --version "$VERSION" --tag "$TAG" \ - --token "${{ secrets.MOKOGITEA_TOKEN }}" --api-base "$API_BASE" \ - --repo "${GITEA_REPO}" --branch dev --prerelease - - - name: Update release notes from CHANGELOG.md - run: | - TAG="${{ steps.meta.outputs.tag }}" - VERSION="${{ steps.meta.outputs.version }}" - API_BASE="${GITEA_URL}/api/v1/repos/${GITEA_ORG}/${GITEA_REPO}" - - # Extract [Unreleased] section from changelog (everything between [Unreleased] and next ## heading) - if [ -f "CHANGELOG.md" ]; then - NOTES=$(awk '/^## \[Unreleased\]/{found=1; next} /^## \[/{if(found) exit} found{print}' CHANGELOG.md) - [ -z "$NOTES" ] && NOTES="Release ${VERSION}" - else - NOTES="Release ${VERSION}" - fi - - # Update release body via API - RELEASE_ID=$(curl -sf -H "Authorization: token ${{ secrets.MOKOGITEA_TOKEN }}" \ - "${API_BASE}/releases/tags/${TAG}" | python3 -c "import json,sys; print(json.load(sys.stdin).get('id',''))" 2>/dev/null || true) - - if [ -n "$RELEASE_ID" ]; then - python3 -c " - import json, urllib.request - body = open('/dev/stdin').read() - payload = json.dumps({'body': body}).encode() - req = urllib.request.Request( - '${API_BASE}/releases/${RELEASE_ID}', - data=payload, method='PATCH', - headers={ - 'Authorization': 'token ${{ secrets.MOKOGITEA_TOKEN }}', - 'Content-Type': 'application/json' - }) - urllib.request.urlopen(req) - " <<< "$NOTES" - echo "Release notes updated from CHANGELOG.md" - fi - - - name: Build package and upload - id: package - run: | - VERSION="${{ steps.meta.outputs.version }}" - TAG="${{ steps.meta.outputs.tag }}" - API_BASE="${GITEA_URL}/api/v1/repos/${GITEA_ORG}/${GITEA_REPO}" - php ${MOKO_CLI}/release_package.php \ - --path . --version "$VERSION" --tag "$TAG" \ - --token "${{ secrets.MOKOGITEA_TOKEN }}" --api-base "$API_BASE" \ - --repo "${GITEA_REPO}" --output /tmp || true - - # updates.xml is generated dynamically by MokoGitea license server - # No need to build, commit, or sync updates.xml from workflows - - - name: "Delete lesser pre-release channels (cascade)" - continue-on-error: true - run: | - API_BASE="${GITEA_URL}/api/v1/repos/${GITEA_ORG}/${GITEA_REPO}" - TOKEN="${{ secrets.MOKOGITEA_TOKEN }}" - - php ${MOKO_CLI}/release_cascade.php \ - --stability "${{ steps.meta.outputs.stability }}" \ - --token "${TOKEN}" \ - --api-base "${API_BASE}" - - - name: Summary - if: always() - run: | - VERSION="${{ steps.meta.outputs.version }}" - STABILITY="${{ steps.meta.outputs.stability }}" - ZIP_NAME="${{ steps.meta.outputs.zip_name }}" - SHA256="${{ steps.package.outputs.sha256_zip }}" - echo "## Pre-Release Complete" >> $GITHUB_STEP_SUMMARY - echo "" >> $GITHUB_STEP_SUMMARY - echo "| Field | Value |" >> $GITHUB_STEP_SUMMARY - echo "|-------|-------|" >> $GITHUB_STEP_SUMMARY - echo "| Version | \`${VERSION}\` |" >> $GITHUB_STEP_SUMMARY - echo "| Channel | ${STABILITY} |" >> $GITHUB_STEP_SUMMARY - echo "| Package | \`${ZIP_NAME}\` |" >> $GITHUB_STEP_SUMMARY - echo "| SHA-256 | \`${SHA256:-n/a}\` |" >> $GITHUB_STEP_SUMMARY +# Copyright (C) 2026 Moko Consulting +# +# SPDX-License-Identifier: GPL-3.0-or-later +# +# FILE INFORMATION +# DEFGROUP: Gitea.Workflow +# INGROUP: moko-platform.Release +# REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform +# PATH: /templates/workflows/universal/pre-release.yml.template +# VERSION: 05.01.00 +# BRIEF: Auto pre-release on push to dev/alpha/beta/rc branches + +name: "Universal: Pre-Release" + +on: + push: + branches: + - dev + - 'fix/**' + - 'patch/**' + - 'hotfix/**' + - 'bugfix/**' + - 'chore/**' + - alpha + - beta + - rc + workflow_dispatch: + inputs: + stability: + description: 'Pre-release channel' + required: true + type: choice + options: + - development + - alpha + - beta + - release-candidate + +permissions: + contents: write + +env: + GITEA_URL: ${{ vars.GITEA_URL || 'https://git.mokoconsulting.tech' }} + GITEA_ORG: ${{ vars.GITEA_ORG || github.repository_owner }} + GITEA_REPO: ${{ vars.GITEA_REPO || github.event.repository.name }} + +jobs: + build: + name: "Build Pre-Release (${{ inputs.stability || github.ref_name }})" + runs-on: release + if: >- + github.event_name == 'workflow_dispatch' || + github.event_name == 'push' + + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + fetch-depth: 0 + token: ${{ secrets.MOKOGITEA_TOKEN }} + ref: ${{ github.ref_name }} + + - name: Setup moko-platform tools + env: + MOKO_CLONE_TOKEN: ${{ secrets.MOKOGITEA_TOKEN }} + MOKO_CLONE_HOST: git.mokoconsulting.tech/MokoConsulting + run: | + # Use pre-installed /opt/moko-platform if available (updated by cron every 6h) + if [ -f /opt/moko-platform/cli/version_bump.php ] && [ -f /opt/moko-platform/cli/manifest_element.php ] && [ -f /opt/moko-platform/vendor/autoload.php ]; then + echo Using pre-installed /opt/moko-platform + echo MOKO_CLI=/opt/moko-platform/cli >> $GITHUB_ENV + else + echo Falling back to fresh clone + if ! command -v composer > /dev/null 2>&1; then + sudo apt-get update -qq && sudo apt-get install -y -qq php-cli php-mbstring php-xml php-zip php-curl composer > /dev/null 2>&1 + fi + rm -rf /tmp/moko-platform-api + CLONE_URL=https://x-access-token:${MOKO_CLONE_TOKEN}@${MOKO_CLONE_HOST}/moko-platform.git + git clone --depth 1 --branch main --quiet $CLONE_URL /tmp/moko-platform-api + cd /tmp/moko-platform-api && composer install --no-dev --no-interaction --quiet + echo MOKO_CLI=/tmp/moko-platform-api/cli >> $GITHUB_ENV + fi + + - name: Detect platform + id: platform + run: | + # Auto-detect and update platform if not set in manifest + php ${MOKO_CLI}/platform_detect.php --path . --github-output 2>/dev/null || true + php ${MOKO_CLI}/manifest_read.php --path . --github-output + + - name: Resolve metadata and bump version + id: meta + run: | + # Auto-detect stability from branch name on push, or use input on dispatch + if [ "${{ github.event_name }}" = "push" ]; then + case "${{ github.ref_name }}" in + rc) STABILITY="release-candidate" ;; + alpha) STABILITY="alpha" ;; + beta) STABILITY="beta" ;; + *) STABILITY="development" ;; + esac + else + STABILITY="${{ inputs.stability || 'development' }}" + fi + + case "$STABILITY" in + development) SUFFIX="-dev"; TAG="development" ;; + alpha) SUFFIX="-alpha"; TAG="alpha" ;; + beta) SUFFIX="-beta"; TAG="beta" ;; + release-candidate) SUFFIX="-rc"; TAG="release-candidate" ;; + esac + + # Bump version via CLI: patch for dev/alpha/beta, minor for RC + case "$STABILITY" in + release-candidate) BUMP="minor" ;; + *) BUMP="patch" ;; + esac + + php ${MOKO_CLI}/version_bump.php --path . $([ "$BUMP" = "minor" ] && echo "--minor") 2>/dev/null || true + + # Set stability suffix and verify consistency + VERSION=$(php ${MOKO_CLI}/version_read.php --path . 2>/dev/null || echo "00.00.01") + VERSION=$(echo "$VERSION" | sed 's/-\(dev\|alpha\|beta\|rc\)$//') + + php ${MOKO_CLI}/version_set_platform.php \ + --path . --version "$VERSION" --branch "${{ github.ref_name }}" --stability "$STABILITY" 2>/dev/null || true + php ${MOKO_CLI}/version_check.php --path . --fix 2>/dev/null || true + + # Ensure licensing tags (updateservers, dlid) if enabled in manifest.xml + php ${MOKO_CLI}/manifest_licensing.php --path . --fix 2>/dev/null || true + + # Append suffix for output + if [ -n "$SUFFIX" ]; then + VERSION="${VERSION}${SUFFIX}" + fi + + # Commit version bump + git config --local user.email "gitea-actions[bot]@mokoconsulting.tech" + git config --local user.name "gitea-actions[bot]" + git remote set-url origin "https://x-access-token:${{ secrets.MOKOGITEA_TOKEN }}@git.mokoconsulting.tech/${{ github.repository }}.git" + git add -A + git diff --cached --quiet || { + git commit -m "chore(version): pre-release bump to ${VERSION} [skip ci]" + git push origin HEAD 2>&1 + } + + # Auto-detect element via manifest_element.php + php ${MOKO_CLI}/manifest_element.php \ + --path . --version "$VERSION" --stability "$STABILITY" \ + --repo "${GITEA_REPO}" --github-output + + # Read back element outputs + EXT_ELEMENT=$(grep '^ext_element=' "$GITHUB_OUTPUT" | tail -1 | cut -d= -f2) + ZIP_NAME=$(grep '^zip_name=' "$GITHUB_OUTPUT" | tail -1 | cut -d= -f2) + [ -z "$EXT_ELEMENT" ] && EXT_ELEMENT=$(echo "${GITEA_REPO}" | tr '[:upper:]' '[:lower:]' | tr -d ' -') + [ -z "$ZIP_NAME" ] && ZIP_NAME="${EXT_ELEMENT}-${VERSION}.zip" + + echo "version=${VERSION}" >> "$GITHUB_OUTPUT" + echo "stability=${STABILITY}" >> "$GITHUB_OUTPUT" + echo "suffix=${SUFFIX}" >> "$GITHUB_OUTPUT" + echo "tag=${TAG}" >> "$GITHUB_OUTPUT" + echo "zip_name=${ZIP_NAME}" >> "$GITHUB_OUTPUT" + echo "ext_element=${EXT_ELEMENT}" >> "$GITHUB_OUTPUT" + + echo "=== Pre-Release: ${EXT_ELEMENT} ${VERSION}${SUFFIX} ===" + + - name: Create release + id: release + run: | + TAG="${{ steps.meta.outputs.tag }}" + VERSION="${{ steps.meta.outputs.version }}" + API_BASE="${GITEA_URL}/api/v1/repos/${GITEA_ORG}/${GITEA_REPO}" + php ${MOKO_CLI}/release_create.php \ + --path . --version "$VERSION" --tag "$TAG" \ + --token "${{ secrets.MOKOGITEA_TOKEN }}" --api-base "$API_BASE" \ + --repo "${GITEA_REPO}" --branch "${{ github.ref_name }}" --prerelease + + - name: Update release notes from CHANGELOG.md + run: | + TAG="${{ steps.meta.outputs.tag }}" + VERSION="${{ steps.meta.outputs.version }}" + API_BASE="${GITEA_URL}/api/v1/repos/${GITEA_ORG}/${GITEA_REPO}" + + # Extract [Unreleased] section from changelog (everything between [Unreleased] and next ## heading) + if [ -f "CHANGELOG.md" ]; then + NOTES=$(awk '/^## \[Unreleased\]/{found=1; next} /^## \[/{if(found) exit} found{print}' CHANGELOG.md) + [ -z "$NOTES" ] && NOTES="Release ${VERSION}" + else + NOTES="Release ${VERSION}" + fi + + # Update release body via API + RELEASE_ID=$(curl -sf -H "Authorization: token ${{ secrets.MOKOGITEA_TOKEN }}" \ + "${API_BASE}/releases/tags/${TAG}" | python3 -c "import json,sys; print(json.load(sys.stdin).get('id',''))" 2>/dev/null || true) + + if [ -n "$RELEASE_ID" ]; then + python3 -c " + import json, urllib.request + body = open('/dev/stdin').read() + payload = json.dumps({'body': body}).encode() + req = urllib.request.Request( + '${API_BASE}/releases/${RELEASE_ID}', + data=payload, method='PATCH', + headers={ + 'Authorization': 'token ${{ secrets.MOKOGITEA_TOKEN }}', + 'Content-Type': 'application/json' + }) + urllib.request.urlopen(req) + " <<< "$NOTES" + echo "Release notes updated from CHANGELOG.md" + fi + + - name: Build package and upload + id: package + run: | + VERSION="${{ steps.meta.outputs.version }}" + TAG="${{ steps.meta.outputs.tag }}" + API_BASE="${GITEA_URL}/api/v1/repos/${GITEA_ORG}/${GITEA_REPO}" + php ${MOKO_CLI}/release_package.php \ + --path . --version "$VERSION" --tag "$TAG" \ + --token "${{ secrets.MOKOGITEA_TOKEN }}" --api-base "$API_BASE" \ + --repo "${GITEA_REPO}" --output /tmp || true + + # updates.xml is generated dynamically by MokoGitea license server + # No need to build, commit, or sync updates.xml from workflows + + - name: "Delete lesser pre-release channels (cascade)" + continue-on-error: true + run: | + API_BASE="${GITEA_URL}/api/v1/repos/${GITEA_ORG}/${GITEA_REPO}" + TOKEN="${{ secrets.MOKOGITEA_TOKEN }}" + + php ${MOKO_CLI}/release_cascade.php \ + --stability "${{ steps.meta.outputs.stability }}" \ + --token "${TOKEN}" \ + --api-base "${API_BASE}" + + - name: Summary + if: always() + run: | + VERSION="${{ steps.meta.outputs.version }}" + STABILITY="${{ steps.meta.outputs.stability }}" + ZIP_NAME="${{ steps.meta.outputs.zip_name }}" + SHA256="${{ steps.package.outputs.sha256_zip }}" + echo "## Pre-Release Complete" >> $GITHUB_STEP_SUMMARY + echo "" >> $GITHUB_STEP_SUMMARY + echo "| Field | Value |" >> $GITHUB_STEP_SUMMARY + echo "|-------|-------|" >> $GITHUB_STEP_SUMMARY + echo "| Version | \`${VERSION}\` |" >> $GITHUB_STEP_SUMMARY + echo "| Channel | ${STABILITY} |" >> $GITHUB_STEP_SUMMARY + echo "| Package | \`${ZIP_NAME}\` |" >> $GITHUB_STEP_SUMMARY + echo "| SHA-256 | \`${SHA256:-n/a}\` |" >> $GITHUB_STEP_SUMMARY -- 2.52.0 From ea760bb75b73c348c96feb60fa1f821b16cfe44c Mon Sep 17 00:00:00 2001 From: "gitea-actions[bot]" Date: Thu, 11 Jun 2026 20:23:12 +0000 Subject: [PATCH 02/21] chore(version): pre-release bump to 09.25.03-dev [skip ci] --- .mokogitea/workflows/issue-branch.yml | 2 +- README.md | 2 +- cli/branch_rename.php | 2 +- cli/bulk_workflow_push.php | 2 +- cli/bulk_workflow_trigger.php | 2 +- cli/client_dashboard.php | 2 +- cli/client_inventory.php | 2 +- cli/client_provision.php | 2 +- cli/grafana_dashboard.php | 2 +- cli/joomla_build.php | 2 +- cli/manifest_licensing.php | 2 +- cli/manifest_read.php | 2 +- cli/platform_detect.php | 2 +- cli/release_cascade.php | 2 +- cli/release_publish.php | 2 +- cli/scaffold_client.php | 2 +- cli/updates_xml_sync.php | 2 +- cli/version_auto_bump.php | 2 +- cli/version_check.php | 2 +- cli/wiki_sync.php | 2 +- cli/workflow_sync.php | 2 +- deploy/backup-before-deploy.php | 2 +- deploy/deploy-dolibarr.php | 2 +- deploy/health-check.php | 2 +- deploy/rollback-joomla.php | 2 +- deploy/sync-joomla.php | 2 +- tests/Unit/VersionBumpTest.php | 2 +- tests/Unit/VersionReadTest.php | 4 ++-- validate/check_file_integrity.php | 2 +- 29 files changed, 30 insertions(+), 30 deletions(-) diff --git a/.mokogitea/workflows/issue-branch.yml b/.mokogitea/workflows/issue-branch.yml index e849522..be48abe 100644 --- a/.mokogitea/workflows/issue-branch.yml +++ b/.mokogitea/workflows/issue-branch.yml @@ -5,7 +5,7 @@ # FILE INFORMATION # DEFGROUP: Gitea.Workflow # INGROUP: moko-platform.Automation -# VERSION: 09.25.02 +# VERSION: 09.25.03 # BRIEF: Auto-create feature branch when an issue is opened name: "Universal: Issue Branch" diff --git a/README.md b/README.md index c6bf850..a4b1b82 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ DEFGROUP: MokoPlatform.Root INGROUP: MokoPlatform REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform PATH: /README.md -VERSION: 09.25.02 +VERSION: 09.25.03 BRIEF: Project overview and documentation --> diff --git a/cli/branch_rename.php b/cli/branch_rename.php index 61b7967..fdc7c40 100644 --- a/cli/branch_rename.php +++ b/cli/branch_rename.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/branch_rename.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Rename a git branch via Gitea API (create new, update PR, delete old) */ diff --git a/cli/bulk_workflow_push.php b/cli/bulk_workflow_push.php index cc56f77..06e7281 100644 --- a/cli/bulk_workflow_push.php +++ b/cli/bulk_workflow_push.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/bulk_workflow_push.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Push a workflow file to all governed repos via the Gitea Contents API */ diff --git a/cli/bulk_workflow_trigger.php b/cli/bulk_workflow_trigger.php index 3f4df33..426a264 100644 --- a/cli/bulk_workflow_trigger.php +++ b/cli/bulk_workflow_trigger.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/bulk_workflow_trigger.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Trigger a workflow across multiple repos at once */ diff --git a/cli/client_dashboard.php b/cli/client_dashboard.php index 3fb51e5..73d62ad 100644 --- a/cli/client_dashboard.php +++ b/cli/client_dashboard.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/client_dashboard.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Generate unified client dashboard HTML */ diff --git a/cli/client_inventory.php b/cli/client_inventory.php index b40f30c..34679c0 100644 --- a/cli/client_inventory.php +++ b/cli/client_inventory.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/client_inventory.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Discover and list all client-waas repos with their server configuration status */ diff --git a/cli/client_provision.php b/cli/client_provision.php index fdfa4d1..44c66df 100644 --- a/cli/client_provision.php +++ b/cli/client_provision.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/client_provision.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Provision a new client environment end-to-end */ diff --git a/cli/grafana_dashboard.php b/cli/grafana_dashboard.php index 596f776..e15ad34 100644 --- a/cli/grafana_dashboard.php +++ b/cli/grafana_dashboard.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/grafana_dashboard.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Manage Grafana dashboards via API */ diff --git a/cli/joomla_build.php b/cli/joomla_build.php index 66f4a5b..e758d3b 100644 --- a/cli/joomla_build.php +++ b/cli/joomla_build.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/joomla_build.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Build a Joomla extension ZIP from manifest — all types supported * NOTE: Called by pre-release and auto-release workflows. */ diff --git a/cli/manifest_licensing.php b/cli/manifest_licensing.php index 5c8096b..565a7e1 100644 --- a/cli/manifest_licensing.php +++ b/cli/manifest_licensing.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/manifest_licensing.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Ensure licensing tags (updateservers, dlid) in Joomla extension manifests */ diff --git a/cli/manifest_read.php b/cli/manifest_read.php index 3572920..441366f 100644 --- a/cli/manifest_read.php +++ b/cli/manifest_read.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/manifest_read.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Parse .manifest.xml and output requested field(s) for CI consumption */ diff --git a/cli/platform_detect.php b/cli/platform_detect.php index b07c6cb..7892ed4 100644 --- a/cli/platform_detect.php +++ b/cli/platform_detect.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/platform_detect.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Auto-detect repository platform type and optionally update manifest */ diff --git a/cli/release_cascade.php b/cli/release_cascade.php index 432947e..2b64134 100644 --- a/cli/release_cascade.php +++ b/cli/release_cascade.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/release_cascade.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: DEPRECATED — cascade behavior removed. Each release stream is independent. */ diff --git a/cli/release_publish.php b/cli/release_publish.php index 7b12819..9e4b368 100644 --- a/cli/release_publish.php +++ b/cli/release_publish.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/release_publish.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Publish a release and create copies for all lesser stability streams. */ diff --git a/cli/scaffold_client.php b/cli/scaffold_client.php index 0bd2998..efc2466 100644 --- a/cli/scaffold_client.php +++ b/cli/scaffold_client.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/scaffold_client.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Scaffold a new client-waas repo from Template-Client-WaaS with pre-configured settings */ diff --git a/cli/updates_xml_sync.php b/cli/updates_xml_sync.php index 193d9d4..db20af5 100644 --- a/cli/updates_xml_sync.php +++ b/cli/updates_xml_sync.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/updates_xml_sync.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Sync updates.xml to target branches via Gitea API * NOTE: Called by pre-release and auto-release workflows after updates.xml * is modified on the current branch. Pushes the file to other branches diff --git a/cli/version_auto_bump.php b/cli/version_auto_bump.php index 9333d53..4282140 100644 --- a/cli/version_auto_bump.php +++ b/cli/version_auto_bump.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/version_auto_bump.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Auto patch-bump, set stability suffix, and commit — single CLI replacing inline workflow bash */ diff --git a/cli/version_check.php b/cli/version_check.php index 35db0da..ec2af82 100644 --- a/cli/version_check.php +++ b/cli/version_check.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/version_check.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Validate version consistency across README, manifests, and sub-packages */ diff --git a/cli/wiki_sync.php b/cli/wiki_sync.php index 4d156e0..4c68879 100644 --- a/cli/wiki_sync.php +++ b/cli/wiki_sync.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/wiki_sync.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Sync select wiki pages from moko-platform to all template repos */ diff --git a/cli/workflow_sync.php b/cli/workflow_sync.php index c02ddb4..f22b352 100644 --- a/cli/workflow_sync.php +++ b/cli/workflow_sync.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/workflow_sync.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Sync workflows from Generic → platform templates → live repos based on manifest.platform */ diff --git a/deploy/backup-before-deploy.php b/deploy/backup-before-deploy.php index 4c8fb07..db7c54f 100644 --- a/deploy/backup-before-deploy.php +++ b/deploy/backup-before-deploy.php @@ -12,7 +12,7 @@ * INGROUP: MokoPlatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /deploy/backup-before-deploy.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Snapshot Joomla directories before deployment for rollback capability */ diff --git a/deploy/deploy-dolibarr.php b/deploy/deploy-dolibarr.php index 9e0f256..d10d782 100644 --- a/deploy/deploy-dolibarr.php +++ b/deploy/deploy-dolibarr.php @@ -12,7 +12,7 @@ * INGROUP: MokoPlatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /deploy/deploy-dolibarr.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Deploy Dolibarr module files to a remote server via SFTP/rsync */ diff --git a/deploy/health-check.php b/deploy/health-check.php index 0fd771d..b7fbcc3 100644 --- a/deploy/health-check.php +++ b/deploy/health-check.php @@ -12,7 +12,7 @@ * INGROUP: MokoPlatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /deploy/health-check.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Post-deploy health check — verify a Joomla site is responding correctly */ diff --git a/deploy/rollback-joomla.php b/deploy/rollback-joomla.php index 6250b70..5650bfa 100644 --- a/deploy/rollback-joomla.php +++ b/deploy/rollback-joomla.php @@ -12,7 +12,7 @@ * INGROUP: MokoPlatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /deploy/rollback-joomla.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Rollback a Joomla deployment by restoring from a pre-deploy snapshot */ diff --git a/deploy/sync-joomla.php b/deploy/sync-joomla.php index 804acd7..fb4d970 100644 --- a/deploy/sync-joomla.php +++ b/deploy/sync-joomla.php @@ -12,7 +12,7 @@ * INGROUP: MokoPlatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /deploy/sync-joomla.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Sync Joomla site directories between two servers via rsync over SSH */ diff --git a/tests/Unit/VersionBumpTest.php b/tests/Unit/VersionBumpTest.php index 40e55e2..e129061 100644 --- a/tests/Unit/VersionBumpTest.php +++ b/tests/Unit/VersionBumpTest.php @@ -63,7 +63,7 @@ class VersionBumpTest extends TestCase { file_put_contents( "{$this->tmpDir}/README.md", - "\nSome content\n" + "\nSome content\n" ); $this->execute(); diff --git a/tests/Unit/VersionReadTest.php b/tests/Unit/VersionReadTest.php index f0d7d22..bbba14a 100644 --- a/tests/Unit/VersionReadTest.php +++ b/tests/Unit/VersionReadTest.php @@ -34,7 +34,7 @@ class VersionReadTest extends TestCase { file_put_contents( "{$this->tmpDir}/README.md", - "# Test\n\n" + "# Test\n\n" ); $this->assertSame('02.03.04', trim($this->runScript())); @@ -68,7 +68,7 @@ class VersionReadTest extends TestCase { file_put_contents( "{$this->tmpDir}/README.md", - "\n" + "\n" ); mkdir("{$this->tmpDir}/src", 0755, true); file_put_contents( diff --git a/validate/check_file_integrity.php b/validate/check_file_integrity.php index bf37403..3fe5c5d 100644 --- a/validate/check_file_integrity.php +++ b/validate/check_file_integrity.php @@ -12,7 +12,7 @@ * INGROUP: MokoPlatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /validate/check_file_integrity.php - * VERSION: 09.25.02 + * VERSION: 09.25.03 * BRIEF: Compare deployed files on a remote server against the local repository to detect drift */ -- 2.52.0 From 2dc43de160fd80f5e89b720f6f609ef9f753b1db Mon Sep 17 00:00:00 2001 From: Jonathan Miller <1+jmiller@noreply.git.mokoconsulting.tech> Date: Thu, 18 Jun 2026 13:22:15 +0000 Subject: [PATCH 03/21] revert: re-enable auto-bump on dev push [skip ci] --- .mokogitea/workflows/auto-bump.yml | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/.mokogitea/workflows/auto-bump.yml b/.mokogitea/workflows/auto-bump.yml index 9de5276..dd6e867 100644 --- a/.mokogitea/workflows/auto-bump.yml +++ b/.mokogitea/workflows/auto-bump.yml @@ -4,8 +4,8 @@ # # FILE INFORMATION # DEFGROUP: Gitea.Workflow -# INGROUP: moko-platform.Release -# REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform +# INGROUP: mokoplatform.Release +# REPO: https://git.mokoconsulting.tech/MokoConsulting/mokoplatform # PATH: /.mokogitea/workflows/auto-bump.yml # VERSION: 09.23.00 # BRIEF: Auto patch-bump version on every push to dev (skips merge commits) @@ -43,21 +43,21 @@ jobs: token: ${{ secrets.MOKOGITEA_TOKEN }} fetch-depth: 1 - - name: Setup moko-platform tools + - name: Setup mokoplatform tools run: | - if [ -f "/opt/moko-platform/cli/version_bump.php" ] && [ -f "/opt/moko-platform/vendor/autoload.php" ]; then - echo "Using pre-installed /opt/moko-platform" - echo "MOKO_CLI=/opt/moko-platform/cli" >> "$GITHUB_ENV" + if [ -f "/opt/mokoplatform/cli/version_bump.php" ] && [ -f "/opt/mokoplatform/vendor/autoload.php" ]; then + echo "Using pre-installed /opt/mokoplatform" + echo "MOKO_CLI=/opt/mokoplatform/cli" >> "$GITHUB_ENV" else if ! command -v composer &> /dev/null; then sudo apt-get update -qq && sudo apt-get install -y -qq php-cli php-mbstring php-xml php-zip php-curl composer >/dev/null 2>&1 fi - rm -rf /tmp/moko-platform-api + rm -rf /tmp/mokoplatform-api git clone --depth 1 --branch main --quiet \ - "https://x-access-token:${{ secrets.MOKOGITEA_TOKEN }}@git.mokoconsulting.tech/MokoConsulting/moko-platform.git" \ - /tmp/moko-platform-api - cd /tmp/moko-platform-api && composer install --no-dev --no-interaction --quiet - echo "MOKO_CLI=/tmp/moko-platform-api/cli" >> "$GITHUB_ENV" + "https://x-access-token:${{ secrets.MOKOGITEA_TOKEN }}@git.mokoconsulting.tech/MokoConsulting/mokoplatform.git" \ + /tmp/mokoplatform-api + cd /tmp/mokoplatform-api && composer install --no-dev --no-interaction --quiet + echo "MOKO_CLI=/tmp/mokoplatform-api/cli" >> "$GITHUB_ENV" fi - name: Bump version -- 2.52.0 From c7b6f98f933692f5eeba0b0c84db1ba24442010e Mon Sep 17 00:00:00 2001 From: Jonathan Miller Date: Thu, 18 Jun 2026 15:53:43 -0500 Subject: [PATCH 04/21] feat: add joomla_metadata_validate CLI command (#257) Validates MokoGitea repo metadata against the actual Joomla extension manifest XML to catch update delivery mismatches before production. Checks: - package_type matches - Element name derived correctly (prefix + lowercase + clean) - Display name matches tag - Version consistency (ignoring -dev/-rc suffixes) - PHP minimum matches composer.json - Description match (informational) Supports: - Local mode: reads .mokogitea/manifest.xml + Joomla XML from disk - API mode: fetches metadata via Gitea API (--token) - CI mode: --ci flag exits 1 on errors - JSON output: --json for workflow integration Handles all Joomla types: package, component, module, plugin, template, library, file. Replicates Joomla's InputFilter::clean('cmd') for element name derivation. Refs mokoplatform #257 --- cli/joomla_metadata_validate.php | 515 +++++++++++++++++++++++++++++++ 1 file changed, 515 insertions(+) create mode 100644 cli/joomla_metadata_validate.php diff --git a/cli/joomla_metadata_validate.php b/cli/joomla_metadata_validate.php new file mode 100644 index 0000000..dac1cc9 --- /dev/null +++ b/cli/joomla_metadata_validate.php @@ -0,0 +1,515 @@ +#!/usr/bin/env php + + * + * SPDX-License-Identifier: GPL-3.0-or-later + * + * FILE INFORMATION + * DEFGROUP: mokoplatform.CLI + * INGROUP: mokoplatform + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokoplatform + * PATH: /cli/joomla_metadata_validate.php + * VERSION: 09.30.00 + * BRIEF: Validate MokoGitea repo metadata against Joomla extension manifest XML + */ + +declare(strict_types=1); + +require_once __DIR__ . '/../lib/Enterprise/CliFramework.php'; + +use MokoEnterprise\CliFramework; + +class JoomlaMetadataValidateCli extends CliFramework +{ + /** Joomla element prefix map — must match MokoGitea's cleanJoomlaElement() */ + private const JOOMLA_PREFIX = [ + 'package' => 'pkg_', + 'component' => 'com_', + 'module' => 'mod_', + 'template' => 'tpl_', + 'library' => 'lib_', + 'file' => 'file_', + ]; + + protected function configure(): void + { + $this->setDescription('Validate MokoGitea repo metadata against Joomla extension manifest XML'); + $this->addArgument('--path', 'Repo root path (default: current directory)', '.'); + $this->addArgument('--token', 'Gitea API token (or GITEA_TOKEN env)', ''); + $this->addArgument('--org', 'Gitea org', 'MokoConsulting'); + $this->addArgument('--repo', 'Repo name (auto-detected from git if empty)', ''); + $this->addArgument('--api-base', 'Gitea API base URL', 'https://git.mokoconsulting.tech/api/v1'); + $this->addArgument('--ci', 'CI mode: exit 1 on any error', false); + $this->addArgument('--json', 'Output as JSON', false); + } + + protected function run(): int + { + $path = realpath($this->getArgument('--path')) ?: $this->getArgument('--path'); + $token = $this->getArgument('--token') ?: getenv('GITEA_TOKEN') ?: ''; + $org = $this->getArgument('--org'); + $repoName = $this->getArgument('--repo'); + $apiBase = rtrim($this->getArgument('--api-base'), '/'); + $ciMode = (bool) $this->getArgument('--ci'); + $jsonMode = (bool) $this->getArgument('--json'); + + if (!is_dir($path)) { + $this->log('ERROR', "Path does not exist: {$path}"); + return 1; + } + + if ($repoName === '') { + $repoName = $this->detectRepoName($path); + } + + // ── Step 1: Find the Joomla extension manifest XML ────────── + $joomlaXml = $this->findJoomlaManifest($path); + + if ($joomlaXml === null) { + $this->log('ERROR', 'No Joomla extension manifest XML found'); + return 1; + } + + $this->log('INFO', "Joomla manifest: {$joomlaXml['path']}"); + + // ── Step 2: Load MokoGitea metadata ───────────────────────── + $metadata = $this->loadMetadata($path, $org, $repoName, $token, $apiBase); + + if ($metadata === null) { + $this->log('ERROR', 'Could not load MokoGitea metadata'); + return 1; + } + + // ── Step 3: Compare ───────────────────────────────────────── + $results = $this->compare($metadata, $joomlaXml, $path); + + // ── Step 4: Output ────────────────────────────────────────── + if ($jsonMode) { + echo json_encode([ + 'repo' => $repoName, + 'results' => $results, + ], JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES) . "\n"; + } else { + $this->printResults($repoName, $results); + } + + $errors = count(array_filter($results, fn($r) => $r['status'] === 'error')); + + return ($ciMode && $errors > 0) ? 1 : 0; + } + + // ================================================================= + // Find Joomla manifest XML + // ================================================================= + + private function findJoomlaManifest(string $root): ?array + { + // Search common locations for a Joomla extension manifest + $candidates = []; + + // Package manifest: source/pkg_*.xml + foreach (glob("{$root}/source/pkg_*.xml") as $file) { + $candidates[] = $file; + } + + // Component manifest: source/packages/com_*/[name].xml + foreach (glob("{$root}/source/packages/com_*/*.xml") as $file) { + $basename = basename($file); + // Skip access.xml, config.xml, etc. + if (in_array($basename, ['access.xml', 'config.xml'], true)) { + continue; + } + $candidates[] = $file; + } + + // Direct source/*.xml + foreach (glob("{$root}/source/*.xml") as $file) { + if (basename($file) !== 'pkg_mokosuitebackup.xml') { + // Already caught above + } + $candidates[] = $file; + } + + // src/ fallback + foreach (glob("{$root}/src/pkg_*.xml") as $file) { + $candidates[] = $file; + } + + // Find the first one that has + foreach (array_unique($candidates) as $file) { + $content = file_get_contents($file); + if ($content === false) { + continue; + } + + if (preg_match('/]*type=["\']([^"\']+)["\']/', $content, $typeMatch)) { + $xml = @simplexml_load_string($content); + if ($xml === false) { + continue; + } + + $type = strtolower($typeMatch[1]); + $relPath = str_replace($root . '/', '', $file); + $relPath = str_replace($root . '\\', '', $relPath); + + return [ + 'path' => $relPath, + 'type' => $type, + 'xml' => $xml, + ]; + } + } + + return null; + } + + // ================================================================= + // Load metadata (from .mokogitea/manifest.xml or API) + // ================================================================= + + private function loadMetadata(string $root, string $org, string $repoName, string $token, string $apiBase): ?array + { + // Try local .mokogitea/manifest.xml first + $localManifest = "{$root}/.mokogitea/manifest.xml"; + + if (is_file($localManifest)) { + $xml = @simplexml_load_file($localManifest); + + if ($xml !== false) { + $identity = $xml->identity ?? $xml; + $governance = $xml->governance ?? $xml; + $build = $xml->build ?? $xml; + + return [ + 'name' => (string) ($identity->name ?? ''), + 'display_name' => (string) ($identity->{'display-name'} ?? ''), + 'description' => (string) ($identity->description ?? ''), + 'version' => (string) ($identity->version ?? ''), + 'platform' => (string) ($governance->platform ?? ''), + 'package_type' => (string) ($build->{'package-type'} ?? ''), + 'language' => (string) ($build->language ?? ''), + 'entry_point' => (string) ($build->{'entry-point'} ?? ''), + 'source' => 'local', + ]; + } + } + + // Fall back to API + if ($token !== '') { + $url = "{$apiBase}/repos/{$org}/{$repoName}/manifest"; + $ctx = stream_context_create([ + 'http' => [ + 'header' => "Authorization: token {$token}\r\nAccept: application/json\r\n", + 'timeout' => 10, + ], + ]); + + $body = @file_get_contents($url, false, $ctx); + + if ($body !== false) { + $data = json_decode($body, true); + if (is_array($data)) { + $data['source'] = 'api'; + return $data; + } + } + } + + return null; + } + + // ================================================================= + // Compare metadata against Joomla manifest + // ================================================================= + + private function compare(array $metadata, array $joomlaXml, string $root): array + { + $results = []; + $xml = $joomlaXml['xml']; + $type = $joomlaXml['type']; + + // 1. Extension type vs package_type + $metaType = $this->normalizePackageType($metadata['package_type'] ?? ''); + $results[] = [ + 'field' => 'package_type', + 'metadata' => $metaType, + 'joomla' => $type, + 'status' => ($metaType === $type) ? 'ok' : 'error', + 'message' => ($metaType === $type) + ? "matches " + : "metadata has \"{$metaType}\" but Joomla manifest has \"{$type}\"", + ]; + + // 2. Element name + $metaName = strtolower($metadata['name'] ?? ''); + $metaElement = $this->deriveElement($metaType, $metaName); + $joomlaElement = $this->extractJoomlaElement($xml, $type); + + $elementMatch = ($metaElement === $joomlaElement); + $results[] = [ + 'field' => 'element', + 'metadata' => $metaElement, + 'joomla' => $joomlaElement, + 'status' => $elementMatch ? 'ok' : 'error', + 'message' => $elementMatch + ? "derived correctly" + : "metadata derives \"{$metaElement}\" but Joomla uses \"{$joomlaElement}\"", + ]; + + // 3. Display name + $metaDisplay = $metadata['display_name'] ?? ''; + $joomlaName = (string) ($xml->name ?? ''); + + if ($metaDisplay !== '' && $joomlaName !== '') { + $displayMatch = ($metaDisplay === $joomlaName); + $results[] = [ + 'field' => 'display_name', + 'metadata' => $metaDisplay, + 'joomla' => $joomlaName, + 'status' => $displayMatch ? 'ok' : 'warn', + 'message' => $displayMatch + ? 'matches' + : "metadata has \"{$metaDisplay}\" but Joomla has \"{$joomlaName}\"", + ]; + } + + // 4. Version + $metaVersion = $metadata['version'] ?? ''; + $joomlaVersion = (string) ($xml->version ?? ''); + + if ($metaVersion !== '' && $joomlaVersion !== '') { + // Strip dev/rc suffixes for comparison (CI bumps these) + $metaBase = preg_replace('/-(dev|rc|alpha|beta)\d*$/', '', $metaVersion); + $joomlaBase = preg_replace('/-(dev|rc|alpha|beta)\d*$/', '', $joomlaVersion); + $versionMatch = ($metaBase === $joomlaBase); + + $results[] = [ + 'field' => 'version', + 'metadata' => $metaVersion, + 'joomla' => $joomlaVersion, + 'status' => $versionMatch ? 'ok' : 'warn', + 'message' => $versionMatch + ? 'matches (base version)' + : "metadata has \"{$metaVersion}\" but Joomla has \"{$joomlaVersion}\"", + ]; + } + + // 5. PHP minimum (from composer.json) + $composerPhp = $this->readComposerPhpRequirement($root); + $metaPhp = $metadata['php_minimum'] ?? ''; + + if ($composerPhp !== '' && $metaPhp !== '') { + $phpMatch = ($metaPhp === $composerPhp); + $results[] = [ + 'field' => 'php_minimum', + 'metadata' => $metaPhp, + 'joomla' => $composerPhp . ' (composer.json)', + 'status' => $phpMatch ? 'ok' : 'warn', + 'message' => $phpMatch + ? 'matches composer.json' + : "metadata has \"{$metaPhp}\" but composer.json requires \"{$composerPhp}\"", + ]; + } + + // 6. Description + $metaDesc = $metadata['description'] ?? ''; + $joomlaDesc = (string) ($xml->description ?? ''); + + // Joomla descriptions are often language keys, skip those + if ($metaDesc !== '' && $joomlaDesc !== '' && !str_starts_with($joomlaDesc, 'COM_') && !str_starts_with($joomlaDesc, 'PKG_')) { + $descMatch = ($metaDesc === $joomlaDesc); + $results[] = [ + 'field' => 'description', + 'metadata' => substr($metaDesc, 0, 60) . (strlen($metaDesc) > 60 ? '...' : ''), + 'joomla' => substr($joomlaDesc, 0, 60) . (strlen($joomlaDesc) > 60 ? '...' : ''), + 'status' => $descMatch ? 'ok' : 'info', + 'message' => $descMatch ? 'matches' : 'descriptions differ (informational)', + ]; + } + + return $results; + } + + // ================================================================= + // Helpers + // ================================================================= + + /** + * Normalize package_type — map MokoGitea types to Joomla types. + */ + private function normalizePackageType(string $type): string + { + return match (strtolower($type)) { + 'joomla-extension' => 'package', // legacy mapping + default => strtolower($type), + }; + } + + /** + * Derive the Joomla element name from type + name. + * Replicates MokoGitea's cleanJoomlaElement() + prefix logic. + */ + private function deriveElement(string $type, string $name): string + { + // Clean: lowercase, strip non-alphanumeric except . _ - + $clean = strtolower($name); + $clean = preg_replace('/[^a-z0-9._-]/', '', $clean); + + $prefix = self::JOOMLA_PREFIX[$type] ?? ''; + + return $prefix . $clean; + } + + /** + * Extract the element name from a Joomla manifest XML. + * Follows the same logic as Joomla's InstallerAdapter::getElement(). + */ + private function extractJoomlaElement(\SimpleXMLElement $xml, string $type): string + { + switch ($type) { + case 'package': + $packagename = (string) ($xml->packagename ?? ''); + if ($packagename !== '') { + return 'pkg_' . strtolower(preg_replace('/[^a-zA-Z0-9._-]/', '', $packagename)); + } + break; + + case 'component': + $element = (string) ($xml->element ?? ''); + if ($element !== '') { + $element = strtolower($element); + return str_starts_with($element, 'com_') ? $element : 'com_' . $element; + } + $name = (string) ($xml->name ?? ''); + $name = strtolower(preg_replace('/[^a-zA-Z0-9._-]/', '', $name)); + return str_starts_with($name, 'com_') ? $name : 'com_' . $name; + + case 'module': + $element = (string) ($xml->element ?? ''); + if ($element !== '') { + return strtolower($element); + } + break; + + case 'plugin': + // Plugins derive element from the file attribute + if (isset($xml->files)) { + foreach ($xml->files->children() as $file) { + $plugin = (string) ($file->attributes()->plugin ?? ''); + if ($plugin !== '') { + return strtolower($plugin); + } + } + } + break; + + case 'library': + $libname = (string) ($xml->libraryname ?? ''); + if ($libname !== '') { + return strtolower($libname); + } + break; + } + + // Fallback: use tag + $name = (string) ($xml->name ?? ''); + return strtolower(preg_replace('/[^a-zA-Z0-9._-]/', '', $name)); + } + + /** + * Read PHP version requirement from composer.json. + */ + private function readComposerPhpRequirement(string $root): string + { + $composerFile = "{$root}/composer.json"; + + if (!is_file($composerFile)) { + return ''; + } + + $data = json_decode(file_get_contents($composerFile), true); + + if (!is_array($data)) { + return ''; + } + + $phpReq = $data['require']['php'] ?? ''; + + // Extract version number from constraint like ">=8.1" + if (preg_match('/(\d+\.\d+)/', $phpReq, $m)) { + return $m[1]; + } + + return ''; + } + + private function detectRepoName(string $root): string + { + $gitConfig = "{$root}/.git/config"; + + if (!file_exists($gitConfig)) { + return basename($root); + } + + $content = file_get_contents($gitConfig); + + if (preg_match('/url\s*=\s*.*\/([^\/\s]+?)(?:\.git)?\s*$/m', $content, $m)) { + return $m[1]; + } + + return basename($root); + } + + // ================================================================= + // Output + // ================================================================= + + private function printResults(string $repoName, array $results): void + { + $errors = count(array_filter($results, fn($r) => $r['status'] === 'error')); + $warns = count(array_filter($results, fn($r) => $r['status'] === 'warn')); + $oks = count(array_filter($results, fn($r) => $r['status'] === 'ok')); + + $this->log('INFO', "Validating {$repoName} Joomla metadata...\n"); + + foreach ($results as $r) { + $icon = match ($r['status']) { + 'ok' => "\xE2\x9C\x93", // ✓ + 'error' => "\xE2\x9C\x97", // ✗ + 'warn' => "\xE2\x9A\xA0", // ⚠ + default => "\xE2\x84\xB9", // ℹ + }; + + $line = sprintf( + " %s %-16s %s", + $icon, + $r['field'], + $r['message'] + ); + + $this->log( + match ($r['status']) { + 'error' => 'ERROR', + 'warn' => 'WARN', + 'ok' => 'OK', + default => 'INFO', + }, + $line + ); + } + + echo "\n"; + + if ($errors > 0) { + $this->log('ERROR', "{$errors} error(s) — update delivery will fail"); + } elseif ($warns > 0) { + $this->log('WARN', "All critical checks passed, {$warns} warning(s)"); + } else { + $this->log('OK', "All {$oks} checks passed"); + } + } +} + +$app = new JoomlaMetadataValidateCli(); +exit($app->execute()); -- 2.52.0 From a51f0bfb2fc0a5da30208c801dc8c268116dbf1e Mon Sep 17 00:00:00 2001 From: Jonathan Miller Date: Fri, 19 Jun 2026 03:13:31 -0500 Subject: [PATCH 05/21] fix: rename package_type to extension_type, remove display_name validation (#259) - API endpoint updated from /manifest to /metadata - Removed dead .mokogitea/manifest.xml local file fallback - display_name is now server-computed, no longer validated - package_type renamed to extension_type throughout --- cli/joomla_metadata_validate.php | 63 +++++--------------------------- 1 file changed, 10 insertions(+), 53 deletions(-) diff --git a/cli/joomla_metadata_validate.php b/cli/joomla_metadata_validate.php index dac1cc9..90fa2c3 100644 --- a/cli/joomla_metadata_validate.php +++ b/cli/joomla_metadata_validate.php @@ -165,39 +165,13 @@ class JoomlaMetadataValidateCli extends CliFramework } // ================================================================= - // Load metadata (from .mokogitea/manifest.xml or API) + // Load metadata (from API) // ================================================================= private function loadMetadata(string $root, string $org, string $repoName, string $token, string $apiBase): ?array { - // Try local .mokogitea/manifest.xml first - $localManifest = "{$root}/.mokogitea/manifest.xml"; - - if (is_file($localManifest)) { - $xml = @simplexml_load_file($localManifest); - - if ($xml !== false) { - $identity = $xml->identity ?? $xml; - $governance = $xml->governance ?? $xml; - $build = $xml->build ?? $xml; - - return [ - 'name' => (string) ($identity->name ?? ''), - 'display_name' => (string) ($identity->{'display-name'} ?? ''), - 'description' => (string) ($identity->description ?? ''), - 'version' => (string) ($identity->version ?? ''), - 'platform' => (string) ($governance->platform ?? ''), - 'package_type' => (string) ($build->{'package-type'} ?? ''), - 'language' => (string) ($build->language ?? ''), - 'entry_point' => (string) ($build->{'entry-point'} ?? ''), - 'source' => 'local', - ]; - } - } - - // Fall back to API if ($token !== '') { - $url = "{$apiBase}/repos/{$org}/{$repoName}/manifest"; + $url = "{$apiBase}/repos/{$org}/{$repoName}/metadata"; $ctx = stream_context_create([ 'http' => [ 'header' => "Authorization: token {$token}\r\nAccept: application/json\r\n", @@ -229,10 +203,10 @@ class JoomlaMetadataValidateCli extends CliFramework $xml = $joomlaXml['xml']; $type = $joomlaXml['type']; - // 1. Extension type vs package_type - $metaType = $this->normalizePackageType($metadata['package_type'] ?? ''); + // 1. Extension type + $metaType = $this->normalizeExtensionType($metadata['extension_type'] ?? ''); $results[] = [ - 'field' => 'package_type', + 'field' => 'extension_type', 'metadata' => $metaType, 'joomla' => $type, 'status' => ($metaType === $type) ? 'ok' : 'error', @@ -257,24 +231,7 @@ class JoomlaMetadataValidateCli extends CliFramework : "metadata derives \"{$metaElement}\" but Joomla uses \"{$joomlaElement}\"", ]; - // 3. Display name - $metaDisplay = $metadata['display_name'] ?? ''; - $joomlaName = (string) ($xml->name ?? ''); - - if ($metaDisplay !== '' && $joomlaName !== '') { - $displayMatch = ($metaDisplay === $joomlaName); - $results[] = [ - 'field' => 'display_name', - 'metadata' => $metaDisplay, - 'joomla' => $joomlaName, - 'status' => $displayMatch ? 'ok' : 'warn', - 'message' => $displayMatch - ? 'matches' - : "metadata has \"{$metaDisplay}\" but Joomla has \"{$joomlaName}\"", - ]; - } - - // 4. Version + // 3. Version $metaVersion = $metadata['version'] ?? ''; $joomlaVersion = (string) ($xml->version ?? ''); @@ -295,7 +252,7 @@ class JoomlaMetadataValidateCli extends CliFramework ]; } - // 5. PHP minimum (from composer.json) + // 4. PHP minimum (from composer.json) $composerPhp = $this->readComposerPhpRequirement($root); $metaPhp = $metadata['php_minimum'] ?? ''; @@ -312,7 +269,7 @@ class JoomlaMetadataValidateCli extends CliFramework ]; } - // 6. Description + // 5. Description $metaDesc = $metadata['description'] ?? ''; $joomlaDesc = (string) ($xml->description ?? ''); @@ -336,9 +293,9 @@ class JoomlaMetadataValidateCli extends CliFramework // ================================================================= /** - * Normalize package_type — map MokoGitea types to Joomla types. + * Normalize extension_type — map MokoGitea types to Joomla types. */ - private function normalizePackageType(string $type): string + private function normalizeExtensionType(string $type): string { return match (strtolower($type)) { 'joomla-extension' => 'package', // legacy mapping -- 2.52.0 From 1b113af0687df357b3c623c3cde071a5e3d1b1c3 Mon Sep 17 00:00:00 2001 From: "gitea-actions[bot]" Date: Fri, 19 Jun 2026 08:14:01 +0000 Subject: [PATCH 06/21] chore(version): pre-release bump to 09.25.04-dev [skip ci] --- .mokogitea/workflows/issue-branch.yml | 2 +- README.md | 2 +- cli/branch_rename.php | 2 +- cli/bulk_workflow_push.php | 2 +- cli/bulk_workflow_trigger.php | 2 +- cli/client_dashboard.php | 2 +- cli/client_inventory.php | 2 +- cli/client_provision.php | 2 +- cli/grafana_dashboard.php | 2 +- cli/joomla_build.php | 2 +- cli/joomla_metadata_validate.php | 2 +- cli/manifest_licensing.php | 2 +- cli/manifest_read.php | 2 +- cli/platform_detect.php | 2 +- cli/release_cascade.php | 2 +- cli/release_publish.php | 2 +- cli/scaffold_client.php | 2 +- cli/updates_xml_sync.php | 2 +- cli/version_auto_bump.php | 2 +- cli/version_check.php | 2 +- cli/wiki_sync.php | 2 +- cli/workflow_sync.php | 2 +- deploy/backup-before-deploy.php | 2 +- deploy/deploy-dolibarr.php | 2 +- deploy/health-check.php | 2 +- deploy/rollback-joomla.php | 2 +- deploy/sync-joomla.php | 2 +- tests/Unit/VersionBumpTest.php | 2 +- tests/Unit/VersionReadTest.php | 4 ++-- validate/check_file_integrity.php | 2 +- 30 files changed, 31 insertions(+), 31 deletions(-) diff --git a/.mokogitea/workflows/issue-branch.yml b/.mokogitea/workflows/issue-branch.yml index be48abe..3819480 100644 --- a/.mokogitea/workflows/issue-branch.yml +++ b/.mokogitea/workflows/issue-branch.yml @@ -5,7 +5,7 @@ # FILE INFORMATION # DEFGROUP: Gitea.Workflow # INGROUP: moko-platform.Automation -# VERSION: 09.25.03 +# VERSION: 09.25.04 # BRIEF: Auto-create feature branch when an issue is opened name: "Universal: Issue Branch" diff --git a/README.md b/README.md index a4b1b82..49fdc19 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ DEFGROUP: MokoPlatform.Root INGROUP: MokoPlatform REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform PATH: /README.md -VERSION: 09.25.03 +VERSION: 09.25.04 BRIEF: Project overview and documentation --> diff --git a/cli/branch_rename.php b/cli/branch_rename.php index fdc7c40..89190e4 100644 --- a/cli/branch_rename.php +++ b/cli/branch_rename.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/branch_rename.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Rename a git branch via Gitea API (create new, update PR, delete old) */ diff --git a/cli/bulk_workflow_push.php b/cli/bulk_workflow_push.php index 06e7281..5d9c8d1 100644 --- a/cli/bulk_workflow_push.php +++ b/cli/bulk_workflow_push.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/bulk_workflow_push.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Push a workflow file to all governed repos via the Gitea Contents API */ diff --git a/cli/bulk_workflow_trigger.php b/cli/bulk_workflow_trigger.php index 426a264..bf5e08d 100644 --- a/cli/bulk_workflow_trigger.php +++ b/cli/bulk_workflow_trigger.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/bulk_workflow_trigger.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Trigger a workflow across multiple repos at once */ diff --git a/cli/client_dashboard.php b/cli/client_dashboard.php index 73d62ad..5c6e1fd 100644 --- a/cli/client_dashboard.php +++ b/cli/client_dashboard.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/client_dashboard.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Generate unified client dashboard HTML */ diff --git a/cli/client_inventory.php b/cli/client_inventory.php index 34679c0..4df49ca 100644 --- a/cli/client_inventory.php +++ b/cli/client_inventory.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/client_inventory.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Discover and list all client-waas repos with their server configuration status */ diff --git a/cli/client_provision.php b/cli/client_provision.php index 44c66df..ff960c7 100644 --- a/cli/client_provision.php +++ b/cli/client_provision.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/client_provision.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Provision a new client environment end-to-end */ diff --git a/cli/grafana_dashboard.php b/cli/grafana_dashboard.php index e15ad34..9c9f0ab 100644 --- a/cli/grafana_dashboard.php +++ b/cli/grafana_dashboard.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/grafana_dashboard.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Manage Grafana dashboards via API */ diff --git a/cli/joomla_build.php b/cli/joomla_build.php index e758d3b..61a0df8 100644 --- a/cli/joomla_build.php +++ b/cli/joomla_build.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/joomla_build.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Build a Joomla extension ZIP from manifest — all types supported * NOTE: Called by pre-release and auto-release workflows. */ diff --git a/cli/joomla_metadata_validate.php b/cli/joomla_metadata_validate.php index 90fa2c3..b7b07d8 100644 --- a/cli/joomla_metadata_validate.php +++ b/cli/joomla_metadata_validate.php @@ -10,7 +10,7 @@ * INGROUP: mokoplatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokoplatform * PATH: /cli/joomla_metadata_validate.php - * VERSION: 09.30.00 + * VERSION: 09.25.04 * BRIEF: Validate MokoGitea repo metadata against Joomla extension manifest XML */ diff --git a/cli/manifest_licensing.php b/cli/manifest_licensing.php index 565a7e1..3058b66 100644 --- a/cli/manifest_licensing.php +++ b/cli/manifest_licensing.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/manifest_licensing.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Ensure licensing tags (updateservers, dlid) in Joomla extension manifests */ diff --git a/cli/manifest_read.php b/cli/manifest_read.php index 441366f..6bcfa13 100644 --- a/cli/manifest_read.php +++ b/cli/manifest_read.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/manifest_read.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Parse .manifest.xml and output requested field(s) for CI consumption */ diff --git a/cli/platform_detect.php b/cli/platform_detect.php index 7892ed4..0b19eff 100644 --- a/cli/platform_detect.php +++ b/cli/platform_detect.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/platform_detect.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Auto-detect repository platform type and optionally update manifest */ diff --git a/cli/release_cascade.php b/cli/release_cascade.php index 2b64134..a760acd 100644 --- a/cli/release_cascade.php +++ b/cli/release_cascade.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/release_cascade.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: DEPRECATED — cascade behavior removed. Each release stream is independent. */ diff --git a/cli/release_publish.php b/cli/release_publish.php index 9e4b368..cb22975 100644 --- a/cli/release_publish.php +++ b/cli/release_publish.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/release_publish.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Publish a release and create copies for all lesser stability streams. */ diff --git a/cli/scaffold_client.php b/cli/scaffold_client.php index efc2466..7df9e2c 100644 --- a/cli/scaffold_client.php +++ b/cli/scaffold_client.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/scaffold_client.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Scaffold a new client-waas repo from Template-Client-WaaS with pre-configured settings */ diff --git a/cli/updates_xml_sync.php b/cli/updates_xml_sync.php index db20af5..31ee8d0 100644 --- a/cli/updates_xml_sync.php +++ b/cli/updates_xml_sync.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/updates_xml_sync.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Sync updates.xml to target branches via Gitea API * NOTE: Called by pre-release and auto-release workflows after updates.xml * is modified on the current branch. Pushes the file to other branches diff --git a/cli/version_auto_bump.php b/cli/version_auto_bump.php index 4282140..c028360 100644 --- a/cli/version_auto_bump.php +++ b/cli/version_auto_bump.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/version_auto_bump.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Auto patch-bump, set stability suffix, and commit — single CLI replacing inline workflow bash */ diff --git a/cli/version_check.php b/cli/version_check.php index ec2af82..fe84c9d 100644 --- a/cli/version_check.php +++ b/cli/version_check.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/version_check.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Validate version consistency across README, manifests, and sub-packages */ diff --git a/cli/wiki_sync.php b/cli/wiki_sync.php index 4c68879..34c5f6b 100644 --- a/cli/wiki_sync.php +++ b/cli/wiki_sync.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/wiki_sync.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Sync select wiki pages from moko-platform to all template repos */ diff --git a/cli/workflow_sync.php b/cli/workflow_sync.php index f22b352..96bec10 100644 --- a/cli/workflow_sync.php +++ b/cli/workflow_sync.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/workflow_sync.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Sync workflows from Generic → platform templates → live repos based on manifest.platform */ diff --git a/deploy/backup-before-deploy.php b/deploy/backup-before-deploy.php index db7c54f..d2cea7a 100644 --- a/deploy/backup-before-deploy.php +++ b/deploy/backup-before-deploy.php @@ -12,7 +12,7 @@ * INGROUP: MokoPlatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /deploy/backup-before-deploy.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Snapshot Joomla directories before deployment for rollback capability */ diff --git a/deploy/deploy-dolibarr.php b/deploy/deploy-dolibarr.php index d10d782..9972774 100644 --- a/deploy/deploy-dolibarr.php +++ b/deploy/deploy-dolibarr.php @@ -12,7 +12,7 @@ * INGROUP: MokoPlatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /deploy/deploy-dolibarr.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Deploy Dolibarr module files to a remote server via SFTP/rsync */ diff --git a/deploy/health-check.php b/deploy/health-check.php index b7fbcc3..af50850 100644 --- a/deploy/health-check.php +++ b/deploy/health-check.php @@ -12,7 +12,7 @@ * INGROUP: MokoPlatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /deploy/health-check.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Post-deploy health check — verify a Joomla site is responding correctly */ diff --git a/deploy/rollback-joomla.php b/deploy/rollback-joomla.php index 5650bfa..a5ff9bc 100644 --- a/deploy/rollback-joomla.php +++ b/deploy/rollback-joomla.php @@ -12,7 +12,7 @@ * INGROUP: MokoPlatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /deploy/rollback-joomla.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Rollback a Joomla deployment by restoring from a pre-deploy snapshot */ diff --git a/deploy/sync-joomla.php b/deploy/sync-joomla.php index fb4d970..027ec79 100644 --- a/deploy/sync-joomla.php +++ b/deploy/sync-joomla.php @@ -12,7 +12,7 @@ * INGROUP: MokoPlatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /deploy/sync-joomla.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Sync Joomla site directories between two servers via rsync over SSH */ diff --git a/tests/Unit/VersionBumpTest.php b/tests/Unit/VersionBumpTest.php index e129061..250fa35 100644 --- a/tests/Unit/VersionBumpTest.php +++ b/tests/Unit/VersionBumpTest.php @@ -63,7 +63,7 @@ class VersionBumpTest extends TestCase { file_put_contents( "{$this->tmpDir}/README.md", - "\nSome content\n" + "\nSome content\n" ); $this->execute(); diff --git a/tests/Unit/VersionReadTest.php b/tests/Unit/VersionReadTest.php index bbba14a..a7060c1 100644 --- a/tests/Unit/VersionReadTest.php +++ b/tests/Unit/VersionReadTest.php @@ -34,7 +34,7 @@ class VersionReadTest extends TestCase { file_put_contents( "{$this->tmpDir}/README.md", - "# Test\n\n" + "# Test\n\n" ); $this->assertSame('02.03.04', trim($this->runScript())); @@ -68,7 +68,7 @@ class VersionReadTest extends TestCase { file_put_contents( "{$this->tmpDir}/README.md", - "\n" + "\n" ); mkdir("{$this->tmpDir}/src", 0755, true); file_put_contents( diff --git a/validate/check_file_integrity.php b/validate/check_file_integrity.php index 3fe5c5d..f5a60a0 100644 --- a/validate/check_file_integrity.php +++ b/validate/check_file_integrity.php @@ -12,7 +12,7 @@ * INGROUP: MokoPlatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /validate/check_file_integrity.php - * VERSION: 09.25.03 + * VERSION: 09.25.04 * BRIEF: Compare deployed files on a remote server against the local repository to detect drift */ -- 2.52.0 From e4de039cffe8633820fc799d626f65c79d4ec7c2 Mon Sep 17 00:00:00 2001 From: "gitea-actions[bot]" Date: Fri, 19 Jun 2026 08:16:30 +0000 Subject: [PATCH 07/21] chore(version): pre-release bump to 09.25.05-dev [skip ci] --- .mokogitea/workflows/issue-branch.yml | 2 +- README.md | 2 +- cli/branch_rename.php | 2 +- cli/bulk_workflow_push.php | 2 +- cli/bulk_workflow_trigger.php | 2 +- cli/client_dashboard.php | 2 +- cli/client_inventory.php | 2 +- cli/client_provision.php | 2 +- cli/grafana_dashboard.php | 2 +- cli/joomla_build.php | 2 +- cli/joomla_metadata_validate.php | 2 +- cli/manifest_licensing.php | 2 +- cli/manifest_read.php | 2 +- cli/platform_detect.php | 2 +- cli/release_cascade.php | 2 +- cli/release_publish.php | 2 +- cli/scaffold_client.php | 2 +- cli/updates_xml_sync.php | 2 +- cli/version_auto_bump.php | 2 +- cli/version_check.php | 2 +- cli/wiki_sync.php | 2 +- cli/workflow_sync.php | 2 +- deploy/backup-before-deploy.php | 2 +- deploy/deploy-dolibarr.php | 2 +- deploy/health-check.php | 2 +- deploy/rollback-joomla.php | 2 +- deploy/sync-joomla.php | 2 +- tests/Unit/VersionBumpTest.php | 2 +- tests/Unit/VersionReadTest.php | 4 ++-- validate/check_file_integrity.php | 2 +- 30 files changed, 31 insertions(+), 31 deletions(-) diff --git a/.mokogitea/workflows/issue-branch.yml b/.mokogitea/workflows/issue-branch.yml index 3819480..98b6504 100644 --- a/.mokogitea/workflows/issue-branch.yml +++ b/.mokogitea/workflows/issue-branch.yml @@ -5,7 +5,7 @@ # FILE INFORMATION # DEFGROUP: Gitea.Workflow # INGROUP: moko-platform.Automation -# VERSION: 09.25.04 +# VERSION: 09.25.05 # BRIEF: Auto-create feature branch when an issue is opened name: "Universal: Issue Branch" diff --git a/README.md b/README.md index 49fdc19..2091584 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ DEFGROUP: MokoPlatform.Root INGROUP: MokoPlatform REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform PATH: /README.md -VERSION: 09.25.04 +VERSION: 09.25.05 BRIEF: Project overview and documentation --> diff --git a/cli/branch_rename.php b/cli/branch_rename.php index 89190e4..a3c40cd 100644 --- a/cli/branch_rename.php +++ b/cli/branch_rename.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/branch_rename.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Rename a git branch via Gitea API (create new, update PR, delete old) */ diff --git a/cli/bulk_workflow_push.php b/cli/bulk_workflow_push.php index 5d9c8d1..d0a28e7 100644 --- a/cli/bulk_workflow_push.php +++ b/cli/bulk_workflow_push.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/bulk_workflow_push.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Push a workflow file to all governed repos via the Gitea Contents API */ diff --git a/cli/bulk_workflow_trigger.php b/cli/bulk_workflow_trigger.php index bf5e08d..87400eb 100644 --- a/cli/bulk_workflow_trigger.php +++ b/cli/bulk_workflow_trigger.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/bulk_workflow_trigger.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Trigger a workflow across multiple repos at once */ diff --git a/cli/client_dashboard.php b/cli/client_dashboard.php index 5c6e1fd..e64d235 100644 --- a/cli/client_dashboard.php +++ b/cli/client_dashboard.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/client_dashboard.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Generate unified client dashboard HTML */ diff --git a/cli/client_inventory.php b/cli/client_inventory.php index 4df49ca..0b3ce91 100644 --- a/cli/client_inventory.php +++ b/cli/client_inventory.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/client_inventory.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Discover and list all client-waas repos with their server configuration status */ diff --git a/cli/client_provision.php b/cli/client_provision.php index ff960c7..6e0ec08 100644 --- a/cli/client_provision.php +++ b/cli/client_provision.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/client_provision.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Provision a new client environment end-to-end */ diff --git a/cli/grafana_dashboard.php b/cli/grafana_dashboard.php index 9c9f0ab..9ae09cb 100644 --- a/cli/grafana_dashboard.php +++ b/cli/grafana_dashboard.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/grafana_dashboard.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Manage Grafana dashboards via API */ diff --git a/cli/joomla_build.php b/cli/joomla_build.php index 61a0df8..b8ab547 100644 --- a/cli/joomla_build.php +++ b/cli/joomla_build.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/joomla_build.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Build a Joomla extension ZIP from manifest — all types supported * NOTE: Called by pre-release and auto-release workflows. */ diff --git a/cli/joomla_metadata_validate.php b/cli/joomla_metadata_validate.php index b7b07d8..4dbba7e 100644 --- a/cli/joomla_metadata_validate.php +++ b/cli/joomla_metadata_validate.php @@ -10,7 +10,7 @@ * INGROUP: mokoplatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokoplatform * PATH: /cli/joomla_metadata_validate.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Validate MokoGitea repo metadata against Joomla extension manifest XML */ diff --git a/cli/manifest_licensing.php b/cli/manifest_licensing.php index 3058b66..b7b825e 100644 --- a/cli/manifest_licensing.php +++ b/cli/manifest_licensing.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/manifest_licensing.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Ensure licensing tags (updateservers, dlid) in Joomla extension manifests */ diff --git a/cli/manifest_read.php b/cli/manifest_read.php index 6bcfa13..fca4eba 100644 --- a/cli/manifest_read.php +++ b/cli/manifest_read.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/manifest_read.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Parse .manifest.xml and output requested field(s) for CI consumption */ diff --git a/cli/platform_detect.php b/cli/platform_detect.php index 0b19eff..fe4042d 100644 --- a/cli/platform_detect.php +++ b/cli/platform_detect.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/platform_detect.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Auto-detect repository platform type and optionally update manifest */ diff --git a/cli/release_cascade.php b/cli/release_cascade.php index a760acd..fb3fb47 100644 --- a/cli/release_cascade.php +++ b/cli/release_cascade.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/release_cascade.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: DEPRECATED — cascade behavior removed. Each release stream is independent. */ diff --git a/cli/release_publish.php b/cli/release_publish.php index cb22975..cc273dd 100644 --- a/cli/release_publish.php +++ b/cli/release_publish.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/release_publish.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Publish a release and create copies for all lesser stability streams. */ diff --git a/cli/scaffold_client.php b/cli/scaffold_client.php index 7df9e2c..5275190 100644 --- a/cli/scaffold_client.php +++ b/cli/scaffold_client.php @@ -12,7 +12,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/scaffold_client.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Scaffold a new client-waas repo from Template-Client-WaaS with pre-configured settings */ diff --git a/cli/updates_xml_sync.php b/cli/updates_xml_sync.php index 31ee8d0..cf19020 100644 --- a/cli/updates_xml_sync.php +++ b/cli/updates_xml_sync.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/updates_xml_sync.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Sync updates.xml to target branches via Gitea API * NOTE: Called by pre-release and auto-release workflows after updates.xml * is modified on the current branch. Pushes the file to other branches diff --git a/cli/version_auto_bump.php b/cli/version_auto_bump.php index c028360..84facf1 100644 --- a/cli/version_auto_bump.php +++ b/cli/version_auto_bump.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/version_auto_bump.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Auto patch-bump, set stability suffix, and commit — single CLI replacing inline workflow bash */ diff --git a/cli/version_check.php b/cli/version_check.php index fe84c9d..dc0a16d 100644 --- a/cli/version_check.php +++ b/cli/version_check.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/version_check.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Validate version consistency across README, manifests, and sub-packages */ diff --git a/cli/wiki_sync.php b/cli/wiki_sync.php index 34c5f6b..69c6202 100644 --- a/cli/wiki_sync.php +++ b/cli/wiki_sync.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/wiki_sync.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Sync select wiki pages from moko-platform to all template repos */ diff --git a/cli/workflow_sync.php b/cli/workflow_sync.php index 96bec10..063768f 100644 --- a/cli/workflow_sync.php +++ b/cli/workflow_sync.php @@ -10,7 +10,7 @@ * INGROUP: moko-platform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /cli/workflow_sync.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Sync workflows from Generic → platform templates → live repos based on manifest.platform */ diff --git a/deploy/backup-before-deploy.php b/deploy/backup-before-deploy.php index d2cea7a..66665d1 100644 --- a/deploy/backup-before-deploy.php +++ b/deploy/backup-before-deploy.php @@ -12,7 +12,7 @@ * INGROUP: MokoPlatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /deploy/backup-before-deploy.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Snapshot Joomla directories before deployment for rollback capability */ diff --git a/deploy/deploy-dolibarr.php b/deploy/deploy-dolibarr.php index 9972774..56d3440 100644 --- a/deploy/deploy-dolibarr.php +++ b/deploy/deploy-dolibarr.php @@ -12,7 +12,7 @@ * INGROUP: MokoPlatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /deploy/deploy-dolibarr.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Deploy Dolibarr module files to a remote server via SFTP/rsync */ diff --git a/deploy/health-check.php b/deploy/health-check.php index af50850..968cb4b 100644 --- a/deploy/health-check.php +++ b/deploy/health-check.php @@ -12,7 +12,7 @@ * INGROUP: MokoPlatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /deploy/health-check.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Post-deploy health check — verify a Joomla site is responding correctly */ diff --git a/deploy/rollback-joomla.php b/deploy/rollback-joomla.php index a5ff9bc..a7e4f0f 100644 --- a/deploy/rollback-joomla.php +++ b/deploy/rollback-joomla.php @@ -12,7 +12,7 @@ * INGROUP: MokoPlatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /deploy/rollback-joomla.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Rollback a Joomla deployment by restoring from a pre-deploy snapshot */ diff --git a/deploy/sync-joomla.php b/deploy/sync-joomla.php index 027ec79..af1a6c0 100644 --- a/deploy/sync-joomla.php +++ b/deploy/sync-joomla.php @@ -12,7 +12,7 @@ * INGROUP: MokoPlatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /deploy/sync-joomla.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Sync Joomla site directories between two servers via rsync over SSH */ diff --git a/tests/Unit/VersionBumpTest.php b/tests/Unit/VersionBumpTest.php index 250fa35..a7aee68 100644 --- a/tests/Unit/VersionBumpTest.php +++ b/tests/Unit/VersionBumpTest.php @@ -63,7 +63,7 @@ class VersionBumpTest extends TestCase { file_put_contents( "{$this->tmpDir}/README.md", - "\nSome content\n" + "\nSome content\n" ); $this->execute(); diff --git a/tests/Unit/VersionReadTest.php b/tests/Unit/VersionReadTest.php index a7060c1..2196c73 100644 --- a/tests/Unit/VersionReadTest.php +++ b/tests/Unit/VersionReadTest.php @@ -34,7 +34,7 @@ class VersionReadTest extends TestCase { file_put_contents( "{$this->tmpDir}/README.md", - "# Test\n\n" + "# Test\n\n" ); $this->assertSame('02.03.04', trim($this->runScript())); @@ -68,7 +68,7 @@ class VersionReadTest extends TestCase { file_put_contents( "{$this->tmpDir}/README.md", - "\n" + "\n" ); mkdir("{$this->tmpDir}/src", 0755, true); file_put_contents( diff --git a/validate/check_file_integrity.php b/validate/check_file_integrity.php index f5a60a0..fabb0d9 100644 --- a/validate/check_file_integrity.php +++ b/validate/check_file_integrity.php @@ -12,7 +12,7 @@ * INGROUP: MokoPlatform * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform * PATH: /validate/check_file_integrity.php - * VERSION: 09.25.04 + * VERSION: 09.25.05 * BRIEF: Compare deployed files on a remote server against the local repository to detect drift */ -- 2.52.0 From df83f36436c6ef1ab569c7a85c9341923c0b074b Mon Sep 17 00:00:00 2001 From: Jonathan Miller Date: Sat, 20 Jun 2026 11:14:50 -0500 Subject: [PATCH 08/21] fix: add MokoCLI backward-compatibility aliases and redirect stubs (#276) Prepare for the mokoplatform -> MokoCLI rename by introducing aliases so both old and new names work during the transition: - src/aliases.php: forward function aliases (mokocli_version, etc.) and install path resolver accepting both /opt/mokocli and /opt/mokoplatform - scripts/setup-mokocli-aliases.sh: runner provisioning script to create symlinks between mokocli and mokoplatform paths - composer.json: auto-load aliases.php - mcp/package.json: add mokocli-mcp bin alias alongside moko-platform-mcp - auto-bump.yml: check both /opt/mokocli and /opt/mokoplatform paths - platform_detect.php: accept both mokocli and mokoplatform directory names --- .mokogitea/workflows/auto-bump.yml | 18 +++++--- cli/platform_detect.php | 4 +- composer.json | 3 +- mcp/package.json | 3 +- scripts/setup-mokocli-aliases.sh | 43 ++++++++++++++++++ src/aliases.php | 71 ++++++++++++++++++++++++++++++ 6 files changed, 131 insertions(+), 11 deletions(-) create mode 100644 scripts/setup-mokocli-aliases.sh create mode 100644 src/aliases.php diff --git a/.mokogitea/workflows/auto-bump.yml b/.mokogitea/workflows/auto-bump.yml index dd6e867..17edc11 100644 --- a/.mokogitea/workflows/auto-bump.yml +++ b/.mokogitea/workflows/auto-bump.yml @@ -43,21 +43,25 @@ jobs: token: ${{ secrets.MOKOGITEA_TOKEN }} fetch-depth: 1 - - name: Setup mokoplatform tools + - name: Setup MokoCLI tools run: | - if [ -f "/opt/mokoplatform/cli/version_bump.php" ] && [ -f "/opt/mokoplatform/vendor/autoload.php" ]; then - echo "Using pre-installed /opt/mokoplatform" + # Check both new (mokocli) and legacy (mokoplatform) install paths + if [ -f "/opt/mokocli/cli/version_bump.php" ] && [ -f "/opt/mokocli/vendor/autoload.php" ]; then + echo "Using pre-installed /opt/mokocli" + echo "MOKO_CLI=/opt/mokocli/cli" >> "$GITHUB_ENV" + elif [ -f "/opt/mokoplatform/cli/version_bump.php" ] && [ -f "/opt/mokoplatform/vendor/autoload.php" ]; then + echo "Using pre-installed /opt/mokoplatform (legacy path)" echo "MOKO_CLI=/opt/mokoplatform/cli" >> "$GITHUB_ENV" else if ! command -v composer &> /dev/null; then sudo apt-get update -qq && sudo apt-get install -y -qq php-cli php-mbstring php-xml php-zip php-curl composer >/dev/null 2>&1 fi - rm -rf /tmp/mokoplatform-api + rm -rf /tmp/mokocli git clone --depth 1 --branch main --quiet \ "https://x-access-token:${{ secrets.MOKOGITEA_TOKEN }}@git.mokoconsulting.tech/MokoConsulting/mokoplatform.git" \ - /tmp/mokoplatform-api - cd /tmp/mokoplatform-api && composer install --no-dev --no-interaction --quiet - echo "MOKO_CLI=/tmp/mokoplatform-api/cli" >> "$GITHUB_ENV" + /tmp/mokocli + cd /tmp/mokocli && composer install --no-dev --no-interaction --quiet + echo "MOKO_CLI=/tmp/mokocli/cli" >> "$GITHUB_ENV" fi - name: Bump version diff --git a/cli/platform_detect.php b/cli/platform_detect.php index fe4042d..6f480b3 100644 --- a/cli/platform_detect.php +++ b/cli/platform_detect.php @@ -134,9 +134,9 @@ class PlatformDetectCli extends CliFramework } } - // 5. Platform — is mokoplatform itself or org-config + // 5. Platform — is MokoCLI itself or org-config $repoName = basename($root); - if (in_array($repoName, ['mokoplatform', 'mokogitea-org-config'])) { + if (in_array($repoName, ['mokocli', 'mokoplatform', 'mokogitea-org-config'])) { return 'platform'; } diff --git a/composer.json b/composer.json index 1354d5f..0e1706b 100644 --- a/composer.json +++ b/composer.json @@ -51,7 +51,8 @@ "lib/Enterprise/CliFramework.php" ], "files": [ - "src/functions.php" + "src/functions.php", + "src/aliases.php" ] }, "archive": { diff --git a/mcp/package.json b/mcp/package.json index 4bdc885..6e332f5 100644 --- a/mcp/package.json +++ b/mcp/package.json @@ -5,7 +5,8 @@ "type": "module", "main": "dist/index.js", "bin": { - "moko-platform-mcp": "dist/index.js" + "moko-platform-mcp": "dist/index.js", + "mokocli-mcp": "dist/index.js" }, "scripts": { "build": "tsc", diff --git a/scripts/setup-mokocli-aliases.sh b/scripts/setup-mokocli-aliases.sh new file mode 100644 index 0000000..7f5f815 --- /dev/null +++ b/scripts/setup-mokocli-aliases.sh @@ -0,0 +1,43 @@ +#!/usr/bin/env bash +# MokoCLI — Runner path aliases +# +# Creates symlinks so that both /opt/mokocli and /opt/mokoplatform resolve, +# and both /tmp/mokocli and /tmp/mokoplatform-api resolve. +# +# Run this on CI runners during provisioning or as a workflow step. +# +# Usage: +# sudo bash scripts/setup-mokocli-aliases.sh +# +# Copyright (C) 2026 Moko Consulting +# SPDX-License-Identifier: GPL-3.0-or-later + +set -euo pipefail + +# ── /opt paths (persistent runner installs) ────────────────────────── + +if [ -d "/opt/mokoplatform" ] && [ ! -e "/opt/mokocli" ]; then + ln -s /opt/mokoplatform /opt/mokocli + echo "[mokocli-aliases] Created symlink /opt/mokocli -> /opt/mokoplatform" +elif [ -d "/opt/mokocli" ] && [ ! -e "/opt/mokoplatform" ]; then + ln -s /opt/mokocli /opt/mokoplatform + echo "[mokocli-aliases] Created symlink /opt/mokoplatform -> /opt/mokocli" +elif [ -d "/opt/mokocli" ] && [ -d "/opt/mokoplatform" ]; then + echo "[mokocli-aliases] Both /opt/mokocli and /opt/mokoplatform exist, skipping" +else + echo "[mokocli-aliases] Neither /opt/mokocli nor /opt/mokoplatform found, skipping" +fi + +# ── /tmp paths (ephemeral CI clones) ───────────────────────────────── + +if [ -d "/tmp/mokoplatform-api" ] && [ ! -e "/tmp/mokocli" ]; then + ln -s /tmp/mokoplatform-api /tmp/mokocli + echo "[mokocli-aliases] Created symlink /tmp/mokocli -> /tmp/mokoplatform-api" +fi + +if [ -d "/tmp/mokocli" ] && [ ! -e "/tmp/mokoplatform-api" ]; then + ln -s /tmp/mokocli /tmp/mokoplatform-api + echo "[mokocli-aliases] Created symlink /tmp/mokoplatform-api -> /tmp/mokocli" +fi + +echo "[mokocli-aliases] Done." diff --git a/src/aliases.php b/src/aliases.php new file mode 100644 index 0000000..be90c86 --- /dev/null +++ b/src/aliases.php @@ -0,0 +1,71 @@ + + * + * SPDX-License-Identifier: GPL-3.0-or-later + * + * FILE INFORMATION + * DEFGROUP: MokoCLI.Common + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokoplatform + * PATH: /src/aliases.php + * BRIEF: Forward/backward aliases for the mokoplatform -> MokoCLI rename + * + * This file provides function aliases so that both old and new names work + * during the transition period. It is auto-loaded via composer.json. + * + * @package MokoCLI + */ + +declare(strict_types=1); + +// ───────────────────────────────────────────────────────────────────── +// Forward aliases: new MokoCLI names → existing implementations +// These let code start using the new names immediately. +// ───────────────────────────────────────────────────────────────────── + +if (!function_exists('mokocli_version')) { + /** + * Get the MokoCLI version (alias for mokostandards_version). + */ + function mokocli_version(): string + { + return mokostandards_version(); + } +} + +if (!function_exists('mokocli_root_dir')) { + /** + * Get the MokoCLI root directory (alias for mokostandards_root_dir). + */ + function mokocli_root_dir(): string + { + return mokostandards_root_dir(); + } +} + +// ───────────────────────────────────────────────────────────────────── +// Path resolution: accept both /opt/mokocli and /opt/mokoplatform +// ───────────────────────────────────────────────────────────────────── + +if (!function_exists('mokocli_resolve_install_path')) { + /** + * Resolve the MokoCLI install path, checking both new and legacy locations. + * + * @return string|null The resolved path, or null if not found + */ + function mokocli_resolve_install_path(): ?string + { + // Prefer new name + if (is_dir('/opt/mokocli')) { + return '/opt/mokocli'; + } + // Fall back to legacy name + if (is_dir('/opt/mokoplatform')) { + return '/opt/mokoplatform'; + } + return null; + } +} -- 2.52.0 From 4eb421d6ba08b5fc2530ca0f99e54205a28702cb Mon Sep 17 00:00:00 2001 From: Jonathan Miller Date: Sat, 20 Jun 2026 11:20:27 -0500 Subject: [PATCH 09/21] fix: rename moko-platform to MokoCLI in config files (#263) Update package names, descriptions, and references across all configuration files: composer.json, mcp/package.json, phpcs.xml, issue templates, script registry, and schema templates. --- .mokogitea/ISSUE_TEMPLATE/config.yml | 4 ++-- .script-registry.json | 2 +- composer.json | 4 ++-- mcp/config.example.json | 4 ++-- mcp/package.json | 4 ++-- phpcs.xml | 4 ++-- templates/configs/phpcs.xml | 4 ++-- templates/mokogitea/ISSUE_TEMPLATE/config.yml | 4 ++-- templates/schemas/template-repository-structure.xml | 6 +++--- 9 files changed, 18 insertions(+), 18 deletions(-) diff --git a/.mokogitea/ISSUE_TEMPLATE/config.yml b/.mokogitea/ISSUE_TEMPLATE/config.yml index 06221e2..bbaebdc 100644 --- a/.mokogitea/ISSUE_TEMPLATE/config.yml +++ b/.mokogitea/ISSUE_TEMPLATE/config.yml @@ -7,8 +7,8 @@ contact_links: - name: 💬 Ask a Question url: https://mokoconsulting.tech/ about: Get help or ask questions through our website - - name: 📚 moko-platform Documentation - url: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + - name: 📚 MokoCLI Documentation + url: https://git.mokoconsulting.tech/MokoConsulting/mokocli about: View our coding standards and best practices - name: 🔒 Report a Security Vulnerability url: https://git.mokoconsulting.tech/mokoconsulting-tech/.github-private/security/advisories/new diff --git a/.script-registry.json b/.script-registry.json index 2281cfb..7dad2a8 100644 --- a/.script-registry.json +++ b/.script-registry.json @@ -1,7 +1,7 @@ { "metadata": { "generated_at": "2026-03-10T19:51:42.238134Z", - "repository": "MokoConsulting/moko-platform", + "repository": "MokoConsulting/mokocli", "version": "1.0.0" }, "scripts": [ diff --git a/composer.json b/composer.json index 0e1706b..aae1ed0 100644 --- a/composer.json +++ b/composer.json @@ -1,6 +1,6 @@ { - "name": "mokoconsulting-tech/enterprise", - "description": "moko-platform Enterprise API \u2014 PHP implementation", + "name": "mokoconsulting-tech/mokocli", + "description": "MokoCLI Enterprise API \u2014 PHP implementation", "type": "library", "version": "09.23.00", "license": "GPL-3.0-or-later", diff --git a/mcp/config.example.json b/mcp/config.example.json index 82769cf..339f5a1 100644 --- a/mcp/config.example.json +++ b/mcp/config.example.json @@ -1,6 +1,6 @@ { - "apiPath": "A:/moko-platform", - "standardsPath": "A:/moko-platform", + "apiPath": "A:/mokocli", + "standardsPath": "A:/mokocli", "giteaUrl": "https://git.mokoconsulting.tech", "giteaToken": "your-gitea-api-token" } diff --git a/mcp/package.json b/mcp/package.json index 6e332f5..9f896d1 100644 --- a/mcp/package.json +++ b/mcp/package.json @@ -1,7 +1,7 @@ { - "name": "@mokoconsulting/moko-platform-mcp", + "name": "@mokoconsulting/mokocli-mcp", "version": "1.0.0", - "description": "MCP server for moko-platform governance — validation, compliance, platform detection, definitions browser", + "description": "MCP server for MokoCLI governance — validation, compliance, platform detection, definitions browser", "type": "module", "main": "dist/index.js", "bin": { diff --git a/phpcs.xml b/phpcs.xml index be6b24c..010b763 100644 --- a/phpcs.xml +++ b/phpcs.xml @@ -6,8 +6,8 @@ This file is part of a Moko Consulting project. SPDX-License-Identifier: GPL-3.0-or-later --> - - PHP_CodeSniffer configuration for moko-platform projects + + PHP_CodeSniffer configuration for MokoCLI projects lib diff --git a/templates/configs/phpcs.xml b/templates/configs/phpcs.xml index ddb471f..6f60bc3 100644 --- a/templates/configs/phpcs.xml +++ b/templates/configs/phpcs.xml @@ -6,8 +6,8 @@ This file is part of a Moko Consulting project. SPDX-License-Identifier: GPL-3.0-or-later --> - - PHP_CodeSniffer configuration for moko-platform projects + + PHP_CodeSniffer configuration for MokoCLI projects src diff --git a/templates/mokogitea/ISSUE_TEMPLATE/config.yml b/templates/mokogitea/ISSUE_TEMPLATE/config.yml index 06221e2..bbaebdc 100644 --- a/templates/mokogitea/ISSUE_TEMPLATE/config.yml +++ b/templates/mokogitea/ISSUE_TEMPLATE/config.yml @@ -7,8 +7,8 @@ contact_links: - name: 💬 Ask a Question url: https://mokoconsulting.tech/ about: Get help or ask questions through our website - - name: 📚 moko-platform Documentation - url: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + - name: 📚 MokoCLI Documentation + url: https://git.mokoconsulting.tech/MokoConsulting/mokocli about: View our coding standards and best practices - name: 🔒 Report a Security Vulnerability url: https://git.mokoconsulting.tech/mokoconsulting-tech/.github-private/security/advisories/new diff --git a/templates/schemas/template-repository-structure.xml b/templates/schemas/template-repository-structure.xml index 9e656ca..4c7dba7 100644 --- a/templates/schemas/template-repository-structure.xml +++ b/templates/schemas/template-repository-structure.xml @@ -20,9 +20,9 @@ You should have received a copy of the GNU General Public License along with this program. If not, see . FILE INFORMATION -DEFGROUP: MokoPlatform.Templates.Schemas -INGROUP: MokoPlatform.Templates -REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform +DEFGROUP: MokoCLI.Templates.Schemas +INGROUP: MokoCLI.Templates +REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli PATH: /templates/schemas/template-repository-structure.xml BRIEF: Template for defining custom repository structure schemas --> -- 2.52.0 From 50260b5cb53627e42c9c46675089c85f6ead124c Mon Sep 17 00:00:00 2001 From: Jonathan Miller Date: Sat, 20 Jun 2026 11:22:24 -0500 Subject: [PATCH 10/21] fix: rename MokoPlatform/moko-platform to MokoCLI in all PHP files (#264) Bulk rename across all non-vendor PHP files: - File header comments (DEFGROUP, INGROUP, REPO, @package) - User-Agent strings - Namespace URI constant in MokoStandardsParser - Descriptive comments and docblocks --- automation/bulk_joomla_template.php | 10 +-- automation/bulk_sync.php | 84 +++++++++---------- automation/enrich_manifest_xml.php | 10 +-- automation/enrich_mokostandards_xml.php | 10 +-- automation/migrate_to_gitea.php | 10 +-- automation/push_files.php | 44 +++++----- automation/push_manifest_xml.php | 10 +-- automation/push_mokostandards_xml.php | 10 +-- automation/repo_cleanup.php | 22 ++--- cli/archive_repo.php | 10 +-- cli/audit_query.php | 6 +- cli/badge_update.php | 6 +- cli/branch_rename.php | 6 +- cli/bulk_workflow_push.php | 10 +-- cli/bulk_workflow_trigger.php | 6 +- cli/changelog_promote.php | 6 +- cli/changelog_prune.php | 6 +- cli/client_dashboard.php | 6 +- cli/client_health_check.php | 6 +- cli/client_inventory.php | 6 +- cli/client_provision.php | 6 +- cli/completion.php | 6 +- cli/create_project.php | 14 ++-- cli/create_repo.php | 34 ++++---- cli/deploy_joomla.php | 6 +- cli/dev_branch_reset.php | 6 +- cli/grafana_dashboard.php | 6 +- cli/joomla_build.php | 6 +- cli/joomla_compat_check.php | 6 +- cli/joomla_metadata_validate.php | 6 +- cli/joomla_release.php | 8 +- cli/license_manage.php | 6 +- cli/manifest_element.php | 6 +- cli/manifest_licensing.php | 6 +- cli/manifest_read.php | 8 +- cli/package_build.php | 6 +- cli/platform_detect.php | 6 +- cli/release.php | 10 +-- cli/release_body_update.php | 6 +- cli/release_cascade.php | 6 +- cli/release_create.php | 6 +- cli/release_manage.php | 6 +- cli/release_mirror.php | 10 +-- cli/release_notes.php | 6 +- cli/release_package.php | 6 +- cli/release_promote.php | 6 +- cli/release_publish.php | 6 +- cli/release_validate.php | 6 +- cli/release_verify.php | 6 +- cli/scaffold_client.php | 6 +- cli/sync_rulesets.php | 8 +- cli/theme_lint.php | 6 +- cli/updates_xml_build.php | 6 +- cli/updates_xml_sync.php | 6 +- cli/version_auto_bump.php | 6 +- cli/version_bump.php | 6 +- cli/version_bump_remote.php | 6 +- cli/version_check.php | 6 +- cli/version_read.php | 6 +- cli/version_reset_dev.php | 6 +- cli/version_set_platform.php | 6 +- cli/wiki_sync.php | 14 ++-- cli/workflow_sync.php | 6 +- deploy/backup-before-deploy.php | 6 +- deploy/deploy-dolibarr.php | 6 +- deploy/deploy-joomla.php | 6 +- deploy/deploy-sftp.php | 6 +- deploy/health-check.php | 6 +- deploy/rollback-joomla.php | 6 +- deploy/sync-joomla.php | 6 +- fix/fix_line_endings.php | 6 +- fix/fix_permissions.php | 6 +- fix/fix_tabs.php | 6 +- fix/fix_trailing_spaces.php | 6 +- lib/CliBase.php | 6 +- lib/Common.php | 8 +- lib/Enterprise/AbstractProjectPlugin.php | 8 +- lib/Enterprise/ApiClient.php | 10 +-- lib/Enterprise/AuditLogger.php | 10 +-- lib/Enterprise/CheckpointManager.php | 10 +-- lib/Enterprise/CliFramework.php | 12 +-- lib/Enterprise/Config.php | 10 +-- lib/Enterprise/ConfigValidator.php | 8 +- .../EnterpriseReadinessValidator.php | 6 +- lib/Enterprise/ErrorRecovery.php | 10 +-- lib/Enterprise/FileFixUtility.php | 6 +- lib/Enterprise/GitHubAdapter.php | 8 +- lib/Enterprise/GitPlatformAdapter.php | 10 +-- lib/Enterprise/InputValidator.php | 14 ++-- lib/Enterprise/ManifestReader.php | 8 +- lib/Enterprise/MetricsCollector.php | 12 +-- lib/Enterprise/MokoGiteaAdapter.php | 8 +- lib/Enterprise/MokoStandardsParser.php | 16 ++-- lib/Enterprise/PackageBuilder.php | 6 +- lib/Enterprise/PlatformAdapterFactory.php | 8 +- lib/Enterprise/PluginFactory.php | 8 +- lib/Enterprise/PluginRegistry.php | 8 +- lib/Enterprise/Plugins/ApiPlugin.php | 6 +- .../Plugins/DocumentationPlugin.php | 6 +- lib/Enterprise/Plugins/DolibarrPlugin.php | 6 +- lib/Enterprise/Plugins/GenericPlugin.php | 6 +- lib/Enterprise/Plugins/JoomlaPlugin.php | 6 +- lib/Enterprise/Plugins/McpServerPlugin.php | 6 +- lib/Enterprise/Plugins/MobilePlugin.php | 6 +- lib/Enterprise/Plugins/NodeJsPlugin.php | 6 +- lib/Enterprise/Plugins/PythonPlugin.php | 6 +- lib/Enterprise/Plugins/TerraformPlugin.php | 6 +- lib/Enterprise/Plugins/WordPressPlugin.php | 6 +- lib/Enterprise/ProjectConfigValidator.php | 6 +- lib/Enterprise/ProjectMetricsCollector.php | 6 +- lib/Enterprise/ProjectPluginInterface.php | 8 +- lib/Enterprise/ProjectTypeDetector.php | 6 +- lib/Enterprise/RecoveryError.php | 10 +-- lib/Enterprise/RecoveryManager.php | 10 +-- lib/Enterprise/RepositoryHealthChecker.php | 6 +- lib/Enterprise/RepositorySynchronizer.php | 40 ++++----- lib/Enterprise/RetryHelper.php | 10 +-- lib/Enterprise/SecurityValidator.php | 12 +-- lib/Enterprise/SourceResolver.php | 6 +- lib/Enterprise/SynchronizationException.php | 6 +- lib/Enterprise/TransactionManager.php | 12 +-- lib/Enterprise/UnifiedValidation.php | 12 +-- lib/plugins/Joomla/UpdateXmlGenerator.php | 6 +- maintenance/pin_action_shas.php | 6 +- maintenance/repo_inventory.php | 16 ++-- maintenance/rotate_secrets.php | 14 ++-- maintenance/setup_labels.php | 18 ++-- maintenance/sync_dolibarr_readmes.php | 12 +-- maintenance/update_repo_inventory.php | 8 +- maintenance/update_sha_hashes.php | 6 +- maintenance/update_version_from_readme.php | 10 +-- plugin_health_check.php | 6 +- plugin_list.php | 6 +- plugin_metrics.php | 6 +- plugin_readiness.php | 6 +- plugin_validate.php | 6 +- release/generate_dolibarr_version_txt.php | 6 +- release/generate_joomla_update_xml.php | 8 +- src/functions.php | 16 ++-- templates/scripts/common/CliBase.template.php | 6 +- .../scripts/release/package_dolibarr.php | 6 +- templates/scripts/release/package_joomla.php | 6 +- .../scripts/validate/dolibarr_module.php | 14 ++-- .../scripts/validate/validate_manifest.php | 14 ++-- .../scripts/validate/validate_structure.php | 18 ++-- templates/security/index.php | 6 +- templates/stubs/dolibarr.php | 6 +- templates/stubs/joomla.php | 6 +- templates/web/index.php | 10 +-- tests/Enterprise/GitPlatformAdapterTest.php | 6 +- tests/test_circuit_breaker_handling.php | 6 +- tests/test_enterprise_libraries.php | 10 +-- validate/auto_detect_platform.php | 10 +-- validate/check_changelog.php | 6 +- validate/check_client_theme.php | 6 +- validate/check_composer_deps.php | 8 +- validate/check_dolibarr_module.php | 6 +- validate/check_enterprise_readiness.php | 8 +- validate/check_file_integrity.php | 6 +- validate/check_joomla_manifest.php | 6 +- validate/check_language_structure.php | 6 +- validate/check_license_headers.php | 6 +- validate/check_no_secrets.php | 6 +- validate/check_paths.php | 6 +- validate/check_php_syntax.php | 6 +- validate/check_repo_health.php | 24 +++--- validate/check_structure.php | 6 +- validate/check_tabs.php | 6 +- validate/check_version_consistency.php | 6 +- validate/check_wiki_health.php | 16 ++-- validate/check_xml_wellformed.php | 6 +- validate/scan_drift.php | 10 +-- wrappers/auto_detect_platform.php | 6 +- wrappers/bulk_sync.php | 6 +- wrappers/check_changelog.php | 6 +- wrappers/check_dolibarr_module.php | 6 +- wrappers/check_enterprise_readiness.php | 6 +- wrappers/check_joomla_manifest.php | 6 +- wrappers/check_language_structure.php | 6 +- wrappers/check_license_headers.php | 6 +- wrappers/check_no_secrets.php | 6 +- wrappers/check_paths.php | 6 +- wrappers/check_php_syntax.php | 6 +- wrappers/check_repo_health.php | 6 +- wrappers/check_structure.php | 6 +- wrappers/check_tabs.php | 6 +- wrappers/check_version_consistency.php | 6 +- wrappers/check_xml_wellformed.php | 6 +- wrappers/deploy_sftp.php | 6 +- wrappers/fix_line_endings.php | 6 +- wrappers/fix_permissions.php | 6 +- wrappers/fix_tabs.php | 6 +- wrappers/fix_trailing_spaces.php | 6 +- wrappers/gen_wrappers.php | 12 +-- wrappers/pin_action_shas.php | 6 +- wrappers/plugin_health_check.php | 6 +- wrappers/plugin_list.php | 6 +- wrappers/plugin_metrics.php | 6 +- wrappers/plugin_readiness.php | 6 +- wrappers/plugin_validate.php | 6 +- wrappers/scan_drift.php | 6 +- wrappers/setup_labels.php | 6 +- wrappers/sync_dolibarr_readmes.php | 6 +- wrappers/update_sha_hashes.php | 6 +- wrappers/update_version_from_readme.php | 6 +- 205 files changed, 863 insertions(+), 863 deletions(-) diff --git a/automation/bulk_joomla_template.php b/automation/bulk_joomla_template.php index 30c9c2c..b0846ef 100644 --- a/automation/bulk_joomla_template.php +++ b/automation/bulk_joomla_template.php @@ -9,9 +9,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Automation - * INGROUP: MokoPlatform.Scripts - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Automation + * INGROUP: MokoCLI.Scripts + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /automation/bulk_joomla_template.php * BRIEF: Bulk scaffold and sync Joomla template repositories * @@ -42,7 +42,7 @@ use MokoEnterprise\{ * * Provides three operations for Joomla template projects: * --scaffold: Create a new template repository with the full directory structure - * --sync: Push moko-platform files to existing template repositories + * --sync: Push MokoCLI files to existing template repositories * --list: List all repositories tagged as joomla-template * * Works with both GitHub and Gitea via the PlatformAdapterFactory. @@ -318,7 +318,7 @@ class BulkJoomlaTemplate extends CliFramework $name, $path, $content, - "chore: update {$path} from moko-platform", + "chore: update {$path} from MokoCLI", $existingSha, $branch ); diff --git a/automation/bulk_sync.php b/automation/bulk_sync.php index ed99ee6..c251f51 100755 --- a/automation/bulk_sync.php +++ b/automation/bulk_sync.php @@ -9,9 +9,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Automation - * INGROUP: MokoPlatform.Scripts - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Automation + * INGROUP: MokoCLI.Scripts + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /automation/bulk_sync.php * BRIEF: Enterprise-grade bulk repository synchronization */ @@ -42,7 +42,7 @@ use MokoEnterprise\{ /** * Bulk Repository Synchronization Tool * - * Synchronizes moko-platform files across multiple repositories using + * Synchronizes MokoCLI files across multiple repositories using * the Enterprise library for robust, audited operations. */ class BulkSync extends CliFramework @@ -95,7 +95,7 @@ class BulkSync extends CliFramework */ protected function run(): int { - $this->log("🚀 moko-platform Bulk Synchronization v" . self::VERSION, 'INFO'); + $this->log("🚀 MokoCLI Bulk Synchronization v" . self::VERSION, 'INFO'); // Initialize enterprise components if (!$this->initializeComponents()) { @@ -180,7 +180,7 @@ class BulkSync extends CliFramework $results['health'] = $this->runHealthChecksAll($org, $repositories); } - // Create/update tracking issue in moko-platform + // Create/update tracking issue in MokoCLI $this->createSyncIssue($org, $results); // Create/update a failure issue when any repos failed @@ -244,7 +244,7 @@ class BulkSync extends CliFramework * Filter repositories based on include/exclude lists */ /** Repositories that are permanently excluded from bulk sync. */ - private const ALWAYS_EXCLUDE = ['moko-platform', '.github-private']; + private const ALWAYS_EXCLUDE = ['MokoCLI', '.github-private']; private function filterRepositories(array $repositories, array $include, array $exclude): array { @@ -426,7 +426,7 @@ class BulkSync extends CliFramework $this->log("", 'ERROR'); $this->log("Required Implementation:", 'ERROR'); $this->log(" 1. Clone/fetch target repository", 'ERROR'); - $this->log(" 2. Apply file updates based on moko-platform configuration", 'ERROR'); + $this->log(" 2. Apply file updates based on MokoCLI configuration", 'ERROR'); $this->log(" 3. Create pull request with changes", 'ERROR'); $this->log(" 4. Handle merge conflicts and validation", 'ERROR'); $this->log("", 'ERROR'); @@ -837,7 +837,7 @@ class BulkSync extends CliFramework } /** - * Ensure all standard moko-platform labels exist on a target repository. + * Ensure all standard MokoCLI labels exist on a target repository. * * Fetches existing labels first (GET) and only POSTs the ones that are * missing. This avoids the 422 "already exists" responses that would @@ -872,7 +872,7 @@ class BulkSync extends CliFramework // Workflow / Process ['automation', '8B4513', 'Automated processes or scripts'], - ['moko-platform', 'B60205', 'moko-platform compliance'], + ['MokoCLI', 'B60205', 'MokoCLI compliance'], ['needs-review', 'FBCA04', 'Awaiting code review'], ['work-in-progress', 'D93F0B', 'Work in progress, not ready for merge'], ['breaking-change', 'D73A4A', 'Breaking API or functionality change'], @@ -912,8 +912,8 @@ class BulkSync extends CliFramework ['health: poor', 'FF6B6B', 'Health score below 50'], // Sync / Automation (used by bulk_sync, scan_drift, check_repo_health) - ['standards-update', 'B60205', 'moko-platform sync update'], - ['standards-drift', 'FBCA04', 'Repository drifted from moko-platform'], + ['standards-update', 'B60205', 'MokoCLI sync update'], + ['standards-drift', 'FBCA04', 'Repository drifted from MokoCLI'], ['sync-report', '0075CA', 'Bulk sync run report'], ['sync-failure', 'D73A4A', 'Bulk sync failure requiring attention'], ['push-failure', 'D73A4A', 'File push failure requiring attention'], @@ -925,10 +925,10 @@ class BulkSync extends CliFramework ['type: version', '0E8A16', 'Version-related change'], ]; - // Quick check: if the repo already has the 'moko-platform' label, it was + // Quick check: if the repo already has the 'MokoCLI' label, it was // provisioned previously — skip the expensive full label provisioning. try { - $probe = $this->api->get("/repos/{$org}/{$repo}/labels/moko-platform"); + $probe = $this->api->get("/repos/{$org}/{$repo}/labels/MokoCLI"); if (!empty($probe['name'])) { return; // already provisioned } @@ -1024,7 +1024,7 @@ class BulkSync extends CliFramework */ private function updateOpenBranches(string $org, string $repo): void { - $syncBranchPrefix = 'chore/sync-moko-platform-'; + $syncBranchPrefix = 'chore/sync-MokoCLI-'; try { $defaultBranch = 'main'; @@ -1055,7 +1055,7 @@ class BulkSync extends CliFramework $this->api->post("/repos/{$org}/{$repo}/merges", [ 'base' => $branch, 'head' => $defaultBranch, - 'commit_message' => "chore: merge {$defaultBranch} into {$branch} (moko-platform sync)", + 'commit_message' => "chore: merge {$defaultBranch} into {$branch} (MokoCLI sync)", ]); $this->log(" 🔀 Merged {$defaultBranch} → {$branch} (PR #{$prNum})", 'INFO'); } catch (\Exception $e) { @@ -1076,7 +1076,7 @@ class BulkSync extends CliFramework /** * Records which sync run touched the repo, the PR number, and the - * moko-platform version that was applied — giving each repo a clear audit + * MokoCLI version that was applied — giving each repo a clear audit * trail of what was changed and why. */ /** @@ -1119,16 +1119,16 @@ class BulkSync extends CliFramework $minor = self::VERSION_MINOR; $force = isset($this->options['force']) ? ' *(--force)*' : ''; $prLink = $this->adapter->getPullRequestWebUrl($org, $repo, $prNumber); - $source = $this->adapter->getRepoWebUrl($org, 'moko-platform'); - $branchName = 'chore/sync-moko-platform-v' . $minor; + $source = $this->adapter->getRepoWebUrl($org, 'MokoCLI'); + $branchName = 'chore/sync-MokoCLI-v' . $minor; $branchLink = $this->adapter->getBranchWebUrl($org, $repo, $branchName); - $title = "chore: moko-platform v{$minor} sync tracking"; + $title = "chore: MokoCLI v{$minor} sync tracking"; $body = <<resolveLabelIds($org, $repo, $labelNames); try { @@ -1213,7 +1213,7 @@ class BulkSync extends CliFramework } /** - * Create a tracking issue in moko-platform for this sync run. + * Create a tracking issue in MokoCLI for this sync run. */ private function createSyncIssue(string $org, array $results): void { @@ -1232,7 +1232,7 @@ class BulkSync extends CliFramework $issues = $results['issues'] ?? []; // Stable title — no timestamp so repeated runs update a single issue - $title = "sync: moko-platform v" . self::VERSION_MINOR . " bulk sync report"; + $title = "sync: MokoCLI v" . self::VERSION_MINOR . " bulk sync report"; $protection = $results['protection'] ?? []; $hasProtect = !empty($protection); @@ -1281,7 +1281,7 @@ class BulkSync extends CliFramework : "|---|---|---|---|"; $body = <<api->get("/repos/{$org}/moko-platform/issues", [ + $existing = $this->api->get("/repos/{$org}/MokoCLI/issues", [ 'labels' => 'sync-report', 'state' => 'all', 'per_page' => 1, @@ -1309,8 +1309,8 @@ class BulkSync extends CliFramework 'direction' => 'desc', ]); - $labelNames = ['sync-report', 'moko-platform', 'type: chore', 'automation']; - $labels = $this->resolveLabelIds($org, 'moko-platform', $labelNames); + $labelNames = ['sync-report', 'MokoCLI', 'type: chore', 'automation']; + $labels = $this->resolveLabelIds($org, 'MokoCLI', $labelNames); $existing = array_values($existing); if (!empty($existing) && isset($existing[0]['number'])) { @@ -1319,22 +1319,22 @@ class BulkSync extends CliFramework if (($existing[0]['state'] ?? 'open') === 'closed') { $patch['state'] = 'open'; } - $this->api->patch("/repos/{$org}/moko-platform/issues/{$issueNumber}", $patch); + $this->api->patch("/repos/{$org}/MokoCLI/issues/{$issueNumber}", $patch); try { - $this->api->post("/repos/{$org}/moko-platform/issues/{$issueNumber}/labels", ['labels' => $labels]); + $this->api->post("/repos/{$org}/MokoCLI/issues/{$issueNumber}/labels", ['labels' => $labels]); } catch (\Exception $le) { /* non-fatal */ } - $this->log("📋 Sync report issue updated: {$org}/moko-platform#{$issueNumber}", 'INFO'); + $this->log("📋 Sync report issue updated: {$org}/MokoCLI#{$issueNumber}", 'INFO'); } else { - $issue = $this->api->post("/repos/{$org}/moko-platform/issues", [ + $issue = $this->api->post("/repos/{$org}/MokoCLI/issues", [ 'title' => $title, 'body' => $body, 'labels' => $labels, 'assignees' => ['jmiller'], ]); $issueNumber = $issue['number'] ?? '?'; - $this->log("📋 Sync report issue created: {$org}/moko-platform#{$issueNumber}", 'INFO'); + $this->log("📋 Sync report issue created: {$org}/MokoCLI#{$issueNumber}", 'INFO'); } } catch (\Exception $e) { $this->log("⚠️ Failed to create/update sync report issue: " . $e->getMessage(), 'WARN'); @@ -1342,7 +1342,7 @@ class BulkSync extends CliFramework } /** - * Create or update a failure issue in moko-platform when repos fail to sync. + * Create or update a failure issue in MokoCLI when repos fail to sync. * Uses the 'sync-failure' label so it is distinct from the run-report issue. * Reopens a closed issue rather than creating a duplicate. */ @@ -1388,7 +1388,7 @@ class BulkSync extends CliFramework $body = preg_replace('/^ /m', '', $body); try { - $existing = $this->api->get("/repos/{$org}/moko-platform/issues", [ + $existing = $this->api->get("/repos/{$org}/MokoCLI/issues", [ 'labels' => 'sync-failure', 'state' => 'all', 'per_page' => 1, @@ -1403,17 +1403,17 @@ class BulkSync extends CliFramework if (($existing[0]['state'] ?? 'open') === 'closed') { $patch['state'] = 'open'; } - $this->api->patch("/repos/{$org}/moko-platform/issues/{$num}", $patch); - $this->log("🚨 Failure issue #{$num} updated: {$org}/moko-platform#{$num}", 'WARN'); + $this->api->patch("/repos/{$org}/MokoCLI/issues/{$num}", $patch); + $this->log("🚨 Failure issue #{$num} updated: {$org}/MokoCLI#{$num}", 'WARN'); } else { - $issue = $this->api->post("/repos/{$org}/moko-platform/issues", [ + $issue = $this->api->post("/repos/{$org}/MokoCLI/issues", [ 'title' => $title, 'body' => $body, - 'labels' => $this->resolveLabelIds($org, 'moko-platform', ['sync-failure']), + 'labels' => $this->resolveLabelIds($org, 'MokoCLI', ['sync-failure']), 'assignees' => ['jmiller'], ]); $num = $issue['number'] ?? '?'; - $this->log("🚨 Failure issue created: {$org}/moko-platform#{$num}", 'WARN'); + $this->log("🚨 Failure issue created: {$org}/MokoCLI#{$num}", 'WARN'); } } catch (\Exception $e) { $this->log("⚠️ Could not create/update failure issue: " . $e->getMessage(), 'WARN'); diff --git a/automation/enrich_manifest_xml.php b/automation/enrich_manifest_xml.php index 26c6afb..3039c62 100644 --- a/automation/enrich_manifest_xml.php +++ b/automation/enrich_manifest_xml.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Automation - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Automation + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /automation/enrich_manifest_xml.php * BRIEF: Enrich XML manifests with repo-specific build and deploy details * @@ -46,7 +46,7 @@ class EnrichManifestXmlCli extends CliFramework $parser = new MokoStandardsParser(); $tmpBase = sys_get_temp_dir() . '/moko-enrich-' . getmypid(); - echo "=== moko-platform XML Manifest Enrichment ===\n"; + echo "=== MokoCLI XML Manifest Enrichment ===\n"; echo "Mode: " . ($this->dryRun ? "DRY RUN" : "LIVE") . "\n"; if (!empty($skipRepos)) { echo "Skipping: " . implode(', ', $skipRepos) . "\n"; @@ -97,7 +97,7 @@ class EnrichManifestXmlCli extends CliFramework } $manifestPath = "{$workDir}/.mokogitea/manifest.xml"; - if (!file_exists($manifestPath) || !str_contains(file_get_contents($manifestPath), 'rmTree($workDir); diff --git a/automation/enrich_mokostandards_xml.php b/automation/enrich_mokostandards_xml.php index 43dc8a6..854bca5 100644 --- a/automation/enrich_mokostandards_xml.php +++ b/automation/enrich_mokostandards_xml.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Automation - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Automation + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /automation/enrich_mokostandards_xml.php * BRIEF: Enrich XML manifests with repo-specific build and deploy details * @@ -46,7 +46,7 @@ class EnrichMokostandardsXmlCli extends CliFramework $parser = new MokoStandardsParser(); $tmpBase = sys_get_temp_dir() . '/moko-enrich-' . getmypid(); - echo "=== moko-platform XML Manifest Enrichment ===\n"; + echo "=== MokoCLI XML Manifest Enrichment ===\n"; echo "Mode: " . ($this->dryRun ? "DRY RUN" : "LIVE") . "\n"; if (!empty($skipRepos)) { echo "Skipping: " . implode(', ', $skipRepos) . "\n"; @@ -97,7 +97,7 @@ class EnrichMokostandardsXmlCli extends CliFramework } $manifestPath = "{$workDir}/.mokogitea/manifest.xml"; - if (!file_exists($manifestPath) || !str_contains(file_get_contents($manifestPath), 'rmTree($workDir); diff --git a/automation/migrate_to_gitea.php b/automation/migrate_to_gitea.php index d2f1c51..c2497bf 100644 --- a/automation/migrate_to_gitea.php +++ b/automation/migrate_to_gitea.php @@ -8,16 +8,16 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Automation - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Automation + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /automation/migrate_to_gitea.php * BRIEF: Migrate repositories from GitHub to self-hosted Gitea instance * * USAGE * php automation/migrate_to_gitea.php --dry-run * php automation/migrate_to_gitea.php --repos MokoCRM MokoDoliMods - * php automation/migrate_to_gitea.php --exclude moko-platform --skip-archived + * php automation/migrate_to_gitea.php --exclude MokoCLI --skip-archived * php automation/migrate_to_gitea.php --resume */ @@ -278,7 +278,7 @@ class MigrateToGitea extends CliFramework try { $this->gitea->createIssue( $giteaOrg, - 'moko-platform', + 'MokoCLI', 'chore: GitHub → Gitea migration report — ' . count($results['migrated']) . ' repos migrated', $report, ['labels' => ['automation', 'type: chore']] diff --git a/automation/push_files.php b/automation/push_files.php index f6cdc19..b84b9e2 100644 --- a/automation/push_files.php +++ b/automation/push_files.php @@ -9,9 +9,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Automation - * INGROUP: MokoPlatform.Scripts - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Automation + * INGROUP: MokoCLI.Scripts + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /automation/push_files.php * BRIEF: Push one or more specific files to one or more remote repositories */ @@ -35,7 +35,7 @@ use MokoEnterprise\{ /** * Targeted File Push Tool * - * Pushes one or more specific files from moko-platform templates to one or + * Pushes one or more specific files from MokoCLI templates to one or * more remote repositories — without running a full sync. * * Files are specified by their destination path as they appear in the target @@ -81,7 +81,7 @@ class PushFiles extends CliFramework */ protected function run(): int { - $this->log('📦 moko-platform File Push v' . self::VERSION, 'INFO'); + $this->log('📦 MokoCLI File Push v' . self::VERSION, 'INFO'); if (!$this->initializeComponents()) { return 1; @@ -337,7 +337,7 @@ class PushFiles extends CliFramework $prNumber = null; if (!$direct) { - $prTitle = "chore: push " . count($entries) . " file(s) from moko-platform"; + $prTitle = "chore: push " . count($entries) . " file(s) from MokoCLI"; $prBody = $this->buildPRBody($entries); $pr = $this->adapter->createPullRequest( $org, @@ -414,7 +414,7 @@ class PushFiles extends CliFramework $message = !empty($customMessage) ? $customMessage - : "chore: update {$destPath} from moko-platform"; + : "chore: update {$destPath} from MokoCLI"; // Fetch existing file SHA (needed for updates) $existingSha = null; @@ -457,9 +457,9 @@ class PushFiles extends CliFramework ): void { $now = gmdate('Y-m-d H:i:s') . ' UTC'; $version = self::VERSION; - $source = $this->adapter->getRepoWebUrl($org, 'moko-platform'); + $source = $this->adapter->getRepoWebUrl($org, 'MokoCLI'); - $title = "chore: moko-platform file push tracking"; + $title = "chore: MokoCLI file push tracking"; $deliveryLine = $prNumber !== null ? "| **Pull request** | [#{$prNumber}](" . $this->adapter->getPullRequestWebUrl($org, $repo, $prNumber) . ") |" @@ -471,9 +471,9 @@ class PushFiles extends CliFramework )); $body = <<api->get("/repos/{$org}/{$repo}/issues", [ @@ -550,7 +550,7 @@ class PushFiles extends CliFramework } /** - * Create or update a failure issue in moko-platform when repos fail to receive files. + * Create or update a failure issue in MokoCLI when repos fail to receive files. * Uses the 'push-failure' label. Reopens a closed issue rather than creating a duplicate. */ private function createFailureIssue(string $org, array $results): void @@ -598,7 +598,7 @@ class PushFiles extends CliFramework $body = preg_replace('/^ /m', '', $body); try { - $existing = $this->api->get("/repos/{$org}/moko-platform/issues", [ + $existing = $this->api->get("/repos/{$org}/MokoCLI/issues", [ 'labels' => 'push-failure', 'state' => 'all', 'per_page' => 1, @@ -613,17 +613,17 @@ class PushFiles extends CliFramework if (($existing[0]['state'] ?? 'open') === 'closed') { $patch['state'] = 'open'; } - $this->api->patch("/repos/{$org}/moko-platform/issues/{$num}", $patch); - $this->log("🚨 Failure issue #{$num} updated: {$org}/moko-platform#{$num}", 'WARN'); + $this->api->patch("/repos/{$org}/MokoCLI/issues/{$num}", $patch); + $this->log("🚨 Failure issue #{$num} updated: {$org}/MokoCLI#{$num}", 'WARN'); } else { - $issue = $this->api->post("/repos/{$org}/moko-platform/issues", [ + $issue = $this->api->post("/repos/{$org}/MokoCLI/issues", [ 'title' => $title, 'body' => $body, 'labels' => ['push-failure'], 'assignees' => ['jmiller'], ]); $num = $issue['number'] ?? '?'; - $this->log("🚨 Failure issue created: {$org}/moko-platform#{$num}", 'WARN'); + $this->log("🚨 Failure issue created: {$org}/MokoCLI#{$num}", 'WARN'); } } catch (\Exception $e) { $this->log("⚠️ Could not create/update failure issue: " . $e->getMessage(), 'WARN'); @@ -638,14 +638,14 @@ class PushFiles extends CliFramework private function buildPRBody(array $entries): string { $now = gmdate('Y-m-d H:i:s') . ' UTC'; - $lines = ["## moko-platform File Push\n", "**Pushed:** {$now}\n", '### Files\n']; + $lines = ["## MokoCLI File Push\n", "**Pushed:** {$now}\n", '### Files\n']; foreach ($entries as $entry) { $lines[] = "- `{$entry['destination']}`"; } - $sourceUrl = $this->adapter->getRepoWebUrl(self::DEFAULT_ORG, 'moko-platform'); - $lines[] = "\n---\n*Generated by [moko-platform]({$sourceUrl}) `push_files.php`*"; + $sourceUrl = $this->adapter->getRepoWebUrl(self::DEFAULT_ORG, 'MokoCLI'); + $lines[] = "\n---\n*Generated by [MokoCLI]({$sourceUrl}) `push_files.php`*"; return implode("\n", $lines); } diff --git a/automation/push_manifest_xml.php b/automation/push_manifest_xml.php index 988755a..815395b 100644 --- a/automation/push_manifest_xml.php +++ b/automation/push_manifest_xml.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Automation - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Automation + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /automation/push_manifest_xml.php * BRIEF: Push XML manifests to all governed repositories */ @@ -47,7 +47,7 @@ class PushManifestXmlCli extends CliFramework $parser = new MokoStandardsParser(); $tmpBase = sys_get_temp_dir() . '/moko-manifest-push-' . getmypid(); - echo "=== moko-platform XML Manifest Push ===\n"; + echo "=== MokoCLI XML Manifest Push ===\n"; echo "Org: {$giteaOrg}\n"; echo "Mode: " . ($this->dryRun ? "DRY RUN" : "LIVE") . "\n"; if ($repoFilter) { @@ -125,7 +125,7 @@ class PushManifestXmlCli extends CliFramework // Check if already XML and up-to-date $manifestPath = "{$workDir}/.mokogitea/manifest.xml"; - $existingIsXml = file_exists($manifestPath) && str_contains(file_get_contents($manifestPath), 'extractPlatform(file_get_contents($manifestPath)); if ($existingPlatform === $platform) { diff --git a/automation/push_mokostandards_xml.php b/automation/push_mokostandards_xml.php index 09150b4..19fa8df 100644 --- a/automation/push_mokostandards_xml.php +++ b/automation/push_mokostandards_xml.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Automation - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Automation + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /automation/push_mokostandards_xml.php * BRIEF: Push XML manifests to all governed repositories */ @@ -47,7 +47,7 @@ class PushMokostandardsXmlCli extends CliFramework $parser = new MokoStandardsParser(); $tmpBase = sys_get_temp_dir() . '/moko-manifest-push-' . getmypid(); - echo "=== moko-platform XML Manifest Push ===\n"; + echo "=== MokoCLI XML Manifest Push ===\n"; echo "Org: {$giteaOrg}\n"; echo "Mode: " . ($this->dryRun ? "DRY RUN" : "LIVE") . "\n"; if ($repoFilter) { @@ -125,7 +125,7 @@ class PushMokostandardsXmlCli extends CliFramework // Check if already XML and up-to-date $manifestPath = "{$workDir}/.mokogitea/manifest.xml"; - $existingIsXml = file_exists($manifestPath) && str_contains(file_get_contents($manifestPath), 'extractPlatform(file_get_contents($manifestPath)); if ($existingPlatform === $platform) { diff --git a/automation/repo_cleanup.php b/automation/repo_cleanup.php index 0e223bd..645739e 100644 --- a/automation/repo_cleanup.php +++ b/automation/repo_cleanup.php @@ -9,9 +9,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Automation - * INGROUP: MokoPlatform.Scripts - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Automation + * INGROUP: MokoCLI.Scripts + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /automation/repo_cleanup.php * BRIEF: Enterprise repository cleanup — branches, PRs, issues, workflows, labels, logs */ @@ -39,14 +39,14 @@ use MokoEnterprise\{ApiClient, AuditLogger, CliFramework, Config, GitPlatformAda class RepoCleanup extends CliFramework { private const VERSION = '09.23.00'; - private const SYNC_PREFIX = 'chore/sync-moko-platform-'; - private const CURRENT_BRANCH = 'chore/sync-moko-platform-v04.02.00'; + private const SYNC_PREFIX = 'chore/sync-MokoCLI-'; + private const CURRENT_BRANCH = 'chore/sync-MokoCLI-v04.02.00'; /** Workflow files that have been retired and should be deleted from governed repos. */ private const RETIRED_WORKFLOWS = [ 'build.yml', 'code-quality.yml', 'release-cycle.yml', 'release-pipeline.yml', 'branch-cleanup.yml', 'auto-update-changelog.yml', 'enterprise-issue-manager.yml', - 'flush-actions-cache.yml', 'moko-platform-script-runner.yml', 'unified-ci.yml', + 'flush-actions-cache.yml', 'MokoCLI-script-runner.yml', 'unified-ci.yml', 'unified-platform-testing.yml', 'reusable-build.yml', 'reusable-ci-validation.yml', 'reusable-deploy.yml', 'reusable-php-quality.yml', 'reusable-platform-testing.yml', 'reusable-project-detector.yml', 'reusable-release.yml', 'reusable-script-executor.yml', @@ -98,7 +98,7 @@ class RepoCleanup extends CliFramework } - $this->logMsg("🧹 moko-platform Repository Cleanup v" . self::VERSION); + $this->logMsg("🧹 MokoCLI Repository Cleanup v" . self::VERSION); $this->logMsg("Organization: {$org}"); $this->logMsg("Current sync branch: " . self::CURRENT_BRANCH); if ($this->dryRun) { @@ -225,7 +225,7 @@ class RepoCleanup extends CliFramework } $allRepos = $this->adapter->listOrgRepos($org, $skipArchived); - return array_filter($allRepos, fn($r) => !in_array($r['name'], ['moko-platform', '.github-private'], true)); + return array_filter($allRepos, fn($r) => !in_array($r['name'], ['MokoCLI', '.github-private'], true)); } // ─── Cleanup operations ────────────────────────────────────────────── @@ -463,9 +463,9 @@ class RepoCleanup extends CliFramework private function checkLabels(string $org, string $repo, array &$results): void { try { - $this->api->get("/repos/{$org}/{$repo}/labels/moko-platform"); + $this->api->get("/repos/{$org}/{$repo}/labels/MokoCLI"); } catch (\Exception $e) { - $this->logMsg(" ⚠️ Missing 'moko-platform' label"); + $this->logMsg(" ⚠️ Missing 'MokoCLI' label"); $results['labels_missing']++; $this->api->resetCircuitBreaker(); } @@ -479,7 +479,7 @@ class RepoCleanup extends CliFramework if (preg_match('/^\s*VERSION:\s*(\d{2}\.\d{2}\.\d{2})/m', $content, $m)) { $version = $m[1]; - // Check manifest.xml for the tracked moko-platform version + // Check manifest.xml for the tracked MokoCLI version try { $mokoFile = $this->api->get("/repos/{$org}/{$repo}/contents/.mokogitea/manifest.xml"); $mokoContent = base64_decode($mokoFile['content'] ?? ''); diff --git a/cli/archive_repo.php b/cli/archive_repo.php index 8b262c6..b64f9b5 100644 --- a/cli/archive_repo.php +++ b/cli/archive_repo.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/archive_repo.php * BRIEF: Gracefully retire a governed repository — archive, close issues/PRs, remove sync def */ @@ -135,7 +135,7 @@ class ArchiveRepoCli extends CliFramework try { $issue = $adapter->createIssue( $org, - 'moko-platform', + 'MokoCLI', "chore: archived repository {$repoName}", "## Repository Archived\n\n" . "**Repository:** `{$org}/{$repoName}`\n" @@ -150,7 +150,7 @@ class ArchiveRepoCli extends CliFramework ] ); if (isset($issue['number'])) { - echo " Archival record: moko-platform#{$issue['number']}\n"; + echo " Archival record: MokoCLI#{$issue['number']}\n"; } } catch (\Exception $e) { echo " Warning: could not create archival record: " . $e->getMessage() . "\n"; diff --git a/cli/audit_query.php b/cli/audit_query.php index 57bb875..8bfe715 100644 --- a/cli/audit_query.php +++ b/cli/audit_query.php @@ -14,9 +14,9 @@ * (at your option) any later version. * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.CLI - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.CLI + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/audit_query.php * BRIEF: Search, filter, and export audit logs */ diff --git a/cli/badge_update.php b/cli/badge_update.php index d7d529b..e385c89 100644 --- a/cli/badge_update.php +++ b/cli/badge_update.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/badge_update.php * BRIEF: Update [VERSION: XX.XX.XX] badges in all markdown files */ diff --git a/cli/branch_rename.php b/cli/branch_rename.php index a3c40cd..8b9818d 100644 --- a/cli/branch_rename.php +++ b/cli/branch_rename.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/branch_rename.php * VERSION: 09.25.05 * BRIEF: Rename a git branch via Gitea API (create new, update PR, delete old) diff --git a/cli/bulk_workflow_push.php b/cli/bulk_workflow_push.php index d0a28e7..82a80a0 100644 --- a/cli/bulk_workflow_push.php +++ b/cli/bulk_workflow_push.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/bulk_workflow_push.php * VERSION: 09.25.05 * BRIEF: Push a workflow file to all governed repos via the Gitea Contents API @@ -154,7 +154,7 @@ class BulkWorkflowPushCli extends CliFramework 'content' => $encodedContent, 'sha' => $remoteSha, 'message' => "chore: sync {$destPath} " - . "from moko-platform [skip ci]", + . "from MokoCLI [skip ci]", 'branch' => $branch, ]); @@ -184,7 +184,7 @@ class BulkWorkflowPushCli extends CliFramework $payload = json_encode([ 'content' => $encodedContent, 'message' => "chore: add {$destPath} " - . "from moko-platform [skip ci]", + . "from MokoCLI [skip ci]", 'branch' => $branch, ]); diff --git a/cli/bulk_workflow_trigger.php b/cli/bulk_workflow_trigger.php index 87400eb..57f7040 100644 --- a/cli/bulk_workflow_trigger.php +++ b/cli/bulk_workflow_trigger.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/bulk_workflow_trigger.php * VERSION: 09.25.05 * BRIEF: Trigger a workflow across multiple repos at once diff --git a/cli/changelog_promote.php b/cli/changelog_promote.php index e5dc3db..d952950 100644 --- a/cli/changelog_promote.php +++ b/cli/changelog_promote.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/changelog_promote.php * BRIEF: Promote [Unreleased] section in CHANGELOG.md to a versioned entry */ diff --git a/cli/changelog_prune.php b/cli/changelog_prune.php index d6fe85d..318fc3d 100644 --- a/cli/changelog_prune.php +++ b/cli/changelog_prune.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/changelog_prune.php * BRIEF: Prune old CHANGELOG.md entries — keeps [Unreleased] + last N releases */ diff --git a/cli/client_dashboard.php b/cli/client_dashboard.php index e64d235..55187f8 100644 --- a/cli/client_dashboard.php +++ b/cli/client_dashboard.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/client_dashboard.php * VERSION: 09.25.05 * BRIEF: Generate unified client dashboard HTML diff --git a/cli/client_health_check.php b/cli/client_health_check.php index ac7145d..d8cec51 100644 --- a/cli/client_health_check.php +++ b/cli/client_health_check.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/client_health_check.php * BRIEF: Verify a client site's update server, installed version, and release availability */ diff --git a/cli/client_inventory.php b/cli/client_inventory.php index 0b3ce91..46778f7 100644 --- a/cli/client_inventory.php +++ b/cli/client_inventory.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/client_inventory.php * VERSION: 09.25.05 * BRIEF: Discover and list all client-waas repos with their server configuration status diff --git a/cli/client_provision.php b/cli/client_provision.php index 6e0ec08..ff88290 100644 --- a/cli/client_provision.php +++ b/cli/client_provision.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/client_provision.php * VERSION: 09.25.05 * BRIEF: Provision a new client environment end-to-end diff --git a/cli/completion.php b/cli/completion.php index 5f3ad4d..d8354ca 100644 --- a/cli/completion.php +++ b/cli/completion.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/completion.php * BRIEF: Generate bash/zsh tab completion scripts for bin/moko */ diff --git a/cli/create_project.php b/cli/create_project.php index e57363f..5440801 100644 --- a/cli/create_project.php +++ b/cli/create_project.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/create_project.php * BRIEF: Create baseline GitHub Projects for repositories with standard fields and views */ @@ -24,7 +24,7 @@ use MokoEnterprise\CliFramework; class CreateProjectCli extends CliFramework { /** @var string[] */ - private array $ALWAYS_EXCLUDE = ['moko-platform', '.github-private']; + private array $ALWAYS_EXCLUDE = ['MokoCLI', '.github-private']; /** @var array */ private array $PLATFORM_TO_TYPE = [ @@ -183,7 +183,7 @@ class CreateProjectCli extends CliFramework CURLOPT_HTTPHEADER => [ 'Authorization: bearer ' . $token, 'Content-Type: application/json', - 'User-Agent: moko-platform-CreateProject', + 'User-Agent: MokoCLI-CreateProject', ], ]); $body = (string) curl_exec($ch); @@ -422,14 +422,14 @@ class CreateProjectCli extends CliFramework updateProjectV2(input: { projectId: $projectId, shortDescription: $shortDescription, - readme: "Managed by moko-platform. Run `php cli/create_project.php` to regenerate." + readme: "Managed by MokoCLI. Run `php cli/create_project.php` to regenerate." }) { projectV2 { id } } }', [ 'projectId' => $projectId, - 'shortDescription' => "Standard project board for {$repo}. Auto-created by moko-platform.", + 'shortDescription' => "Standard project board for {$repo}. Auto-created by MokoCLI.", ], $token ); diff --git a/cli/create_repo.php b/cli/create_repo.php index 38add2b..b24787d 100644 --- a/cli/create_repo.php +++ b/cli/create_repo.php @@ -8,11 +8,11 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/create_repo.php - * BRIEF: Scaffold a new governed repository with full moko-platform baseline + * BRIEF: Scaffold a new governed repository with full MokoCLI baseline */ declare(strict_types=1); @@ -28,7 +28,7 @@ class CreateRepoCli extends CliFramework { protected function configure(): void { - $this->setDescription('Scaffold a new governed repository with full moko-platform baseline'); + $this->setDescription('Scaffold a new governed repository with full MokoCLI baseline'); $this->addArgument('--name', 'Repository name', null); $this->addArgument('--type', 'Project type', null); $this->addArgument('--description', 'Repository description', ''); @@ -60,16 +60,16 @@ class CreateRepoCli extends CliFramework 'generic' => 'generic', ]; $TYPE_TO_TOPICS = [ - 'dolibarr' => ['dolibarr', 'erp', 'crm', 'php', 'moko-platform'], - 'joomla' => ['joomla', 'cms', 'php', 'moko-platform'], - 'nodejs' => ['nodejs', 'javascript', 'typescript', 'moko-platform'], - 'terraform' => ['terraform', 'infrastructure', 'iac', 'moko-platform'], - 'python' => ['python', 'moko-platform'], - 'wordpress' => ['wordpress', 'php', 'cms', 'moko-platform'], - 'generic' => ['moko-platform'], + 'dolibarr' => ['dolibarr', 'erp', 'crm', 'php', 'MokoCLI'], + 'joomla' => ['joomla', 'cms', 'php', 'MokoCLI'], + 'nodejs' => ['nodejs', 'javascript', 'typescript', 'MokoCLI'], + 'terraform' => ['terraform', 'infrastructure', 'iac', 'MokoCLI'], + 'python' => ['python', 'MokoCLI'], + 'wordpress' => ['wordpress', 'php', 'cms', 'MokoCLI'], + 'generic' => ['MokoCLI'], ]; $platform = $TYPE_TO_PLATFORM[$type] ?? 'generic'; - $topics = $TYPE_TO_TOPICS[$type] ?? ['moko-platform']; + $topics = $TYPE_TO_TOPICS[$type] ?? ['MokoCLI']; $platformName = $adapter->getPlatformName(); $vis = $private ? 'private' : 'public'; echo "Scaffolding new repository: {$org}/{$name}" @@ -84,7 +84,7 @@ class CreateRepoCli extends CliFramework if (!$this->dryRun) { try { $data = $adapter->createOrgRepo($org, $name, [ - 'description' => $description ?: "Managed by moko-platform ({$type})", + 'description' => $description ?: "Managed by MokoCLI ({$type})", 'private' => $private, 'has_issues' => true, 'has_projects' => true, @@ -143,7 +143,7 @@ class CreateRepoCli extends CliFramework . "Copyright (C) 2026 Moko Consulting \n" . "SPDX-License-Identifier: GPL-3.0-or-later\n" . "DEFGROUP: {$name}\n" - . "INGROUP: moko-platform\n" + . "INGROUP: MokoCLI\n" . "REPO: {$repoUrl}\n" . "PATH: /README.md\n" . "BRIEF: {$description}\n" @@ -152,7 +152,7 @@ class CreateRepoCli extends CliFramework . "{$description}\n\n" . "## Getting Started\n\n" . "This repository is governed by" - . " [moko-platform]({$standardsUrl}).\n\n" + . " [MokoCLI]({$standardsUrl}).\n\n" . "## License\n\n" . "GPL-3.0-or-later. See [LICENSE](LICENSE)" . " for details.\n"; @@ -169,7 +169,7 @@ class CreateRepoCli extends CliFramework $name, 'README.md', $readmeContent, - 'docs: initialize README with moko-platform header [skip ci]', + 'docs: initialize README with MokoCLI header [skip ci]', $sha ); echo " README.md created\n"; diff --git a/cli/deploy_joomla.php b/cli/deploy_joomla.php index d361fbf..a18c02c 100644 --- a/cli/deploy_joomla.php +++ b/cli/deploy_joomla.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.CLI - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/deploy_joomla.php * BRIEF: Smart Joomla deploy — routes files to correct server directories by extension type * diff --git a/cli/dev_branch_reset.php b/cli/dev_branch_reset.php index 92d5704..d7d86b3 100644 --- a/cli/dev_branch_reset.php +++ b/cli/dev_branch_reset.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/dev_branch_reset.php * BRIEF: Delete and recreate dev branch from main via Gitea API */ diff --git a/cli/grafana_dashboard.php b/cli/grafana_dashboard.php index 9ae09cb..cf23653 100644 --- a/cli/grafana_dashboard.php +++ b/cli/grafana_dashboard.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/grafana_dashboard.php * VERSION: 09.25.05 * BRIEF: Manage Grafana dashboards via API diff --git a/cli/joomla_build.php b/cli/joomla_build.php index b8ab547..3f551de 100644 --- a/cli/joomla_build.php +++ b/cli/joomla_build.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/joomla_build.php * VERSION: 09.25.05 * BRIEF: Build a Joomla extension ZIP from manifest — all types supported diff --git a/cli/joomla_compat_check.php b/cli/joomla_compat_check.php index 0c1a9c5..7337d7b 100644 --- a/cli/joomla_compat_check.php +++ b/cli/joomla_compat_check.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/joomla_compat_check.php * BRIEF: Check if extension targetplatform regex matches the latest Joomla version */ diff --git a/cli/joomla_metadata_validate.php b/cli/joomla_metadata_validate.php index 4dbba7e..e00cc7c 100644 --- a/cli/joomla_metadata_validate.php +++ b/cli/joomla_metadata_validate.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: mokoplatform.CLI - * INGROUP: mokoplatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokoplatform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/joomla_metadata_validate.php * VERSION: 09.25.05 * BRIEF: Validate MokoGitea repo metadata against Joomla extension manifest XML diff --git a/cli/joomla_release.php b/cli/joomla_release.php index b763e62..47ff552 100644 --- a/cli/joomla_release.php +++ b/cli/joomla_release.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/joomla_release.php * BRIEF: Joomla release pipeline — build ZIP+tar.gz, upload to GitHub Release, update updates.xml * @@ -407,7 +407,7 @@ class JoomlaRelease extends CliFramework $this->api->post("/repos/{$repo}/releases", [ 'tag_name' => $tag, 'name' => $releaseName, - 'body' => "## {$version}\n\nCreated by moko-platform release pipeline.", + 'body' => "## {$version}\n\nCreated by MokoCLI release pipeline.", 'prerelease' => ($stability !== 'stable'), ]); } diff --git a/cli/license_manage.php b/cli/license_manage.php index 01fe260..1f4f41b 100644 --- a/cli/license_manage.php +++ b/cli/license_manage.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/license_manage.php * BRIEF: Manage license packages and keys via MokoGitea licensing API * diff --git a/cli/manifest_element.php b/cli/manifest_element.php index 9cf9580..e10e7c7 100644 --- a/cli/manifest_element.php +++ b/cli/manifest_element.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/manifest_element.php * BRIEF: Extract element name, type, type prefix, and ZIP name from manifest */ diff --git a/cli/manifest_licensing.php b/cli/manifest_licensing.php index b7b825e..6f99eba 100644 --- a/cli/manifest_licensing.php +++ b/cli/manifest_licensing.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/manifest_licensing.php * VERSION: 09.25.05 * BRIEF: Ensure licensing tags (updateservers, dlid) in Joomla extension manifests diff --git a/cli/manifest_read.php b/cli/manifest_read.php index fca4eba..222ad8f 100644 --- a/cli/manifest_read.php +++ b/cli/manifest_read.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/manifest_read.php * VERSION: 09.25.05 * BRIEF: Parse .manifest.xml and output requested field(s) for CI consumption @@ -59,7 +59,7 @@ class ManifestReadCli extends CliFramework $candidates = [ "{$root}/.mokogitea/manifest.xml", "{$root}/.mokogitea/.manifest.xml", // legacy (dot-prefixed) - "{$root}/.mokogitea/.moko-platform", // legacy v4 + "{$root}/.mokogitea/.MokoCLI", // legacy v4 ]; foreach ($candidates as $candidate) { diff --git a/cli/package_build.php b/cli/package_build.php index abf89a1..97ad56f 100644 --- a/cli/package_build.php +++ b/cli/package_build.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/package_build.php * BRIEF: Build ZIP and tar.gz install packages for Joomla/Dolibarr/generic projects * diff --git a/cli/platform_detect.php b/cli/platform_detect.php index 6f480b3..ac1da66 100644 --- a/cli/platform_detect.php +++ b/cli/platform_detect.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/platform_detect.php * VERSION: 09.25.05 * BRIEF: Auto-detect repository platform type and optionally update manifest diff --git a/cli/release.php b/cli/release.php index 4ef6b7c..4c0685e 100644 --- a/cli/release.php +++ b/cli/release.php @@ -6,11 +6,11 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/release.php - * BRIEF: Automate the moko-platform version branch release flow + * BRIEF: Automate the MokoCLI version branch release flow */ declare(strict_types=1); @@ -23,7 +23,7 @@ class ReleaseCli extends CliFramework { protected function configure(): void { - $this->setDescription('Automate the moko-platform version branch release flow'); + $this->setDescription('Automate the MokoCLI version branch release flow'); $this->addArgument('--bump', 'Bump type: patch, minor, or major', ''); } diff --git a/cli/release_body_update.php b/cli/release_body_update.php index 54c9b79..05deb24 100644 --- a/cli/release_body_update.php +++ b/cli/release_body_update.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/release_body_update.php * BRIEF: Update Gitea release body with changelog extract and checksums */ diff --git a/cli/release_cascade.php b/cli/release_cascade.php index fb3fb47..8f7f9fb 100644 --- a/cli/release_cascade.php +++ b/cli/release_cascade.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/release_cascade.php * VERSION: 09.25.05 * BRIEF: DEPRECATED — cascade behavior removed. Each release stream is independent. diff --git a/cli/release_create.php b/cli/release_create.php index c7d6b61..745f8c3 100644 --- a/cli/release_create.php +++ b/cli/release_create.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/release_create.php * BRIEF: Create or overwrite a Gitea release with proper naming */ diff --git a/cli/release_manage.php b/cli/release_manage.php index e665d3e..337afbb 100644 --- a/cli/release_manage.php +++ b/cli/release_manage.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/release_manage.php * BRIEF: Create/update Gitea releases, upload assets, update release body */ diff --git a/cli/release_mirror.php b/cli/release_mirror.php index de1481c..1eb684e 100644 --- a/cli/release_mirror.php +++ b/cli/release_mirror.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/release_mirror.php * BRIEF: Mirror a Gitea release (with assets) to a GitHub repository */ @@ -201,7 +201,7 @@ class ReleaseMirrorCli extends CliFramework CURLOPT_HTTPHEADER => [ "Authorization: token {$token}", 'Accept: application/vnd.github+json', - 'User-Agent: moko-platform', + 'User-Agent: MokoCLI', 'Content-Type: application/json', ], CURLOPT_TIMEOUT => 30, @@ -229,7 +229,7 @@ class ReleaseMirrorCli extends CliFramework CURLOPT_HTTPHEADER => [ "Authorization: token {$token}", 'Accept: application/vnd.github+json', - 'User-Agent: moko-platform', + 'User-Agent: MokoCLI', 'Content-Type: application/octet-stream', ], CURLOPT_POSTFIELDS => file_get_contents($filePath), diff --git a/cli/release_notes.php b/cli/release_notes.php index dd31520..4ee6f4a 100644 --- a/cli/release_notes.php +++ b/cli/release_notes.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/release_notes.php * BRIEF: Extract release notes from CHANGELOG.md for a given version */ diff --git a/cli/release_package.php b/cli/release_package.php index 2eb7035..7e899ad 100644 --- a/cli/release_package.php +++ b/cli/release_package.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/release_package.php * BRIEF: Build packages (ZIP + tar.gz) with SHA-256 and upload to Gitea release */ diff --git a/cli/release_promote.php b/cli/release_promote.php index faf779e..a9eda46 100644 --- a/cli/release_promote.php +++ b/cli/release_promote.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/release_promote.php * BRIEF: Promote a Gitea release from one channel to another (rename release, tag, assets) */ diff --git a/cli/release_publish.php b/cli/release_publish.php index cc273dd..81ea9b0 100644 --- a/cli/release_publish.php +++ b/cli/release_publish.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/release_publish.php * VERSION: 09.25.05 * BRIEF: Publish a release and create copies for all lesser stability streams. diff --git a/cli/release_validate.php b/cli/release_validate.php index 63d5a88..04bd3bc 100644 --- a/cli/release_validate.php +++ b/cli/release_validate.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/release_validate.php * BRIEF: Pre-release validation -- version consistency, required files, manifest checks */ diff --git a/cli/release_verify.php b/cli/release_verify.php index 1166ab2..f8229aa 100644 --- a/cli/release_verify.php +++ b/cli/release_verify.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/release_verify.php * BRIEF: Verify a built release artifact — version, SHA256, disallowed files */ diff --git a/cli/scaffold_client.php b/cli/scaffold_client.php index 5275190..3cac8aa 100644 --- a/cli/scaffold_client.php +++ b/cli/scaffold_client.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/scaffold_client.php * VERSION: 09.25.05 * BRIEF: Scaffold a new client-waas repo from Template-Client-WaaS with pre-configured settings diff --git a/cli/sync_rulesets.php b/cli/sync_rulesets.php index 1c6e264..e921415 100644 --- a/cli/sync_rulesets.php +++ b/cli/sync_rulesets.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/sync_rulesets.php * BRIEF: Apply branch protection rules to all repos via platform adapter */ @@ -46,7 +46,7 @@ class SyncRulesetsCli extends CliFramework ); $platformName = $adapter->getPlatformName(); - $ALWAYS_EXCLUDE = ['moko-platform', '.github-private']; + $ALWAYS_EXCLUDE = ['MokoCLI', '.github-private']; // -- Protection rules (platform-agnostic format) -- $PROTECTIONS = [ diff --git a/cli/theme_lint.php b/cli/theme_lint.php index aa910fb..ba971cd 100644 --- a/cli/theme_lint.php +++ b/cli/theme_lint.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/theme_lint.php * BRIEF: Lint theme files -- CSS syntax, image sizes, hardcoded URLs */ diff --git a/cli/updates_xml_build.php b/cli/updates_xml_build.php index 86f47d7..a6ab06a 100644 --- a/cli/updates_xml_build.php +++ b/cli/updates_xml_build.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/updates_xml_build.php * BRIEF: Generate Joomla updates.xml from extension manifest metadata */ diff --git a/cli/updates_xml_sync.php b/cli/updates_xml_sync.php index cf19020..47e36f0 100644 --- a/cli/updates_xml_sync.php +++ b/cli/updates_xml_sync.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/updates_xml_sync.php * VERSION: 09.25.05 * BRIEF: Sync updates.xml to target branches via Gitea API diff --git a/cli/version_auto_bump.php b/cli/version_auto_bump.php index 84facf1..c586003 100644 --- a/cli/version_auto_bump.php +++ b/cli/version_auto_bump.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/version_auto_bump.php * VERSION: 09.25.05 * BRIEF: Auto patch-bump, set stability suffix, and commit — single CLI replacing inline workflow bash diff --git a/cli/version_bump.php b/cli/version_bump.php index b8698f7..287ee88 100644 --- a/cli/version_bump.php +++ b/cli/version_bump.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/version_bump.php * BRIEF: Auto-increment version -- manifest.xml is canonical, cascades to all XML and MD files */ diff --git a/cli/version_bump_remote.php b/cli/version_bump_remote.php index d154467..3a663d6 100644 --- a/cli/version_bump_remote.php +++ b/cli/version_bump_remote.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/version_bump_remote.php * BRIEF: Bump version in manifest XML and CHANGELOG.md on a remote branch via Gitea API */ diff --git a/cli/version_check.php b/cli/version_check.php index dc0a16d..37042f8 100644 --- a/cli/version_check.php +++ b/cli/version_check.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/version_check.php * VERSION: 09.25.05 * BRIEF: Validate version consistency across README, manifests, and sub-packages diff --git a/cli/version_read.php b/cli/version_read.php index 22a2fde..35e059a 100644 --- a/cli/version_read.php +++ b/cli/version_read.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/version_read.php * BRIEF: Read version — manifest.xml is canonical, falls back to README.md and Joomla XML */ diff --git a/cli/version_reset_dev.php b/cli/version_reset_dev.php index 8b0d8f3..e22f20a 100644 --- a/cli/version_reset_dev.php +++ b/cli/version_reset_dev.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/version_reset_dev.php * BRIEF: Reset platform version to 'development' on a branch via Gitea API */ diff --git a/cli/version_set_platform.php b/cli/version_set_platform.php index 0133b8d..3ac394f 100644 --- a/cli/version_set_platform.php +++ b/cli/version_set_platform.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/version_set_platform.php * BRIEF: Set version in platform-specific files (Dolibarr $this->version, Joomla ) */ diff --git a/cli/wiki_sync.php b/cli/wiki_sync.php index 69c6202..21ba2db 100644 --- a/cli/wiki_sync.php +++ b/cli/wiki_sync.php @@ -6,12 +6,12 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/wiki_sync.php * VERSION: 09.25.05 - * BRIEF: Sync select wiki pages from moko-platform to all template repos + * BRIEF: Sync select wiki pages from MokoCLI to all template repos */ declare(strict_types=1); @@ -25,7 +25,7 @@ class WikiSyncCli extends CliFramework private string $giteaUrl = 'https://git.mokoconsulting.tech'; private string $token = ''; private string $org = 'MokoConsulting'; - private string $sourceRepo = 'moko-platform'; + private string $sourceRepo = 'MokoCLI'; private array $targetRepos = []; private array $pages = []; private bool $allTemplates = false; @@ -38,10 +38,10 @@ class WikiSyncCli extends CliFramework protected function configure(): void { - $this->setDescription('Sync wiki pages from moko-platform to template repos'); + $this->setDescription('Sync wiki pages from MokoCLI to template repos'); $this->addArgument('--token', 'Gitea API token (required)', ''); $this->addArgument('--org', 'Organization (default: MokoConsulting)', 'MokoConsulting'); - $this->addArgument('--source', 'Source repo (default: moko-platform)', 'moko-platform'); + $this->addArgument('--source', 'Source repo (default: MokoCLI)', 'MokoCLI'); $this->addArgument('--target', 'Target repo (can repeat)', ''); $this->addArgument('--page', 'Page to sync (can repeat)', ''); $this->addArgument('--all-standards', 'Sync all UPPERCASE standards pages', false); diff --git a/cli/workflow_sync.php b/cli/workflow_sync.php index 063768f..8d5a7bf 100644 --- a/cli/workflow_sync.php +++ b/cli/workflow_sync.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.CLI - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.CLI + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /cli/workflow_sync.php * VERSION: 09.25.05 * BRIEF: Sync workflows from Generic → platform templates → live repos based on manifest.platform diff --git a/deploy/backup-before-deploy.php b/deploy/backup-before-deploy.php index 66665d1..2d0785b 100644 --- a/deploy/backup-before-deploy.php +++ b/deploy/backup-before-deploy.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Deploy - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Deploy + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /deploy/backup-before-deploy.php * VERSION: 09.25.05 * BRIEF: Snapshot Joomla directories before deployment for rollback capability diff --git a/deploy/deploy-dolibarr.php b/deploy/deploy-dolibarr.php index 56d3440..20219dc 100644 --- a/deploy/deploy-dolibarr.php +++ b/deploy/deploy-dolibarr.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Deploy - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Deploy + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /deploy/deploy-dolibarr.php * VERSION: 09.25.05 * BRIEF: Deploy Dolibarr module files to a remote server via SFTP/rsync diff --git a/deploy/deploy-joomla.php b/deploy/deploy-joomla.php index 645de96..97233fa 100644 --- a/deploy/deploy-joomla.php +++ b/deploy/deploy-joomla.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Deploy - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Deploy + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /deploy/deploy-joomla.php * BRIEF: Smart Joomla deploy — routes files to correct Joomla directories based on XML manifest * diff --git a/deploy/deploy-sftp.php b/deploy/deploy-sftp.php index d39492a..3043075 100644 --- a/deploy/deploy-sftp.php +++ b/deploy/deploy-sftp.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Deploy - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Deploy + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /deploy/deploy-sftp.php * BRIEF: Deploy a repository src/ directory to a remote web server via SFTP */ diff --git a/deploy/health-check.php b/deploy/health-check.php index 968cb4b..8d4d3cb 100644 --- a/deploy/health-check.php +++ b/deploy/health-check.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Deploy - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Deploy + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /deploy/health-check.php * VERSION: 09.25.05 * BRIEF: Post-deploy health check — verify a Joomla site is responding correctly diff --git a/deploy/rollback-joomla.php b/deploy/rollback-joomla.php index a7e4f0f..a19bee1 100644 --- a/deploy/rollback-joomla.php +++ b/deploy/rollback-joomla.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Deploy - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Deploy + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /deploy/rollback-joomla.php * VERSION: 09.25.05 * BRIEF: Rollback a Joomla deployment by restoring from a pre-deploy snapshot diff --git a/deploy/sync-joomla.php b/deploy/sync-joomla.php index af1a6c0..137cac0 100644 --- a/deploy/sync-joomla.php +++ b/deploy/sync-joomla.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Deploy - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Deploy + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /deploy/sync-joomla.php * VERSION: 09.25.05 * BRIEF: Sync Joomla site directories between two servers via rsync over SSH diff --git a/fix/fix_line_endings.php b/fix/fix_line_endings.php index 6f5d4d6..de722b0 100644 --- a/fix/fix_line_endings.php +++ b/fix/fix_line_endings.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Fix - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Fix + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /fix/fix_line_endings.php * BRIEF: CLI script to normalise CRLF/CR to LF in tracked source files */ diff --git a/fix/fix_permissions.php b/fix/fix_permissions.php index 615c915..d6b5389 100644 --- a/fix/fix_permissions.php +++ b/fix/fix_permissions.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Fix - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Fix + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /fix/fix_permissions.php * BRIEF: CLI script to normalise file permissions (dirs 755, files 644, scripts 755) */ diff --git a/fix/fix_tabs.php b/fix/fix_tabs.php index 13f5709..095930f 100644 --- a/fix/fix_tabs.php +++ b/fix/fix_tabs.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Fix - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Fix + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /fix/fix_tabs.php * BRIEF: CLI script to convert tabs to spaces in tracked source files */ diff --git a/fix/fix_trailing_spaces.php b/fix/fix_trailing_spaces.php index 699163b..8d5aa47 100644 --- a/fix/fix_trailing_spaces.php +++ b/fix/fix_trailing_spaces.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Fix - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Fix + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /fix/fix_trailing_spaces.php * BRIEF: CLI script to remove trailing whitespace from tracked source files */ diff --git a/lib/CliBase.php b/lib/CliBase.php index 2151b44..667872d 100644 --- a/lib/CliBase.php +++ b/lib/CliBase.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Lib - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Lib + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/CliBase.php * BRIEF: Standalone base CLI class for scripts that do not use CliFramework */ diff --git a/lib/Common.php b/lib/Common.php index 6621891..f6bfc70 100644 --- a/lib/Common.php +++ b/lib/Common.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Lib - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Lib + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Common.php * BRIEF: Common utility functions for scripts * NOTE: Version format used throughout is zero-padded semver: XX.YY.ZZ (e.g. 04.00.04). @@ -33,7 +33,7 @@ class Common const FALLBACK_VERSION = '04.00.00'; const REPO_URL = 'https://git.mokoconsulting.tech/MokoConsulting/MokoStandards-API'; - const REPO_URL_GITHUB = 'https://git.mokoconsulting.tech/MokoConsulting/moko-platform'; + const REPO_URL_GITHUB = 'https://git.mokoconsulting.tech/MokoConsulting/mokocli'; const COPYRIGHT = 'Copyright (C) 2026 Moko Consulting '; const LICENSE = 'GPL-3.0-or-later'; diff --git a/lib/Enterprise/AbstractProjectPlugin.php b/lib/Enterprise/AbstractProjectPlugin.php index 9a3794a..f8d8755 100644 --- a/lib/Enterprise/AbstractProjectPlugin.php +++ b/lib/Enterprise/AbstractProjectPlugin.php @@ -9,9 +9,9 @@ declare(strict_types=1); * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Plugins - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Plugins + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/AbstractProjectPlugin.php * BRIEF: Abstract base class for project plugins */ @@ -23,7 +23,7 @@ namespace MokoEnterprise; * * Provides common functionality for all project type plugins * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 1.0.0 */ abstract class AbstractProjectPlugin implements ProjectPluginInterface diff --git a/lib/Enterprise/ApiClient.php b/lib/Enterprise/ApiClient.php index a6d8e7d..9f7e5b3 100644 --- a/lib/Enterprise/ApiClient.php +++ b/lib/Enterprise/ApiClient.php @@ -9,9 +9,9 @@ declare(strict_types=1); * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.API - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.API + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/ApiClient.php * BRIEF: HTTP API client library */ @@ -31,9 +31,9 @@ declare(strict_types=1); * * SPDX-License-Identifier: GPL-3.0-or-later * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 04.00.04 - * @author moko-platform Team + * @author MokoCLI Team * @license GPL-3.0-or-later */ diff --git a/lib/Enterprise/AuditLogger.php b/lib/Enterprise/AuditLogger.php index 1b90dc6..abbae13 100644 --- a/lib/Enterprise/AuditLogger.php +++ b/lib/Enterprise/AuditLogger.php @@ -22,15 +22,15 @@ declare(strict_types=1); * (at your option) any later version. * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Audit - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Audit + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/AuditLogger.php * BRIEF: Enterprise audit logging * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 04.00.04 - * @author moko-platform Team + * @author MokoCLI Team * @license GPL-3.0-or-later */ diff --git a/lib/Enterprise/CheckpointManager.php b/lib/Enterprise/CheckpointManager.php index 7d447f8..5817923 100644 --- a/lib/Enterprise/CheckpointManager.php +++ b/lib/Enterprise/CheckpointManager.php @@ -10,15 +10,15 @@ declare(strict_types=1); * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Checkpoint - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Checkpoint + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/CheckpointManager.php * BRIEF: Checkpoint manager for resumable operations * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 04.00.04 - * @author moko-platform Team + * @author MokoCLI Team * @license GPL-3.0-or-later */ diff --git a/lib/Enterprise/CliFramework.php b/lib/Enterprise/CliFramework.php index ab4534e..a3f90b4 100644 --- a/lib/Enterprise/CliFramework.php +++ b/lib/Enterprise/CliFramework.php @@ -7,11 +7,11 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.CLI - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.CLI + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/CliFramework.php - * BRIEF: CliFramework — unified base class for all moko-platform CLI scripts + * BRIEF: CliFramework — unified base class for all MokoCLI CLI scripts */ declare(strict_types=1); @@ -23,11 +23,11 @@ use DateTimeZone; use Exception; // ============================================================================= -// CliFramework — current base class for all moko-platform CLI scripts +// CliFramework — current base class for all MokoCLI CLI scripts // ============================================================================= /** - * Base class for moko-platform CLI scripts. + * Base class for MokoCLI CLI scripts. * * Provides argument parsing, a structured lifecycle, and a full console * graphics system (banners, coloured log levels, progress bars, status diff --git a/lib/Enterprise/Config.php b/lib/Enterprise/Config.php index 6fa909e..80a420e 100644 --- a/lib/Enterprise/Config.php +++ b/lib/Enterprise/Config.php @@ -9,9 +9,9 @@ declare(strict_types=1); * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Config - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Config + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/Config.php * BRIEF: Configuration manager */ @@ -32,9 +32,9 @@ declare(strict_types=1); * * SPDX-License-Identifier: GPL-3.0-or-later * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 04.00.04 - * @author moko-platform Team + * @author MokoCLI Team * @license GPL-3.0-or-later */ diff --git a/lib/Enterprise/ConfigValidator.php b/lib/Enterprise/ConfigValidator.php index 941f105..99a6988 100644 --- a/lib/Enterprise/ConfigValidator.php +++ b/lib/Enterprise/ConfigValidator.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/ConfigValidator.php * BRIEF: Validate project config against plugin JSON schema */ @@ -21,7 +21,7 @@ namespace MokoEnterprise; /** * Configuration Validator * - * Validates moko-platform configuration files (YAML, JSON, HCL) + * Validates MokoCLI configuration files (YAML, JSON, HCL) * against expected schemas and reports errors. * * @since 04.00.00 diff --git a/lib/Enterprise/EnterpriseReadinessValidator.php b/lib/Enterprise/EnterpriseReadinessValidator.php index 398ebf8..019d389 100644 --- a/lib/Enterprise/EnterpriseReadinessValidator.php +++ b/lib/Enterprise/EnterpriseReadinessValidator.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/EnterpriseReadinessValidator.php * BRIEF: Enterprise readiness validation library */ diff --git a/lib/Enterprise/ErrorRecovery.php b/lib/Enterprise/ErrorRecovery.php index 03817b8..fe5439b 100644 --- a/lib/Enterprise/ErrorRecovery.php +++ b/lib/Enterprise/ErrorRecovery.php @@ -17,15 +17,15 @@ declare(strict_types=1); * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Recovery - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Recovery + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/ErrorRecovery.php * BRIEF: Error recovery framework * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 04.00.04 - * @author moko-platform Team + * @author MokoCLI Team * @license GPL-3.0-or-later * @deprecated Individual class files should be used instead */ diff --git a/lib/Enterprise/FileFixUtility.php b/lib/Enterprise/FileFixUtility.php index e58b08e..ed94621 100644 --- a/lib/Enterprise/FileFixUtility.php +++ b/lib/Enterprise/FileFixUtility.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise - * INGROUP: MokoPlatform.Lib - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise + * INGROUP: MokoCLI.Lib + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/FileFixUtility.php * BRIEF: Utility class for fixing file formatting issues (line endings, permissions, tabs, trailing spaces) */ diff --git a/lib/Enterprise/GitHubAdapter.php b/lib/Enterprise/GitHubAdapter.php index 0dad9b3..9fb3fd4 100644 --- a/lib/Enterprise/GitHubAdapter.php +++ b/lib/Enterprise/GitHubAdapter.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Platform - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Platform + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/GitHubAdapter.php * BRIEF: GitHub implementation of GitPlatformAdapter */ @@ -31,7 +31,7 @@ use RuntimeException; * - Topics: PUT with {"names": [...]} * - Workflow dir: .github/workflows * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @since 04.06.10 * @see GitPlatformAdapter */ diff --git a/lib/Enterprise/GitPlatformAdapter.php b/lib/Enterprise/GitPlatformAdapter.php index c359f33..fdb28ea 100644 --- a/lib/Enterprise/GitPlatformAdapter.php +++ b/lib/Enterprise/GitPlatformAdapter.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Platform - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Platform + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/GitPlatformAdapter.php * BRIEF: Interface defining all git platform operations for GitHub/Gitea abstraction */ @@ -21,11 +21,11 @@ namespace MokoEnterprise; /** * Git Platform Adapter Interface * - * Defines all platform operations required by moko-platform automation. + * Defines all platform operations required by MokoCLI automation. * Implementations exist for GitHub (GitHubAdapter) and Gitea (MokoGiteaAdapter), * allowing scripts to work against either platform transparently. * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 04.06.10 */ interface GitPlatformAdapter diff --git a/lib/Enterprise/InputValidator.php b/lib/Enterprise/InputValidator.php index 8980b8e..37c9c50 100644 --- a/lib/Enterprise/InputValidator.php +++ b/lib/Enterprise/InputValidator.php @@ -9,9 +9,9 @@ declare(strict_types=1); * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Validation - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Validation + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/InputValidator.php * BRIEF: Input validation library */ @@ -31,9 +31,9 @@ declare(strict_types=1); * * SPDX-License-Identifier: GPL-3.0-or-later * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 04.00.04 - * @author moko-platform Team + * @author MokoCLI Team * @license GPL-3.0-or-later */ @@ -161,11 +161,11 @@ class InputValidator break; case 'moko': - // moko-platform format: XX.YY.ZZ + // MokoCLI format: XX.YY.ZZ $pattern = '/^\d{2}\.\d{2}\.\d{2}$/'; if (!preg_match($pattern, $version)) { throw new ValidationError( - "Invalid moko-platform version format: {$version}. Expected: XX.YY.ZZ" + "Invalid MokoCLI version format: {$version}. Expected: XX.YY.ZZ" ); } break; diff --git a/lib/Enterprise/ManifestReader.php b/lib/Enterprise/ManifestReader.php index f33d24e..9495548 100644 --- a/lib/Enterprise/ManifestReader.php +++ b/lib/Enterprise/ManifestReader.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: moko-platform.Enterprise - * INGROUP: moko-platform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/ManifestReader.php * BRIEF: Read and parse .mokogitea/manifest.xml — shared across all CLI tools */ @@ -58,7 +58,7 @@ class ManifestReader $candidates = [ "{$root}/.mokogitea/manifest.xml", "{$root}/.mokogitea/.manifest.xml", - "{$root}/.mokogitea/.moko-platform", + "{$root}/.mokogitea/.MokoCLI", ]; $manifestFile = null; diff --git a/lib/Enterprise/MetricsCollector.php b/lib/Enterprise/MetricsCollector.php index 8c9de43..73a12c7 100644 --- a/lib/Enterprise/MetricsCollector.php +++ b/lib/Enterprise/MetricsCollector.php @@ -9,15 +9,15 @@ declare(strict_types=1); * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Metrics - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Metrics + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/MetricsCollector.php * BRIEF: Metrics collection framework */ /** - * Metrics Collector for moko-platform + * Metrics Collector for MokoCLI * * Provides observability and monitoring capabilities: * - Execution time tracking with timers @@ -46,9 +46,9 @@ declare(strict_types=1); * * SPDX-License-Identifier: GPL-3.0-or-later * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 04.00.04 - * @author moko-platform Team + * @author MokoCLI Team * @license GPL-3.0-or-later */ diff --git a/lib/Enterprise/MokoGiteaAdapter.php b/lib/Enterprise/MokoGiteaAdapter.php index f379b41..af80d1f 100644 --- a/lib/Enterprise/MokoGiteaAdapter.php +++ b/lib/Enterprise/MokoGiteaAdapter.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Platform - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Platform + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/MokoGiteaAdapter.php * BRIEF: Gitea implementation of GitPlatformAdapter */ @@ -33,7 +33,7 @@ use RuntimeException; * - Branch protection: flat API (not rulesets) * - Workflow dir: .mokogitea/workflows * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @since 04.06.10 * @see GitPlatformAdapter */ diff --git a/lib/Enterprise/MokoStandardsParser.php b/lib/Enterprise/MokoStandardsParser.php index ad9427e..971e7f1 100644 --- a/lib/Enterprise/MokoStandardsParser.php +++ b/lib/Enterprise/MokoStandardsParser.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/MokoStandardsParser.php * BRIEF: Parser for the XML-based manifest.xml repository manifest */ @@ -28,14 +28,14 @@ use SimpleXMLElement; * Reads, writes, and validates the manifest.xml repository manifest. * The file uses XML format (no file extension) and lives at .mokogitea/manifest.xml. * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 04.07.00 */ class MokoStandardsParser { public const SCHEMA_VERSION = '1.0'; - public const NAMESPACE_URI = 'https://standards.mokoconsulting.tech/moko-platform/1.0'; - public const STANDARDS_SOURCE = 'https://git.mokoconsulting.tech/MokoConsulting/moko-platform'; + public const NAMESPACE_URI = 'https://standards.mokoconsulting.tech/MokoCLI/1.0'; + public const STANDARDS_SOURCE = 'https://git.mokoconsulting.tech/MokoConsulting/mokocli'; /** Valid platform slugs — must match Template-* repo names. */ public const VALID_PLATFORMS = [ @@ -180,7 +180,7 @@ class MokoStandardsParser * @type string $name Repository name (required) * @type string $org Organization (required) * @type string $platform Platform slug (required) - * @type string $standards_version moko-platform version + * @type string $standards_version MokoCLI version * @type string $description Repo description * @type string $license SPDX license identifier * @type list $topics Repo topics @@ -205,7 +205,7 @@ class MokoStandardsParser // Add comment header $dom->appendChild($dom->createComment( "\n MokoStandards Repository Manifest\n" - . " Auto-generated by moko-platform bulk sync.\n" + . " Auto-generated by MokoCLI bulk sync.\n" . " Manual edits to and may be overwritten.\n" . " See: docs/standards/mokostandards-file-spec.md\n" )); diff --git a/lib/Enterprise/PackageBuilder.php b/lib/Enterprise/PackageBuilder.php index e224389..8f3104d 100644 --- a/lib/Enterprise/PackageBuilder.php +++ b/lib/Enterprise/PackageBuilder.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise - * INGROUP: MokoPlatform.Lib - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise + * INGROUP: MokoCLI.Lib + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/PackageBuilder.php * BRIEF: Builds release packages for generic, Dolibarr module, and Joomla component projects */ diff --git a/lib/Enterprise/PlatformAdapterFactory.php b/lib/Enterprise/PlatformAdapterFactory.php index 9bf4d4e..6f63c38 100644 --- a/lib/Enterprise/PlatformAdapterFactory.php +++ b/lib/Enterprise/PlatformAdapterFactory.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Platform - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Platform + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/PlatformAdapterFactory.php * BRIEF: Factory for creating platform-specific GitPlatformAdapter instances */ @@ -33,7 +33,7 @@ use RuntimeException; * $repos = $adapter->listOrgRepos('mokoconsulting-tech'); * ``` * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 04.06.10 * * @since 04.00.00 diff --git a/lib/Enterprise/PluginFactory.php b/lib/Enterprise/PluginFactory.php index a41eb01..ab1d289 100644 --- a/lib/Enterprise/PluginFactory.php +++ b/lib/Enterprise/PluginFactory.php @@ -9,9 +9,9 @@ declare(strict_types=1); * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Plugins - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Plugins + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/PluginFactory.php * BRIEF: Plugin factory for project type detection */ @@ -23,7 +23,7 @@ namespace MokoEnterprise; * * Provides convenient methods for plugin instantiation with dependency injection * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 1.0.0 */ class PluginFactory diff --git a/lib/Enterprise/PluginRegistry.php b/lib/Enterprise/PluginRegistry.php index 72812c9..9e037b3 100644 --- a/lib/Enterprise/PluginRegistry.php +++ b/lib/Enterprise/PluginRegistry.php @@ -9,9 +9,9 @@ declare(strict_types=1); * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Plugins - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Plugins + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/PluginRegistry.php * BRIEF: Plugin registry for available project plugins */ @@ -35,7 +35,7 @@ use MokoEnterprise\Plugins\McpServerPlugin; * * Manages plugin discovery, registration, and lifecycle * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 1.0.0 */ class PluginRegistry diff --git a/lib/Enterprise/Plugins/ApiPlugin.php b/lib/Enterprise/Plugins/ApiPlugin.php index 5b26bdf..bf52a6f 100644 --- a/lib/Enterprise/Plugins/ApiPlugin.php +++ b/lib/Enterprise/Plugins/ApiPlugin.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Plugins - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Plugins + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/Plugins/ApiPlugin.php * BRIEF: Enterprise plugin for API/Microservices projects */ diff --git a/lib/Enterprise/Plugins/DocumentationPlugin.php b/lib/Enterprise/Plugins/DocumentationPlugin.php index f559fbf..6529877 100644 --- a/lib/Enterprise/Plugins/DocumentationPlugin.php +++ b/lib/Enterprise/Plugins/DocumentationPlugin.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Plugins - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Plugins + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/Plugins/DocumentationPlugin.php * BRIEF: Enterprise plugin for documentation projects */ diff --git a/lib/Enterprise/Plugins/DolibarrPlugin.php b/lib/Enterprise/Plugins/DolibarrPlugin.php index b54dedd..6da6166 100644 --- a/lib/Enterprise/Plugins/DolibarrPlugin.php +++ b/lib/Enterprise/Plugins/DolibarrPlugin.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Plugins - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Plugins + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/Plugins/DolibarrPlugin.php * BRIEF: Enterprise plugin for Dolibarr modules */ diff --git a/lib/Enterprise/Plugins/GenericPlugin.php b/lib/Enterprise/Plugins/GenericPlugin.php index 5774606..6fa9d28 100644 --- a/lib/Enterprise/Plugins/GenericPlugin.php +++ b/lib/Enterprise/Plugins/GenericPlugin.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Plugins - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Plugins + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/Plugins/GenericPlugin.php * BRIEF: Enterprise plugin for generic projects */ diff --git a/lib/Enterprise/Plugins/JoomlaPlugin.php b/lib/Enterprise/Plugins/JoomlaPlugin.php index ae5a6c2..044fb79 100644 --- a/lib/Enterprise/Plugins/JoomlaPlugin.php +++ b/lib/Enterprise/Plugins/JoomlaPlugin.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Plugins - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Plugins + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/Plugins/JoomlaPlugin.php * BRIEF: Enterprise plugin for Joomla projects */ diff --git a/lib/Enterprise/Plugins/McpServerPlugin.php b/lib/Enterprise/Plugins/McpServerPlugin.php index 51c4a23..58f42f6 100644 --- a/lib/Enterprise/Plugins/McpServerPlugin.php +++ b/lib/Enterprise/Plugins/McpServerPlugin.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Plugins - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Plugins + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/Plugins/McpServerPlugin.php * BRIEF: Enterprise plugin for MCP (Model Context Protocol) server projects */ diff --git a/lib/Enterprise/Plugins/MobilePlugin.php b/lib/Enterprise/Plugins/MobilePlugin.php index e3c0e6d..8086d0e 100644 --- a/lib/Enterprise/Plugins/MobilePlugin.php +++ b/lib/Enterprise/Plugins/MobilePlugin.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Plugins - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Plugins + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/Plugins/MobilePlugin.php * BRIEF: Enterprise plugin for mobile app projects */ diff --git a/lib/Enterprise/Plugins/NodeJsPlugin.php b/lib/Enterprise/Plugins/NodeJsPlugin.php index b226d01..1756110 100644 --- a/lib/Enterprise/Plugins/NodeJsPlugin.php +++ b/lib/Enterprise/Plugins/NodeJsPlugin.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Plugins - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Plugins + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/Plugins/NodeJsPlugin.php * BRIEF: Enterprise plugin for Node.js/TypeScript projects */ diff --git a/lib/Enterprise/Plugins/PythonPlugin.php b/lib/Enterprise/Plugins/PythonPlugin.php index 9cc3995..632a991 100644 --- a/lib/Enterprise/Plugins/PythonPlugin.php +++ b/lib/Enterprise/Plugins/PythonPlugin.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Plugins - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Plugins + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/Plugins/PythonPlugin.php * BRIEF: Enterprise plugin for Python projects */ diff --git a/lib/Enterprise/Plugins/TerraformPlugin.php b/lib/Enterprise/Plugins/TerraformPlugin.php index 8a64280..d7e5db1 100644 --- a/lib/Enterprise/Plugins/TerraformPlugin.php +++ b/lib/Enterprise/Plugins/TerraformPlugin.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Plugins - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Plugins + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/Plugins/TerraformPlugin.php * BRIEF: Enterprise plugin for Terraform projects */ diff --git a/lib/Enterprise/Plugins/WordPressPlugin.php b/lib/Enterprise/Plugins/WordPressPlugin.php index 2aa8763..ebebd0e 100644 --- a/lib/Enterprise/Plugins/WordPressPlugin.php +++ b/lib/Enterprise/Plugins/WordPressPlugin.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Plugins - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Plugins + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/Plugins/WordPressPlugin.php * BRIEF: Enterprise plugin for WordPress projects */ diff --git a/lib/Enterprise/ProjectConfigValidator.php b/lib/Enterprise/ProjectConfigValidator.php index 6851e7b..0ec39c8 100644 --- a/lib/Enterprise/ProjectConfigValidator.php +++ b/lib/Enterprise/ProjectConfigValidator.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.ProjectTypes - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.ProjectTypes + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/ProjectConfigValidator.php * BRIEF: Enterprise library for validating project configurations */ diff --git a/lib/Enterprise/ProjectMetricsCollector.php b/lib/Enterprise/ProjectMetricsCollector.php index becf791..865f887 100644 --- a/lib/Enterprise/ProjectMetricsCollector.php +++ b/lib/Enterprise/ProjectMetricsCollector.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.ProjectTypes - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.ProjectTypes + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/ProjectMetricsCollector.php * BRIEF: Enterprise library for collecting project-specific metrics */ diff --git a/lib/Enterprise/ProjectPluginInterface.php b/lib/Enterprise/ProjectPluginInterface.php index 0a7f895..d5f9913 100644 --- a/lib/Enterprise/ProjectPluginInterface.php +++ b/lib/Enterprise/ProjectPluginInterface.php @@ -9,9 +9,9 @@ declare(strict_types=1); * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Plugins - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Plugins + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/ProjectPluginInterface.php * BRIEF: Interface for project type plugins */ @@ -24,7 +24,7 @@ namespace MokoEnterprise; * Each project type (Joomla, Node.js, Python, etc.) implements this interface * to provide type-specific validation, metrics, and management capabilities. * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 1.0.0 */ interface ProjectPluginInterface diff --git a/lib/Enterprise/ProjectTypeDetector.php b/lib/Enterprise/ProjectTypeDetector.php index 63c8090..2f88bbb 100644 --- a/lib/Enterprise/ProjectTypeDetector.php +++ b/lib/Enterprise/ProjectTypeDetector.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.ProjectTypes - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.ProjectTypes + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/ProjectTypeDetector.php * BRIEF: Enterprise library for detecting project types */ diff --git a/lib/Enterprise/RecoveryError.php b/lib/Enterprise/RecoveryError.php index 6effaae..973197a 100644 --- a/lib/Enterprise/RecoveryError.php +++ b/lib/Enterprise/RecoveryError.php @@ -10,15 +10,15 @@ declare(strict_types=1); * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Recovery - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Recovery + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/RecoveryError.php * BRIEF: Recovery error exception class * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 04.00.04 - * @author moko-platform Team + * @author MokoCLI Team * @license GPL-3.0-or-later */ diff --git a/lib/Enterprise/RecoveryManager.php b/lib/Enterprise/RecoveryManager.php index 5f8f03e..0056124 100644 --- a/lib/Enterprise/RecoveryManager.php +++ b/lib/Enterprise/RecoveryManager.php @@ -10,15 +10,15 @@ declare(strict_types=1); * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Recovery - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Recovery + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/RecoveryManager.php * BRIEF: Recovery manager for failed operations * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 04.00.04 - * @author moko-platform Team + * @author MokoCLI Team * @license GPL-3.0-or-later */ diff --git a/lib/Enterprise/RepositoryHealthChecker.php b/lib/Enterprise/RepositoryHealthChecker.php index a181cbb..ac7ab01 100644 --- a/lib/Enterprise/RepositoryHealthChecker.php +++ b/lib/Enterprise/RepositoryHealthChecker.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/RepositoryHealthChecker.php * BRIEF: Repository health checking enterprise library */ diff --git a/lib/Enterprise/RepositorySynchronizer.php b/lib/Enterprise/RepositorySynchronizer.php index ff3dc38..be56288 100644 --- a/lib/Enterprise/RepositorySynchronizer.php +++ b/lib/Enterprise/RepositorySynchronizer.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/RepositorySynchronizer.php * BRIEF: Repository synchronization enterprise library */ @@ -165,8 +165,8 @@ class RepositorySynchronizer // Resolve repo root (three levels up from this file: Enterprise/ → lib/ → root) // API repo root (definitions, sync code) $repoRoot = dirname(dirname(__DIR__)); - // moko-platform repo root (templates, configs) - $standardsRoot = getenv('MOKOSTANDARDS_ROOT') ?: dirname($repoRoot) . '/moko-platform'; + // MokoCLI repo root (templates, configs) + $standardsRoot = getenv('MOKOSTANDARDS_ROOT') ?: dirname($repoRoot) . '/MokoCLI'; // Detect platform from repo metadata $repoInfo = $this->adapter->getRepo($org, $repo); @@ -364,7 +364,7 @@ class RepositorySynchronizer * @param string $repo * @param string $platform Detected platform slug (e.g. 'dolibarr') * @param array $filesToSync - * @param string $repoRoot Absolute path to the moko-platform repository root + * @param string $repoRoot Absolute path to the MokoCLI repository root * @param bool $force When true, overwrite files even when always_overwrite = false * @return array{number: ?int, summary: array} */ @@ -421,7 +421,7 @@ class RepositorySynchronizer // Create tracking issue (no PR — files pushed directly to default branch) $issueBody = $this->generatePRBody($summary); - $issueTitle = 'chore: moko-platform v' . self::STANDARDS_MINOR . ' sync — ' . count($summary['copied']) . ' files updated'; + $issueTitle = 'chore: MokoCLI v' . self::STANDARDS_MINOR . ' sync — ' . count($summary['copied']) . ' files updated'; $issueNumber = null; try { @@ -478,7 +478,7 @@ class RepositorySynchronizer * never added. * * @param string $existing Current file content from the remote repo - * @param string $template Template file content from moko-platform + * @param string $template Template file content from MokoCLI * @return string Merged content */ /** @@ -501,7 +501,7 @@ class RepositorySynchronizer * @param string $repo Repository name * @param string $platform Detected platform type * @param array $filesToSync Files to synchronize - * @param string $repoRoot Path to moko-platform root + * @param string $repoRoot Path to MokoCLI root * @param bool $force Force overwrite * @param string $branchName Target branch * @param string|null $moduleId Dolibarr module ID (pre-fetched) @@ -583,7 +583,7 @@ class RepositorySynchronizer $repo, $targetPath, $content, - "chore: update {$targetPath} from moko-platform", + "chore: update {$targetPath} from MokoCLI", $existingFile['sha'] ?? null, $branchName ); @@ -597,7 +597,7 @@ class RepositorySynchronizer $repo, $targetPath, $content, - "chore: add {$targetPath} from moko-platform", + "chore: add {$targetPath} from MokoCLI", null, $branchName ); @@ -613,7 +613,7 @@ class RepositorySynchronizer $repo, $targetPath, $content, - "chore: update {$targetPath} from moko-platform", + "chore: update {$targetPath} from MokoCLI", $existing['sha'] ?? null, $branchName ); @@ -782,7 +782,7 @@ class RepositorySynchronizer 'license' => 'GPL-3.0-or-later', 'topics' => $repoInfo['topics'] ?? [], 'language' => $repoInfo['language'] ?? MokoStandardsParser::platformLanguage($platform), - 'package_type' => moko-platformParser::platformPackageType($platform), + 'package_type' => MokoCLIParser::platformPackageType($platform), 'last_synced' => date('c'), ]; @@ -1110,7 +1110,7 @@ class RepositorySynchronizer // so repos have a safe place for custom workflows that sync won't touch. $entries[] = [ 'inline_content' => "# Custom Workflows\n\nPlace repo-specific workflows here.\n\n" - . "- **Never overwritten** by moko-platform bulk sync\n" + . "- **Never overwritten** by MokoCLI bulk sync\n" . "- **Never deleted** by the repository-cleanup workflow\n" . "- Safe for custom CI, notifications, or repo-specific automation\n\n" . "Synced workflows live in the parent `{$wfDir}/` directory.\n", @@ -1261,7 +1261,7 @@ class RepositorySynchronizer // Append missing lines with a clear separator $merged = rtrim($existing) . "\n\n" - . "# ── moko-platform sync (auto-appended) ────────────────────────────────\n" + . "# ── MokoCLI sync (auto-appended) ────────────────────────────────\n" . implode("\n", $missing) . "\n"; return $merged; @@ -1313,7 +1313,7 @@ class RepositorySynchronizer '{{standards_version}}' => self::STANDARDS_VERSION, '{{standards_minor}}' => self::STANDARDS_MINOR, '{{standards_branch}}' => self::VERSION_BRANCH, - // Single-brace tokens — used by GitHub repository templates and older moko-platform stubs + // Single-brace tokens — used by GitHub repository templates and older MokoCLI stubs '{REPO_NAME}' => $repoInfo['name'] ?? $repo, '{REPO_URL}' => "https://github.com/{$org}/{$repo}", '{REPO_DESCRIPTION}' => $repoInfo['description'] ?? '', @@ -1383,8 +1383,8 @@ class RepositorySynchronizer */ private function generatePRBody(array $summary): string { - $body = "## moko-platform Synchronization\n\n"; - $body .= "This PR synchronizes workflows, configurations, and scripts from the moko-platform repository.\n\n"; + $body = "## MokoCLI Synchronization\n\n"; + $body .= "This PR synchronizes workflows, configurations, and scripts from the MokoCLI repository.\n\n"; // Summary statistics $body .= "### Summary\n"; @@ -1419,7 +1419,7 @@ class RepositorySynchronizer $body .= "- Verify issue templates render correctly\n\n"; $body .= "---\n"; - $body .= "*This PR was automatically generated by the moko-platform bulk sync process.*\n"; + $body .= "*This PR was automatically generated by the MokoCLI bulk sync process.*\n"; return $body; } @@ -1524,7 +1524,7 @@ class RepositorySynchronizer default => 'EDEDED', }, match ($label) { - 'mokostandards' => 'moko-platform compliance', + 'mokostandards' => 'MokoCLI compliance', 'type: chore' => 'Maintenance tasks', 'automation' => 'Automated processes or scripts', default => '', diff --git a/lib/Enterprise/RetryHelper.php b/lib/Enterprise/RetryHelper.php index 84810b2..46fb2e6 100644 --- a/lib/Enterprise/RetryHelper.php +++ b/lib/Enterprise/RetryHelper.php @@ -10,15 +10,15 @@ declare(strict_types=1); * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Recovery - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Recovery + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/RetryHelper.php * BRIEF: Retry helper with exponential backoff * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 04.00.04 - * @author moko-platform Team + * @author MokoCLI Team * @license GPL-3.0-or-later */ diff --git a/lib/Enterprise/SecurityValidator.php b/lib/Enterprise/SecurityValidator.php index 3926cb7..a7a23a2 100644 --- a/lib/Enterprise/SecurityValidator.php +++ b/lib/Enterprise/SecurityValidator.php @@ -9,15 +9,15 @@ declare(strict_types=1); * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Security - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Security + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/SecurityValidator.php * BRIEF: Security validation library */ /** - * Security Validator for moko-platform + * Security Validator for MokoCLI * * Provides security scanning and validation: * - Credential detection in code/config files @@ -45,9 +45,9 @@ declare(strict_types=1); * * SPDX-License-Identifier: GPL-3.0-or-later * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 04.00.04 - * @author moko-platform Team + * @author MokoCLI Team * @license GPL-3.0-or-later */ diff --git a/lib/Enterprise/SourceResolver.php b/lib/Enterprise/SourceResolver.php index c94d111..ac843e2 100644 --- a/lib/Enterprise/SourceResolver.php +++ b/lib/Enterprise/SourceResolver.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise - * INGROUP: MokoPlatform.Lib - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise + * INGROUP: MokoCLI.Lib + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/SourceResolver.php * BRIEF: Resolve the root-level source directory across repos (source/, src/, htdocs/) */ diff --git a/lib/Enterprise/SynchronizationException.php b/lib/Enterprise/SynchronizationException.php index 2761b38..6387da7 100644 --- a/lib/Enterprise/SynchronizationException.php +++ b/lib/Enterprise/SynchronizationException.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/SynchronizationException.php * BRIEF: Custom exception for repository synchronization errors */ diff --git a/lib/Enterprise/TransactionManager.php b/lib/Enterprise/TransactionManager.php index 093ca6c..798e676 100644 --- a/lib/Enterprise/TransactionManager.php +++ b/lib/Enterprise/TransactionManager.php @@ -9,15 +9,15 @@ declare(strict_types=1); * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Transaction - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Transaction + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/TransactionManager.php * BRIEF: Transaction manager for atomic operations */ /** - * Transaction Manager for moko-platform + * Transaction Manager for MokoCLI * * Provides atomic multi-step operations with automatic rollback: * - Transaction boundaries for ACID operations @@ -52,9 +52,9 @@ declare(strict_types=1); * * SPDX-License-Identifier: GPL-3.0-or-later * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 04.00.04 - * @author moko-platform Team + * @author MokoCLI Team * @license GPL-3.0-or-later */ diff --git a/lib/Enterprise/UnifiedValidation.php b/lib/Enterprise/UnifiedValidation.php index f159bb2..af623a1 100644 --- a/lib/Enterprise/UnifiedValidation.php +++ b/lib/Enterprise/UnifiedValidation.php @@ -9,15 +9,15 @@ declare(strict_types=1); * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Enterprise.Validation - * INGROUP: MokoPlatform.Enterprise - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Enterprise.Validation + * INGROUP: MokoCLI.Enterprise + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/Enterprise/UnifiedValidation.php * BRIEF: Unified validation framework */ /** - * Unified Validation Framework for moko-platform + * Unified Validation Framework for MokoCLI * * Consolidates all validation logic into a single framework with plugins. * Replaces 12+ individual validator scripts with a unified approach. @@ -51,9 +51,9 @@ declare(strict_types=1); * * SPDX-License-Identifier: GPL-3.0-or-later * - * @package MokoPlatform\Enterprise + * @package MokoCLI\Enterprise * @version 04.00.04 - * @author moko-platform Team + * @author MokoCLI Team * @license GPL-3.0-or-later */ diff --git a/lib/plugins/Joomla/UpdateXmlGenerator.php b/lib/plugins/Joomla/UpdateXmlGenerator.php index 12cfada..b697bc4 100644 --- a/lib/plugins/Joomla/UpdateXmlGenerator.php +++ b/lib/plugins/Joomla/UpdateXmlGenerator.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Joomla - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Joomla + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /lib/plugins/Joomla/UpdateXmlGenerator.php * BRIEF: Generates and updates Joomla extension updates.xml files */ diff --git a/maintenance/pin_action_shas.php b/maintenance/pin_action_shas.php index dbee8a8..9441f4f 100644 --- a/maintenance/pin_action_shas.php +++ b/maintenance/pin_action_shas.php @@ -9,9 +9,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Maintenance - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Maintenance + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /maintenance/pin_action_shas.php * BRIEF: Pin GitHub Actions to immutable commit SHAs in workflow files * NOTE: Resolves tag/branch refs to commit SHAs via the GitHub API to satisfy diff --git a/maintenance/repo_inventory.php b/maintenance/repo_inventory.php index 73352bd..982e27f 100644 --- a/maintenance/repo_inventory.php +++ b/maintenance/repo_inventory.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Maintenance - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Maintenance + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /maintenance/repo_inventory.php * BRIEF: Generate a live inventory dashboard of all governed repos as a GitHub issue */ @@ -26,7 +26,7 @@ class RepoInventoryCli extends CliFramework private $api = null; private string $token = ''; private $platformConfig = null; - private const ALWAYS_EXCLUDE = ['moko-platform', '.github-private']; + private const ALWAYS_EXCLUDE = ['MokoCLI', '.github-private']; protected function configure(): void { @@ -161,7 +161,7 @@ class RepoInventoryCli extends CliFramework if (!$this->dryRun) { $title = "dashboard: repository inventory ({$org})"; - $issueQuery = "repos/{$org}/moko-platform/issues" + $issueQuery = "repos/{$org}/MokoCLI/issues" . "?labels=inventory&state=all&per_page=1" . "&sort=created&direction=desc"; [$_, $existing] = $this->ghApi('GET', $issueQuery, null); @@ -169,7 +169,7 @@ class RepoInventoryCli extends CliFramework $num = $existing[0]['number']; $this->ghApi( 'PATCH', - "repos/{$org}/moko-platform/issues/{$num}", + "repos/{$org}/MokoCLI/issues/{$num}", [ 'title' => $title, 'body' => $body, @@ -181,7 +181,7 @@ class RepoInventoryCli extends CliFramework } else { [$_, $issue] = $this->ghApi( 'POST', - "repos/{$org}/moko-platform/issues", + "repos/{$org}/MokoCLI/issues", [ 'title' => $title, 'body' => $body, @@ -226,7 +226,7 @@ class RepoInventoryCli extends CliFramework CURLOPT_HTTPHEADER => [ 'Authorization: bearer ' . $this->token, 'Content-Type: application/json', - 'User-Agent: moko-platform-Inventory', + 'User-Agent: MokoCLI-Inventory', ], ]); $body = (string) curl_exec($ch); diff --git a/maintenance/rotate_secrets.php b/maintenance/rotate_secrets.php index e145955..1d3050d 100644 --- a/maintenance/rotate_secrets.php +++ b/maintenance/rotate_secrets.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Maintenance - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Maintenance + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /maintenance/rotate_secrets.php * BRIEF: Audit FTP secrets and variables across all governed repos -- report missing or stale */ @@ -25,7 +25,7 @@ class RotateSecretsCli extends CliFramework { private $api = null; private string $token = ''; - private const ALWAYS_EXCLUDE = ['moko-platform', '.github-private']; + private const ALWAYS_EXCLUDE = ['MokoCLI', '.github-private']; private const ENVS = [ 'DEV' => [ 'vars' => ['DEV_FTP_HOST', 'DEV_FTP_PATH', 'DEV_FTP_USERNAME', 'DEV_FTP_SUFFIX'], @@ -186,7 +186,7 @@ class RotateSecretsCli extends CliFramework . "| Repository | Issue |\n|---|---|\n" . "{$table}\n\n---\n" . "*Auto-created by `rotate_secrets.php`*\n"; - $auditQuery = "repos/{$org}/moko-platform/issues" + $auditQuery = "repos/{$org}/MokoCLI/issues" . "?labels=secret-audit&state=all" . "&per_page=1&sort=created&direction=desc"; [$_, $existing] = $this->ghApi('GET', $auditQuery, null); @@ -196,7 +196,7 @@ class RotateSecretsCli extends CliFramework $num = $existing[0]['number']; $this->ghApi( 'PATCH', - "repos/{$org}/moko-platform/issues/{$num}", + "repos/{$org}/MokoCLI/issues/{$num}", [ 'title' => $auditTitle, 'body' => $body, @@ -210,7 +210,7 @@ class RotateSecretsCli extends CliFramework } else { [$_, $issue] = $this->ghApi( 'POST', - "repos/{$org}/moko-platform/issues", + "repos/{$org}/MokoCLI/issues", [ 'title' => $auditTitle, 'body' => $body, diff --git a/maintenance/setup_labels.php b/maintenance/setup_labels.php index e2a131e..5a5b61d 100644 --- a/maintenance/setup_labels.php +++ b/maintenance/setup_labels.php @@ -3,18 +3,18 @@ /* Copyright (C) 2026 Moko Consulting * - * REQUIRED FILE: This file must be present in all moko-platform-compliant repositories + * REQUIRED FILE: This file must be present in all MokoCLI-compliant repositories * * This file is part of a Moko Consulting project. * * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Maintenance - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Maintenance + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /maintenance/setup_labels.php - * BRIEF: REQUIRED label deployment script for all moko-platform-governed repositories + * BRIEF: REQUIRED label deployment script for all MokoCLI-governed repositories */ declare(strict_types=1); @@ -27,7 +27,7 @@ use MokoEnterprise\GitPlatformAdapter; use MokoEnterprise\PlatformAdapterFactory; /** - * Deploys the standard set of repository labels required by moko-platform. + * Deploys the standard set of repository labels required by MokoCLI. * * Uses the platform adapter (GitHub or Gitea) to create or update each label. * Supports --dry-run mode to preview without making changes. @@ -66,7 +66,7 @@ class SetupLabels extends CliFramework // Workflow / Process ['automation', '8B4513', 'Automated processes or scripts'], - ['moko-platform', 'B60205', 'moko-platform compliance'], + ['MokoCLI', 'B60205', 'MokoCLI compliance'], ['needs-review', 'FBCA04', 'Awaiting code review'], ['work-in-progress', 'D93F0B', 'Work in progress, not ready for merge'], ['breaking-change', 'D73A4A', 'Breaking API or functionality change'], @@ -106,8 +106,8 @@ class SetupLabels extends CliFramework ['health: poor', 'FF6B6B', 'Health score below 50'], // Sync / Automation - ['standards-update', 'B60205', 'moko-platform sync update'], - ['standards-drift', 'FBCA04', 'Repository drifted from moko-platform'], + ['standards-update', 'B60205', 'MokoCLI sync update'], + ['standards-drift', 'FBCA04', 'Repository drifted from MokoCLI'], ['sync-report', '0075CA', 'Bulk sync run report'], ['sync-failure', 'D73A4A', 'Bulk sync failure requiring attention'], ['push-failure', 'D73A4A', 'File push failure requiring attention'], diff --git a/maintenance/sync_dolibarr_readmes.php b/maintenance/sync_dolibarr_readmes.php index 12565dc..8e97585 100644 --- a/maintenance/sync_dolibarr_readmes.php +++ b/maintenance/sync_dolibarr_readmes.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Maintenance - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Maintenance + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /maintenance/sync_dolibarr_readmes.php * BRIEF: Keeps root README.md and src/README.md in sync for Dolibarr module repositories * NOTE: Version format is zero-padded semver: XX.YY.ZZ (e.g. 04.00.04). All version regex @@ -77,8 +77,8 @@ class SyncDolibarrReadmes extends CliFramework $moduleName = $this->extractModuleName($rootContent, $repoRoot); $repoUrl = $this->extractField($rootContent, 'REPO', 'https://git.mokoconsulting.tech/MokoConsulting'); - $defgroup = $this->extractField($rootContent, 'DEFGROUP', 'MokoPlatform.Module'); - $ingroup = $this->extractField($rootContent, 'INGROUP', 'moko-platform'); + $defgroup = $this->extractField($rootContent, 'DEFGROUP', 'MokoCLI.Module'); + $ingroup = $this->extractField($rootContent, 'INGROUP', 'MokoCLI'); $brief = $this->extractField($rootContent, 'BRIEF', "{$moduleName} end-user documentation"); $installSection = $this->extractSection($rootContent, 'Installation'); @@ -272,7 +272,7 @@ NOTE: This file is auto-generated by sync_dolibarr_readmes.php from root README. Last synced: {$today} --> -[![moko-platform](https://img.shields.io/badge/moko--platform-{$version}-blue)]({$repoUrl}) +[![MokoCLI](https://img.shields.io/badge/moko--platform-{$version}-blue)]({$repoUrl}) # {$moduleName} diff --git a/maintenance/update_repo_inventory.php b/maintenance/update_repo_inventory.php index ae53df6..5a592f2 100644 --- a/maintenance/update_repo_inventory.php +++ b/maintenance/update_repo_inventory.php @@ -9,9 +9,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Maintenance - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Maintenance + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /maintenance/update_repo_inventory.php * BRIEF: Queries GitHub org repos and rewrites the auto-generated section of REPOSITORY_INVENTORY.md */ @@ -205,7 +205,7 @@ class UpdateRepoInventory extends CliFramework $lower = strtolower($name); - if (in_array('mokostandards-core', $topics, true) || $name === 'moko-platform' || $name === '.github-private') { + if (in_array('mokostandards-core', $topics, true) || $name === 'MokoCLI' || $name === '.github-private') { $groups['core'][] = $repo; } elseif ( in_array('dolibarr-module', $topics, true) diff --git a/maintenance/update_sha_hashes.php b/maintenance/update_sha_hashes.php index fc68a9b..9b6223c 100755 --- a/maintenance/update_sha_hashes.php +++ b/maintenance/update_sha_hashes.php @@ -9,9 +9,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Maintenance - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Maintenance + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /maintenance/update_sha_hashes.php * BRIEF: Update SHA-256 hashes in script registry */ diff --git a/maintenance/update_version_from_readme.php b/maintenance/update_version_from_readme.php index 469f7c0..9ad3fd9 100644 --- a/maintenance/update_version_from_readme.php +++ b/maintenance/update_version_from_readme.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Maintenance - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Maintenance + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /maintenance/update_version_from_readme.php * BRIEF: Reads VERSION from README.md FILE INFORMATION block and propagates it to all badges and FILE INFORMATION headers * NOTE: README.md is the single source of truth for the repository version. @@ -29,7 +29,7 @@ use MokoEnterprise\{ApiClient, AuditLogger, CliFramework}; * badge and FILE INFORMATION VERSION field in the repository. * * Sources updated: - * - Markdown badge: [![moko-platform](https://img.shields.io/badge/moko--platform-OLD-blue)] + * - Markdown badge: [![MokoCLI](https://img.shields.io/badge/moko--platform-OLD-blue)] * - Markdown header: VERSION: OLD (inside comment blocks) * - PHP header: * VERSION: OLD (inside block comments) * - YAML/Shell header:# VERSION: OLD @@ -220,7 +220,7 @@ class UpdateVersionFromReadme extends CliFramework $updated = $original; // ── Badge replacement (all file types) ─────────────────────────── - // shields.io badge: [![moko-platform](...badge/moko--platform-XX.YY.ZZ-color)] + // shields.io badge: [![MokoCLI](...badge/moko--platform-XX.YY.ZZ-color)] $updated = preg_replace( '/(\[!\[MokoStandards\]\(https:\/\/img\.shields\.io\/badge\/MokoStandards-)[0-9]{2}\.[0-9]{2}\.[0-9]{2}(-[a-z]+\)\])/', '${1}' . $version . '${2}', diff --git a/plugin_health_check.php b/plugin_health_check.php index 7bedb76..b016ff7 100755 --- a/plugin_health_check.php +++ b/plugin_health_check.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Plugin - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Plugin + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /plugin_health_check.php * BRIEF: Run health checks on a project using the auto-detected or specified plugin */ diff --git a/plugin_list.php b/plugin_list.php index 4f55a51..0f397b4 100755 --- a/plugin_list.php +++ b/plugin_list.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Plugin - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Plugin + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /plugin_list.php * BRIEF: List all available project-type plugins and their capabilities */ diff --git a/plugin_metrics.php b/plugin_metrics.php index 63214a5..28ecf45 100755 --- a/plugin_metrics.php +++ b/plugin_metrics.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Plugin - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Plugin + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /plugin_metrics.php * BRIEF: Collect project metrics using the auto-detected or specified plugin */ diff --git a/plugin_readiness.php b/plugin_readiness.php index ee55eb9..d6d662d 100755 --- a/plugin_readiness.php +++ b/plugin_readiness.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Plugin - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Plugin + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /plugin_readiness.php * BRIEF: Check release readiness of a project using the auto-detected or specified plugin */ diff --git a/plugin_validate.php b/plugin_validate.php index 24bd666..ac6f3f8 100755 --- a/plugin_validate.php +++ b/plugin_validate.php @@ -7,9 +7,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Scripts.Plugin - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Scripts.Plugin + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /plugin_validate.php * BRIEF: Validate a project's structure and standards using the auto-detected or specified plugin */ diff --git a/release/generate_dolibarr_version_txt.php b/release/generate_dolibarr_version_txt.php index fa5efbb..a801e18 100644 --- a/release/generate_dolibarr_version_txt.php +++ b/release/generate_dolibarr_version_txt.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Release - * INGROUP: MokoPlatform.Scripts - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Release + * INGROUP: MokoCLI.Scripts + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /release/generate_dolibarr_version_txt.php * BRIEF: Create or update version.txt on Dolibarr module release * diff --git a/release/generate_joomla_update_xml.php b/release/generate_joomla_update_xml.php index 59e834c..055468e 100644 --- a/release/generate_joomla_update_xml.php +++ b/release/generate_joomla_update_xml.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Release - * INGROUP: MokoPlatform.Scripts - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Release + * INGROUP: MokoCLI.Scripts + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /release/generate_joomla_update_xml.php * BRIEF: Create or update the in updates.xml on release * @@ -35,7 +35,7 @@ * [--zip-url=https://github.com/org/repo/releases/download/v1.2.0/mod_foo-1.2.0.zip] \ * [--inject-updateserver] * - * Usage (remote — from moko-platform): + * Usage (remote — from MokoCLI): * php generate_joomla_update_xml.php \ * --repo=mokoconsulting-tech/WaasComponent \ * --tag=v1.2.0 \ diff --git a/src/functions.php b/src/functions.php index 62d05c9..e6e80ac 100644 --- a/src/functions.php +++ b/src/functions.php @@ -1,21 +1,21 @@ * * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Common - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Common + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /src/functions.php * BRIEF: Common utility functions * - * This file provides global helper functions for moko-platform. + * This file provides global helper functions for MokoCLI. * - * @package MokoPlatform + * @package MokoCLI * @version 04.00.04 */ @@ -23,7 +23,7 @@ declare(strict_types=1); if (!function_exists('mokostandards_version')) { /** - * Get the moko-platform version + * Get the MokoCLI version * * @return string Version number */ @@ -35,7 +35,7 @@ if (!function_exists('mokostandards_version')) { if (!function_exists('mokostandards_root_dir')) { /** - * Get the moko-platform root directory + * Get the MokoCLI root directory * * @return string Root directory path */ diff --git a/templates/scripts/common/CliBase.template.php b/templates/scripts/common/CliBase.template.php index 15f013d..b995f8d 100644 --- a/templates/scripts/common/CliBase.template.php +++ b/templates/scripts/common/CliBase.template.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Templates.Common - * INGROUP: MokoPlatform.Templates - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Templates.Common + * INGROUP: MokoCLI.Templates + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /templates/scripts/common/CliBase.template.php * BRIEF: PHP CLI script template — extends MokoEnterprise\CliFramework * NOTE: Copy this file as a starting point for new PHP CLI scripts in governed repos. diff --git a/templates/scripts/release/package_dolibarr.php b/templates/scripts/release/package_dolibarr.php index 5109f1b..09ee1a2 100644 --- a/templates/scripts/release/package_dolibarr.php +++ b/templates/scripts/release/package_dolibarr.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Templates.Scripts.Release - * INGROUP: MokoPlatform.Templates - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Templates.Scripts.Release + * INGROUP: MokoCLI.Templates + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /templates/scripts/release/package_dolibarr.php * BRIEF: Build a distributable ZIP package for a Dolibarr module * NOTE: Deployed to bin/build_package.php in governed Dolibarr module repos. diff --git a/templates/scripts/release/package_joomla.php b/templates/scripts/release/package_joomla.php index 9b8352c..228db7f 100644 --- a/templates/scripts/release/package_joomla.php +++ b/templates/scripts/release/package_joomla.php @@ -8,9 +8,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Templates.Scripts.Release - * INGROUP: MokoPlatform.Templates - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Templates.Scripts.Release + * INGROUP: MokoCLI.Templates + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /templates/scripts/release/package_joomla.php * BRIEF: Build a distributable ZIP package for a Joomla component * NOTE: Deployed to bin/build_package.php in governed WaaS component repos. diff --git a/templates/scripts/validate/dolibarr_module.php b/templates/scripts/validate/dolibarr_module.php index d9e3e87..90d442a 100644 --- a/templates/scripts/validate/dolibarr_module.php +++ b/templates/scripts/validate/dolibarr_module.php @@ -8,11 +8,11 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Templates.Scripts.Validate - * INGROUP: MokoPlatform.Templates - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Templates.Scripts.Validate + * INGROUP: MokoCLI.Templates + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /templates/scripts/validate/dolibarr_module.php - * BRIEF: Validate a Dolibarr module repository against moko-platform requirements + * BRIEF: Validate a Dolibarr module repository against MokoCLI requirements * NOTE: Deployed to bin/validate_module.php in governed Dolibarr module repos. * Run: php bin/validate_module.php [--path DIR] [--verbose] [--json] */ @@ -25,7 +25,7 @@ require_once __DIR__ . '/../vendor/autoload.php'; use MokoEnterprise\CliFramework; /** - * Validates a Dolibarr module repository against moko-platform requirements. + * Validates a Dolibarr module repository against MokoCLI requirements. * * Checks performed: * - Required directories (src/, src/core/modules/, langs/en_US/, img/) @@ -39,7 +39,7 @@ class ValidateDolibarrModule extends CliFramework { protected function configure(): void { - $this->setDescription('Validate a Dolibarr module repository against moko-platform requirements'); + $this->setDescription('Validate a Dolibarr module repository against MokoCLI requirements'); $this->addArgument('--path', 'Repository root to validate', '.'); } @@ -173,5 +173,5 @@ class ValidateDolibarrModule extends CliFramework } } -$script = new ValidateDolibarrModule('validate_module', 'Validate a Dolibarr module repository against moko-platform requirements'); +$script = new ValidateDolibarrModule('validate_module', 'Validate a Dolibarr module repository against MokoCLI requirements'); exit($script->execute()); diff --git a/templates/scripts/validate/validate_manifest.php b/templates/scripts/validate/validate_manifest.php index e6b7dea..dbc382e 100644 --- a/templates/scripts/validate/validate_manifest.php +++ b/templates/scripts/validate/validate_manifest.php @@ -8,11 +8,11 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Templates.Scripts.Validate - * INGROUP: MokoPlatform.Templates - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Templates.Scripts.Validate + * INGROUP: MokoCLI.Templates + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /templates/scripts/validate/validate_manifest.php - * BRIEF: Validate a Joomla component XML manifest against moko-platform requirements + * BRIEF: Validate a Joomla component XML manifest against MokoCLI requirements * NOTE: Deployed to bin/validate_manifest.php in governed WaaS component repos. * Run: php bin/validate_manifest.php [--path DIR] [--verbose] */ @@ -25,7 +25,7 @@ require_once __DIR__ . '/../vendor/autoload.php'; use MokoEnterprise\CliFramework; /** - * Validates a Joomla component XML manifest against moko-platform requirements. + * Validates a Joomla component XML manifest against MokoCLI requirements. * * Checks performed: * - XML manifest exists and is well-formed @@ -41,7 +41,7 @@ class ValidateJoomlaManifest extends CliFramework { protected function configure(): void { - $this->setDescription('Validate a Joomla component XML manifest against moko-platform requirements'); + $this->setDescription('Validate a Joomla component XML manifest against MokoCLI requirements'); $this->addArgument('--path', 'Repository root to validate', '.'); } @@ -188,5 +188,5 @@ class ValidateJoomlaManifest extends CliFramework } } -$script = new ValidateJoomlaManifest('validate_manifest', 'Validate a Joomla component XML manifest against moko-platform requirements'); +$script = new ValidateJoomlaManifest('validate_manifest', 'Validate a Joomla component XML manifest against MokoCLI requirements'); exit($script->execute()); diff --git a/templates/scripts/validate/validate_structure.php b/templates/scripts/validate/validate_structure.php index f1dbf08..b83c416 100644 --- a/templates/scripts/validate/validate_structure.php +++ b/templates/scripts/validate/validate_structure.php @@ -8,11 +8,11 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Templates.Scripts.Validate - * INGROUP: MokoPlatform.Templates - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Templates.Scripts.Validate + * INGROUP: MokoCLI.Templates + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /templates/scripts/validate/validate_structure.php - * BRIEF: Validate a repository structure against moko-platform requirements + * BRIEF: Validate a repository structure against MokoCLI requirements * NOTE: Deployed to bin/validate_structure.php in governed generic/default repos. * Run: php bin/validate_structure.php [--path DIR] [--verbose] */ @@ -25,7 +25,7 @@ require_once __DIR__ . '/../vendor/autoload.php'; use MokoEnterprise\CliFramework; /** - * Validates a generic repository structure against moko-platform requirements. + * Validates a generic repository structure against MokoCLI requirements. * * Checks performed: * - Required root files present (README.md, CHANGELOG.md, LICENSE, CONTRIBUTING.md, @@ -40,7 +40,7 @@ class ValidateStructure extends CliFramework { protected function configure(): void { - $this->setDescription('Validate a repository structure against moko-platform requirements'); + $this->setDescription('Validate a repository structure against MokoCLI requirements'); $this->addArgument('--path', 'Repository root to validate', '.'); } @@ -72,7 +72,7 @@ class ValidateStructure extends CliFramework } // ── Governance attachment ───────────────────────────────────────── - $this->section('moko-platform governance'); + $this->section('MokoCLI governance'); $mokoFile = file_exists("{$path}/.mokogitea/manifest.xml") || file_exists("{$path}/.github/.mokostandards") || file_exists("{$path}/.mokostandards"); @@ -87,7 +87,7 @@ class ValidateStructure extends CliFramework ? "{$path}/.github/.mokostandards" : "{$path}/.mokostandards"); $manifestContent = file_get_contents($manifestPath); - $isXml = str_contains($manifestContent, 'status($isXml, 'manifest.xml uses XML format'); $isXml ? $passed++ : $failed++; } @@ -172,5 +172,5 @@ class ValidateStructure extends CliFramework } } -$script = new ValidateStructure('validate_structure', 'Validate a repository structure against moko-platform requirements'); +$script = new ValidateStructure('validate_structure', 'Validate a repository structure against MokoCLI requirements'); exit($script->execute()); diff --git a/templates/security/index.php b/templates/security/index.php index 5abfa6a..020d58c 100644 --- a/templates/security/index.php +++ b/templates/security/index.php @@ -6,9 +6,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Templates.Security - * INGROUP: MokoPlatform.Templates - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Templates.Security + * INGROUP: MokoCLI.Templates + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /templates/security/index.php * BRIEF: Directory listing prevention script * diff --git a/templates/stubs/dolibarr.php b/templates/stubs/dolibarr.php index 44fe174..21f2372 100644 --- a/templates/stubs/dolibarr.php +++ b/templates/stubs/dolibarr.php @@ -5,9 +5,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Stubs - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Stubs + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /templates/stubs/dolibarr.php * BRIEF: PHPStan stub declarations for Dolibarr core classes * diff --git a/templates/stubs/joomla.php b/templates/stubs/joomla.php index 4a32846..8712df1 100644 --- a/templates/stubs/joomla.php +++ b/templates/stubs/joomla.php @@ -5,9 +5,9 @@ * SPDX-License-Identifier: GPL-3.0-or-later * * FILE INFORMATION - * DEFGROUP: MokoPlatform.Stubs - * INGROUP: MokoPlatform - * REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + * DEFGROUP: MokoCLI.Stubs + * INGROUP: MokoCLI + * REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli * PATH: /templates/stubs/joomla.php * BRIEF: PHPStan stub declarations for Joomla framework classes * diff --git a/templates/web/index.php b/templates/web/index.php index c2ce465..339fd9c 100644 --- a/templates/web/index.php +++ b/templates/web/index.php @@ -5,14 +5,14 @@ declare(strict_types=1); /** * Web Application Entry Point * - * This is the main entry point for the moko-platform web-based management system. + * This is the main entry point for the MokoCLI web-based management system. * Handles all HTTP requests and routes them to appropriate controllers. * * Copyright (C) 2026 Moko Consulting * * SPDX-License-Identifier: GPL-3.0-or-later * - * @package MokoPlatform + * @package MokoCLI * @version 04.00.04 */ @@ -90,7 +90,7 @@ function handleDashboard(): Response - moko-platform - Repository Management + MokoCLI - Repository Management