I've been very happy using the versioning software Mercurial (hg) to backup Python code and keep it synchronized across platforms and installations. I can keep my whole Python development directory within the higher-level directory synchronized by mercurial and then access it on any platform. This is very useful when I am offline for long periods of time and want to work on whatever computer I have to hand.

When I tried the same thing recently with Eclipse and Netbeans directories, I found that there are many tiny files configuration files, history files, and so forth that are specific to each platform and installation, so that while the code itself can still be synchronized using Mercurial, these directories have to be kept *unsynchronized*, and the code files imported and exported to Eclipse and Netbeans manually each time one changes platform

My question is whether Postgresql databases behave more like directories of Python code or more like Eclipse and Netbeans directories in this respect. Can I safely synchronize a whole database installation or development directory, or must I export and reimport the data each time I am going to be working offline on a local machine?