Files
MokoOnyx/docs/QUICK_START.md
Jonathan Miller 8258ed804a
Some checks failed
Standards Compliance / Secret Scanning (push) Successful in 3s
Standards Compliance / License Header Validation (push) Successful in 4s
Standards Compliance / Repository Structure Validation (push) Successful in 5s
Standards Compliance / Coding Standards Check (push) Failing after 3s
Standards Compliance / Version Consistency Check (push) Successful in 3s
Standards Compliance / Workflow Configuration Check (push) Failing after 2s
Standards Compliance / Documentation Quality Check (push) Successful in 3s
Standards Compliance / README Completeness Check (push) Successful in 3s
Standards Compliance / Git Repository Hygiene (push) Successful in 2s
Standards Compliance / Script Integrity Validation (push) Successful in 4s
Standards Compliance / Line Length Check (push) Failing after 4s
Standards Compliance / File Naming Standards (push) Successful in 2s
Standards Compliance / Insecure Code Pattern Detection (push) Successful in 3s
Standards Compliance / Code Complexity Analysis (push) Successful in 3s
Standards Compliance / Code Duplication Detection (push) Successful in 4s
Standards Compliance / Dead Code Detection (push) Successful in 3s
Standards Compliance / File Size Limits (push) Successful in 2s
CodeQL Security Scanning / Analyze (javascript) (push) Failing after 1m9s
Standards Compliance / Binary File Detection (push) Successful in 4s
CodeQL Security Scanning / Analyze (actions) (push) Failing after 1m11s
Standards Compliance / TODO/FIXME Tracking (push) Successful in 3s
Standards Compliance / Dependency Vulnerability Scanning (push) Successful in 5s
Standards Compliance / Broken Link Detection (push) Successful in 5s
Standards Compliance / Unused Dependencies Check (push) Successful in 7s
Standards Compliance / API Documentation Coverage (push) Successful in 3s
Standards Compliance / Accessibility Check (push) Successful in 3s
Standards Compliance / Performance Metrics (push) Successful in 3s
Standards Compliance / Enterprise Readiness Check (push) Successful in 3s
Standards Compliance / Repository Health Check (push) Successful in 4s
Standards Compliance / Terraform Configuration Validation (push) Successful in 6s
CodeQL Security Scanning / Security Scan Summary (push) Successful in 1s
Standards Compliance / Compliance Summary (push) Successful in 1s
Repo Health / Access control (push) Successful in 1s
Auto-Update SHA Hash / Update SHA-256 Hash in updates.xml (release) Successful in 4s
Repo Health / Release configuration (push) Failing after 3s
Repo Health / Scripts governance (push) Successful in 3s
Repo Health / Repository health (push) Failing after 3s
MokoOnyx v01.00.00 — initial release (successor to MokoCassiopeia)
All files renamed from mokocassiopeia to mokoonyx.
Update server points to MokoOnyx repo.
Bridge migration removed (clean standalone template).
Version reset to 01.00.00.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-19 17:19:03 -05:00

7.7 KiB

Quick Start Guide - MokoOnyx Development

Get up and running with MokoOnyx development in minutes.

Prerequisites

Before you begin, ensure you have:

  • Git - For version control
  • PHP 8.0+ - Required runtime
  • Composer - PHP dependency manager
  • Make (optional) - For convenient commands
  • Code Editor - VS Code recommended (tasks pre-configured)

5-Minute Setup

1. Clone the Repository

git clone https://git.mokoconsulting.tech/MokoConsulting/MokoOnyx.git
cd MokoOnyx

2. Install Development Dependencies

# Using Make (recommended)
make dev-setup

# Or manually
composer global require "squizlabs/php_codesniffer:^3.0"
composer global require phpstan/phpstan
composer global require "phpcompatibility/php-compatibility:^9.0"
composer global require codeception/codeception

3. Validate Everything Works

# Quick validation
make validate-required

# Or comprehensive validation
make validate

Common Tasks

Development Workflow

# 1. Make your changes
vim src/index.php

# 2. Validate locally
make validate-required

# 3. Check code quality
make quality

# 4. Commit
git add -A
git commit -m "feat: add new feature"
# (pre-commit hook runs automatically)

# 5. Push
git push origin your-branch

Testing

# Run all tests
make test

# Run unit tests only
make test-unit

# Run acceptance tests only
make test-acceptance

Code Quality

# Check everything
make quality

# PHP CodeSniffer only
make phpcs

# Auto-fix PHPCS issues
make phpcs-fix

# PHPStan only
make phpstan

# PHP compatibility check
make phpcompat

Creating a Release Package

# Package with auto-detected version
make package

# Check package contents
ls -lh dist/
unzip -l dist/mokoonyx-*.zip

VS Code Integration

If using VS Code, press Ctrl+Shift+P (or Cmd+Shift+P on Mac) and type "Run Task" to see available tasks:

  • Validate All - Run all validation scripts (default test task)
  • Validate Required - Run only required validations
  • PHP CodeSniffer - Check code style
  • PHP CodeSniffer - Auto Fix - Fix code style issues
  • PHPStan - Static analysis
  • Run Tests - Execute all tests
  • Create Package - Build distribution ZIP
  • Install Git Hooks - Set up pre-commit hooks

Available Make Commands

Run make help to see all available commands:

make help              # Show all commands
make dev-setup         # Complete environment setup
make validate          # Run all validations
make test              # Run all tests
make quality           # Check code quality
make package           # Create distribution package
make clean             # Remove generated files
make check             # Quick check (validate + quality)
make all               # Complete build pipeline

Project Structure

moko-cassiopeia/
├── src/                      # Joomla template source (template root)
│   ├── component.php         # Component template file
│   ├── index.php             # Main template file
│   ├── offline.php           # Offline page template
│   ├── error.php             # Error page template
│   ├── templateDetails.xml   # Template manifest
│   ├── html/                 # Module & component overrides
│   ├── media/                # Assets (CSS, JS, images, fonts)
│   ├── language/             # Frontend language files (en-GB, en-US)
│   └── administrator/        # Backend files
│       └── language/         # Backend language files
├── tests/                    # Test suites
├── docs/                     # Documentation
├── scripts/                  # Build scripts
├── .github/workflows/        # CI/CD workflows
├── Makefile                  # Make commands
└── README.md                 # Project overview

Next Steps

Learning the Workflow

  1. Read the Workflow Guide: docs/WORKFLOW_GUIDE.md
  2. Review Joomla Development: docs/JOOMLA_DEVELOPMENT.md

Creating Your First Feature

  1. Create a version branch via GitHub Actions:

    • Go to Actions → Create version branch
    • Enter version (e.g., 03.06.00)
    • Select branch prefix: dev/
    • Run workflow
  2. Checkout the branch:

    git fetch origin
    git checkout dev/03.06.00
    
  3. Make changes and test:

    # Edit files
    vim src/index.php
    
    # Validate
    make validate-required
    
    # Check quality
    make quality
    
  4. Commit and push:

    git add -A
    git commit -m "feat: your feature description"
    git push origin dev/03.06.00
    
  5. Watch CI: Check GitHub Actions for automated testing

Understanding the Release Process

Development → RC → Stable → Production
  (dev/)     (rc/)  (version/)  (main)
  1. dev/X.Y.Z - Active development
  2. rc/X.Y.Z - Release candidate testing
  3. version/X.Y.Z - Stable release
  4. main - Production (auto-merged from version/)

Use the Release Pipeline workflow to promote between stages.

Troubleshooting

Scripts Not Executable

make fix-permissions
### PHPStan/PHPCS Not Found

```bash
make install
# Or manually:
composer global require "squizlabs/php_codesniffer:^3.0" phpstan/phpstan

CI Workflow Fails

  1. Check the workflow logs in GitHub Actions
  2. Run validation locally:
    make validate-required
    make quality
    

Need Help?

  • Documentation: Check docs/ directory
  • Issues: Open an issue on GitHub
  • Contributing: See CONTRIBUTING.md

Best Practices

Before Committing

# Always validate first
make validate-required

# Check quality for PHP changes
make quality

# Run tests if you changed functionality
make test

Code Style

  • Follow PSR-12 standards
  • Use make phpcs-fix to auto-fix issues
  • Add SPDX license headers to new files
  • Keep functions small and focused

Documentation

  • Update docs when changing workflows
  • Add comments for complex logic
  • Update CHANGELOG.md with changes
  • Keep README.md current

Version Management

  • Use semantic versioning: Major.Minor.Patch (03.06.00)
  • Update CHANGELOG.md with all changes
  • Follow the version hierarchy: dev → rc → version → main
  • Never skip stages in the release process

Useful Resources

Quick Reference Card

# Setup
make dev-setup              # Initial setup

# Development
make validate-required      # Quick validation
make quality               # Code quality
make test                  # Run tests

# Building
make package               # Create ZIP

# Maintenance
make clean                 # Clean generated files
make fix-permissions       # Fix script permissions

# Help
make help                  # Show all commands

Metadata

Revision History

Date Change Summary Author
2026-01-30 Updated metadata to MokoStandards format GitHub Copilot
2025-01-04 Initial quick start guide created GitHub Copilot