WordPress theme development repository for the RMIT Learning Lab website.
- Node.js v20+ (uses
.nvmrc
for version management) - npm or yarn
- Local WordPress development environment (e.g., Local by Flywheel, MAMP, XAMPP)
- PHP 7.4+ (WordPress requirement)
- MySQL 5.7+ or MariaDB 10.3+
git clone https://github.com/yourusername/ll-wordpress-theme.git
cd ll-wordpress-theme
# If you have nvm installed, use the correct Node version
nvm use
# Install dependencies
npm install
- Install WordPress 6.8.2 in your local environment
- Copy the theme files to your WordPress installation:
cp -r wp-content/themes/* /path/to/wordpress/wp-content/themes/
- Activate the "RMIT Learning Lab" theme in WordPress admin
# Watch and compile SASS during development
npm run dev
# Build production CSS (minified)
npm run build
# Clean generated CSS files
npm run clean
npm run dev
– Watch SASS files and auto-compile on changes (alias forwatch
)npm run build
– Build compressed CSS with source maps (alias forsass
)npm run sass
– Single compile with compressed output and source mapsnpm run watch
– Watch SASS files and auto-compile on changesnpm run clean
– Remove generated CSS filesnpm run db:prod
/npm run db:dev
– Run the database sync helper for the specified environmentnpm run plugins:prod
/npm run plugins:dev
– Rsync remote plugins down to the local installnpm run site-sync:prod
/npm run site-sync:dev
– Orchestrate both database and plugin syncs sequentially
The sync commands read configuration from
.env
; see the sync workflow section below before running them.
ll-wordpress-theme/
├── wp-content/
│ └── themes/
│ ├── picostrap5/ # Parent theme (Bootstrap 5 base)
│ └── rmit-learning-lab/ # Child theme (main development)
│ ├── sass/ # SASS source files
│ │ ├── main.scss # Main SASS entry point
│ │ ├── design-system/# Design system components
│ │ └── learning-lab/ # Site-specific styles
│ ├── css-output/ # Compiled CSS output
│ │ └── bundle.css # Main compiled CSS
│ ├── js/ # JavaScript files
│ ├── includes/ # Modular PHP functionality
│ │ ├── admin-customizations.php
│ │ ├── analytics-dashboards.php
│ │ ├── breadcrumbs-navigation.php
│ │ ├── content-filters.php
│ │ ├── custom-shortcodes.php
│ │ ├── custom-taxonomy.php
│ │ ├── helper-utils.php
│ │ ├── json-export.php
│ │ ├── redirect.php
│ │ └── seo-noindex-inheritance.php
│ ├── page-templates/ # Custom page templates
│ ├── custom-shortcodes/# Custom WordPress shortcodes
│ ├── acf-json/ # ACF field definitions
│ └── functions.php # Theme functions (modular)
├── package.json # Node dependencies and scripts
├── .nvmrc # Node version specification
└── README.md # This file
This is a WordPress child theme setup:
- Parent Theme: Picostrap5 (v3.1.0) - Provides Bootstrap 5.3.3 foundation
- Child Theme: RMIT Learning Lab (v3.1.0) - Custom implementation
- Edit SASS files in
wp-content/themes/rmit-learning-lab/sass/
- Main entry point is
sass/main.scss
- Site-specific styles go in
sass/learning-lab/
directory - Compiled output goes to
css-output/bundle.css
(compressed with source maps) - All builds produce consistent compressed CSS matching the parent theme compiler
The repository tracks:
- Child theme files (rmit-learning-lab)
- Parent theme files (picostrap5)
- Development configuration (package.json, .nvmrc)
- Custom sync tooling (
scripts/
,SYNC_GUIDE.md
)
The repository ignores:
- WordPress core files
- Plugin files
- Upload directories
- Build artifacts and source maps
- Local configuration files
- Laravel Herd - Modern PHP/MySQL local development
- Local by Flywheel - Simple WordPress local development
- MAMP/XAMPP - Traditional PHP/MySQL stack
- Create a local database
- Configure
wp-config.php
with your local database credentials - Never commit
wp-config.php
to version control
Operational scripts live in scripts/
and are documented in SYNC_GUIDE.md
.
- Copy
.env.example
to.env
and populate the WP Engine (or other host) credentials for each environment. - Use the npm scripts (or call the shell scripts directly) to pull the remote database and plugins locally.
- Summaries print after each run so you can confirm replacements, backups, and plugin changes at a glance.
See SYNC_GUIDE.md
for step-by-step instructions, prerequisites (WP-CLI, rsync, SSH), and troubleshooting tips.
This theme is hosted on WP Engine and uses GitHub Actions for automated deployment.
The repository includes a GitHub Actions workflow (.github/workflows/deploy.yml
) that automatically deploys theme changes to WP Engine environments on git pushes:
- main branch → Production environment
- develop branch → Development environment
- staging branch → Staging environment
-
Configure Secrets in GitHub:
- Go to your GitHub repository → Settings → Secrets and variables → Actions
- Add the following secrets:
WPE_SSHG_KEY_PRIVATE
: SSH private key for WP Engine accessWPE_ENV_PRD
: Production environment name (e.g.,yoursite-prd
)WPE_ENV_DEV
: Development environment name (e.g.,yoursite-dev
)WPE_ENV_STG
: Staging environment name (e.g.,yoursite-staging
)
-
SSH Key Setup:
- Generate an SSH key pair if you haven't already
- Add the public key to your WP Engine account
- Store the private key as
WPE_SSHG_KEY_PRIVATE
-
Deployment Process:
- Push changes to the appropriate branch
- GitHub Actions will automatically deploy the
wp-content/themes/
directory to WP Engine - Cache is cleared after each deployment
If needed, you can manually deploy using Cyberduck or another SFTP client:
- Connect to your WP Engine environment via SFTP
- Upload the
wp-content/themes/
folder to/wp-content/themes/
- Create a feature branch
- Make your changes
- Test locally
- Submit a pull request
For issues or questions, contact the Digital Learning Team at RMIT University.
GPL-2.0 (WordPress compatible)