Rollback & Versions
Version control and safe rollback for your BuildGreenfield projects
Version Control
Every change to your BuildGreenfield project is automatically versioned. This gives you:
- Complete change history: See what changed, when, and why
- Safe rollback: Revert to any previous state
- Change comparison: Diff view for all modifications
- Audit trail: Track who made what changes (Team plan)
How Versioning Works
Automatic Commits
Every time you request a change, BuildGreenfield:
- Analyzes the requested modification
- Generates or modifies code
- Runs automated tests
- Creates a version commit (if tests pass)
- Deploys a new preview
Each version includes:
- Complete code snapshot
- AI-generated commit message
- Test results
- Timestamp
- Author (user or AI agent)
Version Naming
Versions are labeled with:
- Semantic versioning: e.g.,
v0.1.0,v0.1.1,v1.0.0 - Timestamps: Exact creation time
- Tags: Optional custom tags (e.g.,
before-refactor,production-candidate)
Viewing Versions
Version History
Access version history from your project dashboard:
- Click “Versions” in the sidebar
- Browse chronological list of changes
- Click any version to view details
Version Details
Each version shows:
- Summary: AI-generated description of changes
- Modified Files: List of files changed
- Diff View: Side-by-side comparison
- Test Results: Pass/fail status with logs
- Preview URL: Link to deployed preview at this version
Rolling Back
When to Roll Back
Common scenarios:
- A change broke functionality
- Performance regression
- Unwanted feature addition
- Testing a previous state
How to Roll Back
Simple Rollback
- Go to Versions
- Find the version you want to restore
- Click “Rollback to this version”
- Confirm the action
The project instantly reverts to that state, including:
- All code files
- Database schema (structure, not data)
- Environment variables
- Configuration files
Data Considerations
⚠️ Important: Rollback affects code and schema, but not user data.
- Code: Fully restored ✅
- Database Schema: Rolled back ✅
- Database Data: Preserved ⚠️
- File Uploads: Preserved ⚠️
If the schema changed, you may need to migrate data manually.
Rollback Strategies
Safe Rollback
For production projects, use this approach:
- Tag Current Version:
production-stable - Test New Changes: On a preview deployment
- Deploy to Production: When confident
- Monitor: Watch logs and metrics
- Rollback if Needed: To
production-stabletag
Experimental Rollback
For development/testing:
- Save Checkpoint: Tag current version
- Try Changes: Experiment freely
- Compare: Check performance, behavior
- Keep or Revert: Based on results
Branching (Team Plan)
Team plan subscribers can create branches for parallel development.
Creating a Branch
- Go to Versions → Branches
- Click “New Branch”
- Name it (e.g.,
feature/new-dashboard) - Select starting point (current or specific version)
Working on Branches
Each branch has its own:
- Code state
- Preview deployment
- Version history
- Test environment
Merging Branches
When ready to merge:
- Go to Branches
- Click “Merge” on the source branch
- Select target branch (usually
main) - Review changes
- Confirm merge
Conflicts are automatically resolved when possible. Manual intervention required for complex conflicts.
Best Practices
Regular Tagging
Tag important versions:
production-v1.0
before-major-refactor
stable-working-state
demo-ready
Tags make it easy to find and restore critical states.
Descriptive Change Requests
When requesting changes, be specific:
✅ Good: “Add email validation to the signup form and show error messages inline”
❌ Bad: “Fix signup”
Better descriptions lead to better AI-generated commit messages.
Test Before Production
Always test changes on preview deployments:
- Request change
- Review generated code
- Test preview URL thoroughly
- Tag as
production-candidate - Deploy to production
Incremental Changes
Make small, focused changes rather than large, sweeping modifications:
- Easier to review
- Simpler to debug if issues arise
- Clearer version history
- More precise rollback
Version Retention
Versions are retained based on your plan:
| Plan | Retention | Storage |
|---|---|---|
| Free | 7 days | 500 MB |
| Pro | 30 days | 10 GB |
| Team | 90 days | 50 GB |
After retention period:
- Versions are archived
- Preview deployments are deleted
- Code diffs are compressed
- Restore from archive available (Team plan)
Advanced Features
Version Comparison
Compare any two versions:
- Go to Versions
- Select two versions
- Click “Compare”
- View side-by-side diff
Export Version
Download a specific version:
- Open version details
- Click “Export”
- Choose format (ZIP, Git bundle)
- Download
Schedule Rollback
Set a rollback to trigger automatically:
- Deploy a risky change
- Set rollback timer (e.g., 1 hour)
- If not manually confirmed, auto-rollback executes
Perfect for low-risk production deployments.
Troubleshooting
Rollback Failed
If rollback fails:
- Check error message in logs
- Verify database schema compatibility
- Contact support with version IDs
Lost Version
Versions are never truly deleted (within retention period):
- Go to Versions → Archived
- Find the version
- Restore if on Pro/Team plan
Merge Conflict
For complex merge conflicts:
- Review conflicting files
- Use “Manual Resolution” option
- Edit code directly in editor
- Commit resolved version
Next Steps
- Learn about Project Isolation
- Read about Workspaces & Projects
- Check the FAQ for common questions