Tag Archives: cvs

Mercurial and Upstream CVS with MQ

# Set up repo
cvs checkout repo
cd repo
hg init
>> .hgignore echo syntax: glob
>> .hgignore echo CVS/*
>> .hgignore echo .cvsignore
# Consult .cvsignore files
hg addremove
# Verify pending changes
hg commit -m "Upstream import."
hg init --mq
hg commit --mq -m "Initial import."

# Create patches
hg qnew -m MESSAGE PATCH
# Make changes
hg qrefresh -UD
# Repeat as needed

# Tag queue
hg qnew -m "Add tag TAG." TAG
>> .mqtags echo TAG
hg add .mqtags  # Only for the first tag
hg qrefresh -UD
# Now you can `hg qgoto TAG`

# Save queue
hg commit --mq -m MESSAGE

# Update from upstream
hg update qparent
cvs update
# Consult .cvsignore files
hg addremove
# Verify pending changes
hg commit -m "Upstream update."
hg update qtip
hg rebase
# Fix merge conflicts
hg commit --mq -m "Rebase to upstream."