# Package installation under OS X 10.6+

There is an installable, 64bit application. Download etm_qt-x.x.x.dmg from this site, open it and drag etm.app to your Applications folder. If you already have etm.app in your Applications folder, then you might want to rename the new version to something like etm_qt.app before moving it to Applications. Follow the instructions below to install Mercurial.

Since pyinstaller has not yet been ported to python 3, this application is built with python 2.7.3.

# Source installation under OS X, Linux or Windows

Python 2.7.3, 2.7.5 or python >= 3.3.0 is required.

The following python packages are required for etm but are not included in the python standard library:

- dateutil (1.5 is OK but >= 2.1 is strongly recommended)
- PyYaml (>= 3.10)

This package is used to export vcalendar files but is otherwise optional. It is not yet available for python 3:

- vobject (>= 0.8.1)

## Qt

http://qt-project.org/downloads - the build platform used 4.8.4.

You may not need to install Qt. Qt is a part of the standard package installation for Ubuntu 12 and possibly other linux distributions as well.

Binaries are available for windows and osx.

## SIP and PyQt4

Both SIP and PyQt4 are available from

    http://www.riverbankcomputing.com/software/pyqt/download

The following combinations have been tested:

1. python 2.7.3 or 2.7.5: Qt 4.8.4, SIP 4.14.1-2 and PyQt4 4.9.5

2. python 3.3.0 or 3.3.2: Qt 4.8.4, SIP 4.14.1-3 and PyQt 4.9.6 or 4.10

Install Qt, then SIP and finally PyQt4

For both SIP and PyQt, use the standard python installation process:

    python configure.py
    make
    sudo make install

Note: You will get either a 32bit or 64bit installation depending upon the version of python you use with `configure.py`. For example, you would use

    python3 configure.py

for both SIP and PyQt to get python 3 versions.

## installing etm

### option 1) use pip

    sudo pip install -U etm_qt

For an initial install, `-U` can be omitted.

### option 2) use easy_install

    sudo easy_install -U etm_qt

For an initial install, `-U` can be omitted.

### option 3) download and run setup.py

Download 'etm_qt-x.x.x.tar.gz' from this site, unpack the tarball, cd to the resulting directory and do the normal

    sudo python setup.py install

for a system installation. You can then run from any directory either

    $ etm_qt.py ?

for information about command line usage or

    $ etm_qt.py

to open the etm gui.

Alternatively, you can avoid doing a system installation and simply run either

    $ python etm_qt.py ?

or

    $ python etm_qt.py

from this directory.

# Installing Mercurial

Optional but strongly recommended!

Download Mercurial from

    http://mercurial.selenic.com/

install it and then create the file ~/.hgrc, if it doesn't already exist, with at least the following two lines:

    [ui]
    username = Your Name <your email address>

Mercurial is used to keep a record of changes to your etm data files.

# Previous etm users

Just to be safe, before you run etm the first time, make a copy of the entire directory:

    ~/.etm

The first time you run etm it will create, if necessary, the following:

    ~/.etm
    ~/.etm/etm.cfg
    ~/.etm/data

You can edit ~/.etm/etm.cfg to change the location of the data directory if you wish. You should choose a different location from your current data directory.

If you want to use your existing data files, make a copy of your current data directory (the directory specified by `etmdata` in ~/.etm/etmrc) and place it in

    ~/.etm/data

or whatever location you specified for `datadir` in ~/.etm/etm.cfg. Next download `one2two.py.txt` from this site, cd to the location of `datadir` and then execute

    $ python pathto/one2two.py.txt

This will traverse your data directory reading *.text files and displaying the item by item changes that the new format would entail. Run this script with `-m` appended:

    $ python pathto/one2two.py.txt -m

to actually write the items in the new format to *.txt files. Note that your existing files will not be changed. You can run this script again but it will overwrite any changes you have made to the new *.txt files.

If you follow these suggestions, your new etm installation will be completely independent of your current installation.

# New etm users

You can download files from the sample folder on this site and place them in your datadir, ~/.etm/data by default, to have some existing items when you start etm.

Now, if you have done the system installation, you can run

    $ etm_qt.py

from any directory to open the gui, or you can just execute

    $ python etm_qt.py

from the unpack directory to run etm without a system installation.

A good strategy is to look first at overview.html under help information on this web site and then the other help files there. This same information is available by pressing F1 in the etm gui. The file cheatsheet.pdf is intended to be a helpful reference.