diff --git a/.mokogitea/ISSUE_TEMPLATE/config.yml b/.mokogitea/ISSUE_TEMPLATE/config.yml index d4d49ec..71fe271 100644 --- a/.mokogitea/ISSUE_TEMPLATE/config.yml +++ b/.mokogitea/ISSUE_TEMPLATE/config.yml @@ -8,7 +8,7 @@ contact_links: url: https://mokoconsulting.tech/ about: Get help or ask questions through our website - name: πŸ“š MokoStandards Documentation - url: https://git.mokoconsulting.tech/MokoConsulting/moko-platform + url: https://git.mokoconsulting.tech/MokoConsulting/.mokogitea/wiki 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/.mokogitea/ISSUE_TEMPLATE/feature_request.md b/.mokogitea/ISSUE_TEMPLATE/feature_request.md index 7b76dc9..984fcbe 100644 --- a/.mokogitea/ISSUE_TEMPLATE/feature_request.md +++ b/.mokogitea/ISSUE_TEMPLATE/feature_request.md @@ -37,7 +37,7 @@ If you have ideas about how this could be implemented, share them here: Add any other context, mockups, or screenshots about the feature request here. ## Relevant Standards -Does this relate to any standards in [MokoStandards](https://git.mokoconsulting.tech/MokoConsulting/MokoStandards)? +Does this relate to any standards in [MokoStandards](https://git.mokoconsulting.tech/MokoConsulting/.mokogitea/wiki)? - [ ] Accessibility (WCAG 2.1 AA) - [ ] Localization (en_US/en_GB) - [ ] Security best practices diff --git a/.mokogitea/ISSUE_TEMPLATE/security.md b/.mokogitea/ISSUE_TEMPLATE/security.md index f57b284..14d63e0 100644 --- a/.mokogitea/ISSUE_TEMPLATE/security.md +++ b/.mokogitea/ISSUE_TEMPLATE/security.md @@ -35,7 +35,7 @@ Use this template only for: ## Standards Reference -Does this relate to security standards in [MokoStandards](https://git.mokoconsulting.tech/MokoConsulting/MokoStandards)? +Does this relate to security standards in [MokoStandards](https://git.mokoconsulting.tech/MokoConsulting/.mokogitea/wiki)? - [ ] SPDX license identifiers - [ ] Secret management - [ ] Dependency security diff --git a/.mokogitea/workflows/issue-branch.yml b/.mokogitea/workflows/issue-branch.yml index eb67f8f..efa5e78 100644 --- a/.mokogitea/workflows/issue-branch.yml +++ b/.mokogitea/workflows/issue-branch.yml @@ -3,9 +3,9 @@ # SPDX-License-Identifier: GPL-3.0-or-later # # FILE INFORMATION -# DEFGROUP: MokoGitea.Workflow +# DEFGROUP: Gitea.Workflow # INGROUP: mokocli.Automation -# VERSION: 01.00.00 +# VERSION: 01.00.40 # BRIEF: Auto-create feature branch when an issue is opened name: "Universal: Issue Branch" @@ -19,7 +19,7 @@ permissions: issues: write env: - MOKOGITEA_URL: ${{ vars.GITEA_URL || 'https://git.mokoconsulting.tech' }} + GITEA_URL: ${{ vars.GITEA_URL || 'https://git.mokoconsulting.tech' }} jobs: create-branch: @@ -28,8 +28,8 @@ jobs: steps: - name: Create branch and comment run: | - TOKEN="${{ secrets.MOKOGITEA_TOKEN }}" - API="${MOKOGITEA_URL}/api/v1/repos/${{ github.repository }}" + TOKEN="${{ secrets.GA_TOKEN }}" + API="${GITEA_URL}/api/v1/repos/${{ github.repository }}" ISSUE_NUM="${{ github.event.issue.number }}" ISSUE_TITLE="${{ github.event.issue.title }}" @@ -58,7 +58,7 @@ jobs: echo "Created branch: ${BRANCH}" # Comment on issue with branch link - REPO_URL="${MOKOGITEA_URL}/${{ github.repository }}" + REPO_URL="${GITEA_URL}/${{ github.repository }}" BODY="Branch created: [\`${BRANCH}\`](${REPO_URL}/src/branch/${BRANCH})\n\n\`\`\`bash\ngit fetch origin\ngit checkout ${BRANCH}\n\`\`\`" curl -sf -X POST \ diff --git a/CHANGELOG.md b/CHANGELOG.md index eeabb81..a78983c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,9 @@ ## [Unreleased] +### Fixed +- **Honest install success** β€” the package installer no longer shows the license / next-steps message when a bundled child extension failed to install. A fail-open manifest verifier confirms every child extension landed in `#__extensions` and reports any that are missing. + ### Added - **Package Manifest** β€” `pkg_mokosuiterealty.xml` with dlid and updateservers - **Plugin Manifest** β€” `mokosuiterealty.xml` with config fieldsets (listing defaults, search settings) diff --git a/CLAUDE.md b/CLAUDE.md index 29d8b94..797012a 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -41,8 +41,8 @@ Joomla **package** (`pkg_mokosuiterealty`) β€” Layer 2 add-on extending MokoSuit - **Never commit** `.claude/`, `.mcp.json`, `TODO.md`, `*.min.css`/`*.min.js` - **Attribution**: `Authored-by: Moko Consulting` - **Workflow directory**: `.mokogitea/` -- **Wiki**: documentation lives in the Gitea wiki, not `docs/` files -- **Standards**: [MokoStandards](https://git.mokoconsulting.tech/MokoConsulting/MokoCLI/wiki) +- **Wiki**: documentation lives in the MokoGitea wiki, not `docs/` files +- **Standards**: [MokoStandards](https://git.mokoconsulting.tech/MokoConsulting/.mokogitea/wiki) - **Changelog**: `[Unreleased]` only β€” release system assigns versions - **No upstream references**: never reference competitor products diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md index ef34ec0..f4ae23f 100644 --- a/CODE_OF_CONDUCT.md +++ b/CODE_OF_CONDUCT.md @@ -14,7 +14,7 @@ DEFGROUP: Template-Joomla INGROUP: Template-Joomla.Documentation REPO: https://github.com/mokoconsulting-tech/Template-Joomla/ - VERSION: 01.00.32 + VERSION: 01.00.40 PATH: ./CODE_OF_CONDUCT.md BRIEF: Community expectations and enforcement guidelines NOTE: Adapted with attribution from the Contributor Covenant v2.1 diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index c0b4858..d7df945 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -34,7 +34,7 @@ feature/* ──PR──> dev ──draft PR──> (renamed to rc) ──merge 7. **Merging to main** triggers the stable release pipeline: - Minor version bump (e.g., `02.09.xx` β†’ `02.10.00`) - Stability suffix stripped (clean version) - - Gitea release created with ZIP/tar.gz packages + - MokoGitea release created with ZIP/tar.gz packages - `updates.xml` updated (Joomla extensions) - `dev` branch recreated from `main` diff --git a/GOVERNANCE.md b/GOVERNANCE.md index f30836c..718e40e 100644 --- a/GOVERNANCE.md +++ b/GOVERNANCE.md @@ -19,12 +19,12 @@ DEFGROUP: mokoconsulting-tech.Template-Joomla INGROUP: MokoStandards.Governance REPO: https://github.com/mokoconsulting-tech/Template-Joomla - VERSION: 01.00.32 + VERSION: 01.00.40 PATH: /GOVERNANCE.md BRIEF: Project governance rules, roles, and decision process for Template-Joomla --> -[![MokoStandards](https://img.shields.io/badge/MokoStandards-04.00.04-blue)](https://github.com/mokoconsulting-tech/MokoStandards) +[![MokoStandards](https://git.mokoconsulting.tech/MokoConsulting/.mokogitea/wiki)](https://github.com/mokoconsulting-tech/MokoStandards) # Project Governance @@ -32,7 +32,7 @@ This document defines the governance model for the `Template-Joomla` repository within the `mokoconsulting-tech` organization. It is automatically maintained by -[MokoStandards](https://github.com/mokoconsulting-tech/MokoStandards) v04.00.04. +[MokoStandards](https://git.mokoconsulting.tech/MokoConsulting/.mokogitea/wiki) v04.00.04. Full governance policy is defined in the MokoStandards source repository: [docs/policy/GOVERNANCE.md](https://github.com/mokoconsulting-tech/MokoStandards/blob/main/docs/policy/GOVERNANCE.md) diff --git a/SECURITY.md b/SECURITY.md index 1e05ffc..bd502f4 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -23,7 +23,7 @@ DEFGROUP: Template-Joomla INGROUP: Template-Joomla.Documentation REPO: https://git.mokoconsulting.tech/MokoConsulting/Template-Joomla PATH: /SECURITY.md -VERSION: 01.00.32 +VERSION: 01.00.40 BRIEF: Security vulnerability reporting and handling policy --> diff --git a/automation/ci-issue-reporter.sh b/automation/ci-issue-reporter.sh index 65c47ba..42399d0 100644 --- a/automation/ci-issue-reporter.sh +++ b/automation/ci-issue-reporter.sh @@ -6,11 +6,11 @@ # # FILE INFORMATION # DEFGROUP: Automation.CI -# INGROUP: moko-platform.Automation -# REPO: https://git.mokoconsulting.tech/MokoConsulting/moko-platform +# INGROUP: mokocli.Automation +# REPO: https://git.mokoconsulting.tech/MokoConsulting/mokocli # PATH: /automation/ci-issue-reporter.sh # VERSION: 09.23.00 -# BRIEF: Creates or updates a Gitea issue when a CI gate fails. +# BRIEF: Creates or updates a MokoGitea issue when a CI gate fails. # Deduplicates by searching open issues with the "ci-auto" label # whose title matches the gate. If a matching issue exists, a comment # is appended instead of opening a duplicate. @@ -45,8 +45,8 @@ Optional: --workflow Workflow name for the issue title --repo owner/repo (default: \$GITHUB_REPOSITORY) --run-url URL to the CI run (auto-detected from env) - --token Gitea API token (default: \$GITEA_TOKEN) - --url Gitea base URL (default: \$GITEA_URL) + --token MokoGitea API token (default: \$GITEA_TOKEN) + --url MokoGitea base URL (default: \$GITEA_URL) EOF exit 1 } @@ -213,7 +213,7 @@ print(json.dumps({ ISSUE_NUM=$(echo "$RESPONSE" | grep -oP '"number":\s*\K[0-9]+' | head -1) if [[ -n "$ISSUE_NUM" ]]; then - # Apply label (separate call β€” more reliable across Gitea versions) + # Apply label (separate call β€” more reliable across MokoGitea versions) LABEL_ID=$(curl -sf \ -H "Authorization: token ${GITEA_TOKEN}" \ "${API}/labels" 2>/dev/null \ diff --git a/source/packages/com_mokosuiterealty/admin/language/en-GB/com_mokosuiterealty.sys.ini b/source/packages/com_mokosuiterealty/admin/language/en-GB/com_mokosuiterealty.sys.ini new file mode 100644 index 0000000..ccc45f2 --- /dev/null +++ b/source/packages/com_mokosuiterealty/admin/language/en-GB/com_mokosuiterealty.sys.ini @@ -0,0 +1,3 @@ +COM_MOKOSUITEREALTY="MokoSuite Realty" +COM_MOKOSUITEREALTY_SHORT="Realty" +COM_MOKOSUITEREALTY_XML_DESCRIPTION="MokoSuite Realty component." diff --git a/source/packages/com_mokosuiterealty/mokosuiterealty.xml b/source/packages/com_mokosuiterealty/mokosuiterealty.xml index 62e5676..dbeb545 100644 --- a/source/packages/com_mokosuiterealty/mokosuiterealty.xml +++ b/source/packages/com_mokosuiterealty/mokosuiterealty.xml @@ -5,10 +5,13 @@ 2026-06-23 Copyright (C) 2026 Moko Consulting. GPL-3.0-or-later - 01.00.32 + 01.00.40 Moko\Component\MokoSuiteRealty servicessrctmpl - COM_MOKOSUITEREALTY + COM_MOKOSUITEREALTY_SHORT + + en-GB/com_mokosuiterealty.sys.ini + diff --git a/source/packages/plg_system_mokosuiterealty/mokosuiterealty.xml b/source/packages/plg_system_mokosuiterealty/mokosuiterealty.xml index a65b01d..71fdcfa 100644 --- a/source/packages/plg_system_mokosuiterealty/mokosuiterealty.xml +++ b/source/packages/plg_system_mokosuiterealty/mokosuiterealty.xml @@ -8,7 +8,7 @@ GPL-3.0-or-later hello@mokoconsulting.tech https://mokoconsulting.tech - 01.00.32 + 01.00.40 8.3 PLG_SYSTEM_MOKOSUITEREALTY_DESC Moko\Plugin\System\MokoSuiteRealty diff --git a/source/packages/plg_webservices_mokosuiterealty/mokosuiterealty.xml b/source/packages/plg_webservices_mokosuiterealty/mokosuiterealty.xml index e908882..cddab3f 100644 --- a/source/packages/plg_webservices_mokosuiterealty/mokosuiterealty.xml +++ b/source/packages/plg_webservices_mokosuiterealty/mokosuiterealty.xml @@ -3,7 +3,7 @@ Web Services - MokoSuite Realty mokosuiterealty Moko Consulting - 01.00.32 + 01.00.40 GPL-3.0-or-later Moko\Plugin\WebServices\MokoSuiteRealty srcservices diff --git a/source/pkg_mokosuiterealty.xml b/source/pkg_mokosuiterealty.xml index 0c7c426..36ef50c 100644 --- a/source/pkg_mokosuiterealty.xml +++ b/source/pkg_mokosuiterealty.xml @@ -2,7 +2,7 @@ Package - MokoSuite Realty mokosuiterealty - 01.00.32 + 01.00.40 2026-06-21 Moko Consulting hello@mokoconsulting.tech diff --git a/source/script.php b/source/script.php new file mode 100644 index 0000000..38a6923 --- /dev/null +++ b/source/script.php @@ -0,0 +1,169 @@ +missingChildExtensions($adapter); + + if (!empty($missing)) + { + Factory::getApplication()->enqueueMessage( + '

MokoSuiteRealty did not install correctly.

' + . '

The following bundled extensions are missing: ' + . htmlspecialchars(implode(', ', $missing), ENT_QUOTES) . '

' + . '

Please uninstall MokoSuiteRealty and reinstall the full package.

', + 'error' + ); + + return; + } + + $this->warnMissingLicenseKey(); + } + + /** + * Verify every child extension declared in the package manifest actually landed in + * #__extensions. Returns readable labels of any that are missing. + * + * Matching per Joomla's #__extensions uniqueness: type = "type"; element = + * "id" (for plugins, strip a leading plg__); plugins also match + * folder = "group". + * + * FAILS OPEN: any error returns [] so a transient glitch never fakes a failure. + */ + private function missingChildExtensions($adapter): array + { + try + { + $manifest = $adapter->getParent()->getManifest(); + + if (!$manifest || !isset($manifest->files) || !isset($manifest->files->file)) + { + return []; + } + + $db = Factory::getDbo(); + $missing = []; + + foreach ($manifest->files->file as $file) + { + $attrs = $file->attributes(); + $id = isset($attrs['id']) ? (string) $attrs['id'] : ''; + $exType = isset($attrs['type']) ? (string) $attrs['type'] : ''; + + if ($id === '' || $exType === '') + { + continue; + } + + $group = isset($attrs['group']) ? (string) $attrs['group'] : ''; + $element = $id; + + // Plugin element in #__extensions is the id minus any leading plg__. + if ($exType === 'plugin' && $group !== '') + { + $prefix = 'plg_' . $group . '_'; + + if (strpos($element, $prefix) === 0) + { + $element = substr($element, \strlen($prefix)); + } + } + + $query = $db->getQuery(true) + ->select('COUNT(*)') + ->from($db->quoteName('#__extensions')) + ->where($db->quoteName('element') . ' = ' . $db->quote($element)) + ->where($db->quoteName('type') . ' = ' . $db->quote($exType)); + + if ($exType === 'plugin' && $group !== '') + { + $query->where($db->quoteName('folder') . ' = ' . $db->quote($group)); + } + + if ((int) $db->setQuery($query)->loadResult() === 0) + { + $label = trim((string) $file); + $missing[] = $label !== '' ? preg_replace('/\.zip$/i', '', $label) : $id; + } + } + + return $missing; + } + catch (\Throwable $e) + { + // Fail open β€” never fake a failure on a glitch. + return []; + } + } + + private function warnMissingLicenseKey(): void + { + try + { + $db = Factory::getDbo(); + $app = Factory::getApplication(); + + $query = $db->getQuery(true) + ->select([$db->quoteName('update_site_id'), $db->quoteName('extra_query')]) + ->from($db->quoteName('#__update_sites')) + ->where('(' . $db->quoteName('name') . ' LIKE ' . $db->quote('%MokoSuiteRealty%') + . ' OR ' . $db->quoteName('location') . ' LIKE ' . $db->quote('%MokoSuiteRealty%') . ')') + ->setLimit(1); + $db->setQuery($query); + $site = $db->loadObject(); + + if ($site) + { + $extraQuery = (string) ($site->extra_query ?? ''); + + if (!empty($extraQuery) && strpos($extraQuery, 'dlid=') !== false) + { + parse_str($extraQuery, $parsed); + + if (!empty($parsed['dlid'])) + { + return; + } + } + + $editUrl = 'index.php?option=com_installer&task=updatesite.edit&update_site_id=' . (int) $site->update_site_id; + } + else + { + $editUrl = 'index.php?option=com_installer&view=updatesites'; + } + + $app->enqueueMessage( + 'Moko Consulting License Key Required β€” ' + . 'No download key is configured. Updates will not be available until a valid license key is entered. ' + . 'Enter License Key', + 'warning' + ); + } + catch (\Throwable $e) + { + // Silent β€” avoid breaking install if update_sites query fails + } + } +}