Tuesday, June 18, 2013

How do I concatenate text files on Windows?

Strangely enough, I've had this same question asked of me twice within the last week, so I figured I'd post it here.

At the command prompt, use this command:
type *.txt > outfile

If you name outfile with the extension .txt, you'll actually wind up with stuff duplicated because the *.txt will cause the output file to be input, too!


Monday, June 17, 2013

What does dcommit stand for in git svn?

It took me some scrounging around to find it, and I don't remember where I did, but git svn dcommit means delta commit.

Git stores full versions of files (and relies on compression to make everything as a whole a manageable size), but SVN stores deltas, or differences between files.

So, when pushing your changes to an SVN repo, git has to build deltas out of all the commits you are sharing and then commit those to the SVN repo.

Saturday, June 01, 2013

Building Mercurial (hg) -- fatal error: Python.h: No such file or directory

The version of Mercurial you get using sudo apt-get install mercurial is a relatively old one. But, if you download it from http://mercurial.selenic.com/, you can get the latest. However, in a fresh install of Linux Mint, I got the following error when I tried to run sudo make install:
mercurial/base85.c:13:20: fatal error: Python.h: No such file or directory
compilation terminated.
To fix this, you need to install the python-dev package using:
sudo apt-get install python-dev
You'll need to install python-docutils, too. Then you can run make install.