Publishing & Development Automation
This repository includes automated workflows for packaging and releasing the Home Assistant plasmoid to the KDE Store.
🚀 Automated Release Process
Creating a Release
Method 1: Git Tags (Recommended)
git tag v2.1
git push origin v2.1
Method 2: Manual Trigger
- Go to repository Actions tab on GitHub
- Select “Create Plasmoid Release”
- Click “Run workflow”
- Enter version number
- Click “Run workflow”
What Happens Automatically
- ✅ Package Creation: Creates
.tar.gzand.zipfiles - ✅ Version Update: Updates
metadata.jsonwith new version - ✅ GitHub Release: Creates release with download links
- ✅ Upload Instructions: Provides step-by-step KDE Store guide
🏪 Publishing to KDE Store
After automation completes:
- Download the
.tar.gzfile from GitHub release - Login to store.kde.org
- Navigate to your plasmoid page
- Add new version and upload the package
- Publish the update
🧪 Local Development
Local Packaging
# Create development package
./package.sh
# Create specific version
./package.sh 2.1
Testing Installation
# Install locally for testing
kpackagetool6 --type Plasma/Applet --install home-assistant-plasmoid-2.0.tar.gz
# Remove after testing
kpackagetool6 --type Plasma/Applet --remove org.neiam.kde.homeassistant
🔧 Workflow Configuration
Repository Setup
The workflows require GitHub repository permissions:
- Go to Settings → Actions → General
- Under “Workflow permissions”:
- Select “Read and write permissions”
- Check “Allow GitHub Actions to create and approve pull requests”
- Click Save
Available Workflows
-
Release Workflow (
.github/workflows/release.yml)- Triggers: Git tags starting with
v - Creates packages and GitHub releases
- Provides KDE Store upload instructions
- Triggers: Git tags starting with
-
Validation Workflow (
.github/workflows/validate.yml)- Triggers: Push to main branches, PRs
- Validates plasmoid structure and metadata
- Checks QML syntax and package integrity
📋 Best Practices
Version Management
- Use semantic versioning:
v1.0.0,v1.1.0,v2.0.0 - Update version in
metadata.jsonbefore tagging - Write meaningful commit messages for changelog
Pre-Release Checklist
- Test plasmoid functionality locally
- Update README with new features
- Verify metadata.json version
- Run
./package.shto test packaging - Check QML syntax and structure
Release Process
- Development: Make changes and test locally
- Commit: Push changes to main branch
- Validation: Ensure validation workflow passes
- Tag: Create version tag to trigger release
- Upload: Download package and upload to KDE Store
🐛 Troubleshooting
GitHub Actions Issues
403 Permission Error:
- Update repository workflow permissions (see above)
- Ensure workflows have
permissions: contents: write
Package Creation Fails:
- Check required files exist (
metadata.json,contents/ui/main.qml) - Verify JSON syntax in metadata.json
- Review workflow logs for specific errors
Release Creation Fails:
- Verify tag format starts with
v(e.g.,v2.0) - Check repository permissions
- Ensure no existing release with same tag
Local Packaging Issues
Script Fails:
- Ensure
rsyncis installed - Check file permissions (
chmod +x package.sh) - Verify no syntax errors in script
Package Too Large:
- Review included files (check
.gitignore) - Remove unnecessary development files
- Optimize images and assets
KDE Store Upload Issues
Wrong Package Format:
- Use
.tar.gzfile, not.zip - Ensure proper directory structure inside package
Version Conflicts:
- Ensure version number is unique
- Match version in
metadata.jsonand store
Metadata Issues:
- Validate JSON syntax
- Ensure all required KPlugin fields present
- Check icon and category specifications
📖 Additional Resources
- KDE Store Documentation
- Plasma Applet Development Guide
- GitHub Actions Documentation
- KDE Community Resources
🔄 Future Enhancements
The automation system can be extended with:
- Automated changelog generation from commits
- Integration testing in different Plasma versions
- Automated screenshots for store listings
- Multi-platform package generation
- Automated dependency checking