Entries Tagged with: Mercurial
Local Branching with Mercurial
As you may or may not know, at EllisLab, we use Mercurial for our source control management. When we moved to hg from SVN, we were highly critical of what system we wanted to use, and spent a good amount of time looking into the different distributed version control systems out there. In the end, we found that Mercurial suits us best.
When we were on SVN, I used git-svn, as I love the ability to branch locally, hack away—committing often, then merge & push to the 'blessed repository.' One of my struggles in moving to Mercurial, is that there ...
Deploy ExpressionEngine with Fabric
A lot of people use Capistrano and GitHub for their ExpressionEngine deploys, I wanted to show an alternative, BitBucket and Fabric.
There isn't quite the level of automagic in Fabric as with Capistrano, but being a sys admin, automagic scares the shit out of me. Anyhoo, I posted yesterday about developing on the CodeIgniter trunk, and in my base repository I linked to, I have a file in the base named fabfile.py. If you keep a similar repository setup to what I have, this will work splendidly for you. If you don't, you'll need to tweak ...
Developing on the CodeIgniter Trunk
Earlier this evening, Kenny Meyers posed a question on Twitter about how to develop with CodeIgniter while working off the trunk. With Mercurial, it's easy.
We'll use a mercurial sub-repository so CodeIgniter is running off the EllisLab CodeIgniter repository. In fact, I created a quick repository over at BitBucket to help me easily start a new project.
Here is my basic project directory structure.
│ ├── config
│ ├── controllers
│ ├── core
│ ├── errors
│ ├── helpers
│ ├── hooks
│ ├── index.html
│ ├── language
│ ├── libraries
│ ├── models
│ ├── third_party
│ └── views
│ ├── application
│ ├── index.php
│ ├── license.txt
│ ├── system
│ └── user_guide
├── images ...
PHP Lint Mercurial Extension
Here's a quick Mercurial extension that enables a PHP programmer to do a quick syntax check on files to be committed. It'll help you in a couple of ways.
- Catch some blatant errors before you push.
- Save money. Don't you have to purchase team members a beer every time you commit with errors?
Get it at BitBucket
Count number of commits users have in mercurial
A quick command line tip to return a list of every committer in a mercurial repository, as well as the number of commits they have.
hg log | grep '^user\?'|cut -d':' -f2|sort|uniq -c|sort -nr
Make it an alias in your ~/.bash_profile so you don't have to remember.