In case you didn't know, Statamic - which is the CMS we use here at Laravel News - has built-in Git support. This makes so much sense for a flat-file CMS because it means that changes can be kept in sync usually without much fuss. Statamic's Git Automation provides you with automatic commits and pushing capabilities right out of the box.
Statamic also has Revisions, which is a purpose-built, opt-in revision management feature. This doesn't build on top of Git's version control, but uses a separate datastore to keep a track of changes.
Both of these are Pro features, which means you'll need Statamic Pro to use them.
If you're a lone wolf running your own site or a handful of client sites, this can help massively to keep things up to date between production and development, which makes fixing pesky bugs much easier - you no longer need to sync databases or worry about missing files.
And Revisions allows you to see what's changed, when and by whom, and roll back if you need to.
But for teams and individuals looking for a higher degree of control over their version control processes, Gitamic, by long-time Laravel developer and Statamic supporter Simon Hamp, has emerged as the essential add-on. Here's a deep dive into how Gitamic's manual controls offer more power and flexibility than Statamic's built-in Git features.
Understanding Statamic's Built-in Version Control Capabilities
Statamic's built-in capabilities provide a fundamental layer of version control. With automatic commits and pushes, when enabled, every change made within the CMS gets logged and pushed to the connected Git repository without user intervention.
With Revisions enabled, every change is logged, and users can view, compare, and revert to previous versions.
Pros:
- Effortless Version Control: Every change is automatically saved, ensuring nothing is lost.
- Streamlined Workflow: Content editors and developers can work without needing to worry about the technicalities of version control.
- Accessible: These features are either completely invisible or within arm's reach, right on the entry edit screen.
Cons:
- Lack of Granularity: Automatic commits mean that users can't group related changes or provide detailed commit messages.
- Reduced Oversight: Without manual control, it's challenging to review or bundle changes before pushing them to the main branch or remote repository.
- Limited Availability: Revisions only work for entries at the moment.
- Premium Price Point: Both require a Statamic Pro license.
In many cases, Statamic's built-in Git Automation and Revisions will be more than enough for your needs. But on occasion, you may find yourself in a more complex setup that requires more control and flexibility.
Gitamic's Manual Controls: Enhancing Power & Flexibility
1. Commit with Precision:
Gitamic allows users to select specific changes for committing. This is a boon for those who want to make related changes across various parts of a site and then group them into a single commit. This precision helps in better tracking and understanding the evolution of the project.
2. Detailed Commit Messages:
While automatic commits provide convenience, they often lack context. With Gitamic, users can provide detailed commit messages, ensuring that every change has a clear, understandable context for future reference.
3. Review Before Pushing:
Gitamic gives users an opportunity to review in detail all changes before they're pushed. This means users can review, modify, or even revert updates, ensuring only the desired changes make it to the main branch or remote repository.
4. Staging Area:
Gitamic makes full use of Git's staging area, offering users the ability to stage and unstage changes - even at the chunk level, not just at the file level! This is particularly useful when working on larger updates or when collaborating with a team.
Staged changes can easily be reviewed, adjusted, and combined, offering a layer of flexibility not available with automatic commits.
5. Pull Changes with Insight:
Gitamic's manual pull feature allows users to view incoming changes before integrating them, which may help ensure there are no unexpected modifications or potential conflicts.
While Statamic's built-in Git functionalities serve as a great starting point, especially for those new to version control, Gitamic elevates the experience. It provides the control, granularity, and flexibility that power users and teams need to manage their projects effectively.
In essence, Gitamic doesn't just add manual controls—it brings the full power of Git to the Statamic Control Panel, allowing users to harness the best of both worlds. Whether you're a solo developer looking for precision or a team aiming for streamlined collaboration, Gitamic's manual controls are the game-changer you've been waiting for.
Filed in: