1 Installation instructions
2 =========================
5 Download a tarball from http://jonas.nitro.dk/tig/releases[] or clone the Tig
6 repository http://github.com/jonas/tig[git://github.com/jonas/tig.git].
8 NB: Do not use tig-2.0.tar because it will fail to compile due to these issues https://github.com/jonas/tig/pull/283 and https://github.com/jonas/tig/issues/337
10 The quick and simple way to install Tig is:
15 By default, `tig` is installed in `$HOME/bin`. To install `tig` elsewhere set
16 `prefix` to the desired path:
18 $ make prefix=/usr/local
19 $ sudo make install prefix=/usr/local
21 Documentation files, such as manpages, are distributed in the release tarballs,
22 and can be installed using:
26 When installing directly from the Tig repository, `make install-doc` will assume
27 that the documentation tool chain is available and build the documentation
28 locally. In case you do not wish to install the required tools, documentation
29 can be installed from the 'release' branch using:
31 $ make install-release-doc
33 Before upgrading, you are advised to read link:NEWS.{docext}[the release notes].
35 Installation using `configure`
36 ------------------------------
38 Optionally, you can use the `configure` script to detect dependencies:
44 If your `iconv` library is not in the default library and include path, you need
45 to pass the `--with-libiconv` option to `configure` to tell it where to look.
47 Note, if you are building from the Tig repository, you need to generate
48 `configure` yourself. First, ensure that `autoconf` is installed on your system,
49 and then run the following command:
53 Installation using Homebrew
54 ---------------------------
55 You can use link:http://brew.sh[Homebrew] to install Tig on OS X:
59 Installation on Windows
60 -----------------------
61 To run on Windows, you will need link:https://www.cygwin.com/[cygwin].
62 You must then install the packages `git`, `gcc-core`, `make`, `libiconv-devel`
63 and `libncurses-devel`. Extract the tarball and install by using `configure`
66 If you want to install from the sources, then you will also need the `automake`
67 package (which will also install `autoconf`). Then run `make configure` and install
68 by using `configure` as explained above.
73 Build settings are read from the file `config.make` and for certain systems also
74 from `contrib/config.make-$kernel`. An example of the latter is Mac OS X, where
75 `contrib/config.make-Darwin` provides out-of-the-box configuration for using the
76 system ncurses library and linking with the iconv library. This makes it easy to
77 configure the build without having to use the `configure` script. As a side
78 note, `configure` itself generates a `config.make` file.
80 Apart from the different standard `make` build variables (`CC`, `CFLAGS`, etc.)
81 and standard `configure` variables (`prefix`, `bindir`, etc.), build settings
82 can be one of the following flags:
84 - `NO_SETENV`: Define this variable to enable work-around for missing
86 - `NO_MKSTEMPS`: Define this variable to enable work-around for missing
88 - `NO_BUILTIN_TIGRC`: Reduce the size of the binary by not including a
89 built-in tigrc. The built-in tigrc is used as a fallback when no
90 `tigrc` is found in the system configuration directory (e.g. `/etc`).
92 The following example `config.make` manually configures Tig to use the ncurses
93 library with wide character support and include the proper ncurses header file
94 (see tig.h for more information):
97 CPPFLAGS = -DHAVE_NCURSESW_CURSES_H
99 For more examples of build settings, see `contrib/config.make` and
105 The following tools and packages are needed:
107 [cols="2<,8<",options="header"]
108 |=============================================================================
110 |git-core |Tig is just a frontend for Git.
111 |ncurses or ncursesw |Be sure to have the development files
112 installed. Usually they are available in a
113 separate package ending with `-dev`.
115 Ncurses with wide character support (ncursesw)
116 is required to properly handle UTF-8 encoded
119 Note for packagers: For Tig's `configure`
120 script to work as expected you should avoid
121 configuring and building ncurses using
123 |iconv |If iconv is not provided by the c library
124 you need to change the Makefile to link it
126 |=============================================================================
128 The following tools and packages are optional and mainly needed for creating the
129 configure script and building documentation:
131 [cols="2<,8<",options="header"]
132 |=============================================================================
134 |readline |Adds support for completion and history in
135 search and command prompts.
136 |autoconf |Contains autoreconf for generating configure
138 |asciidoc (>= 8.4) |Generates HTML and (DocBook) XML from text.
139 |xmlto |Generates manpages and chunked HTML from XML.
140 |DocBook XSL (>= 1.72.0) |Used by xmlto for building manpages.
141 |DocBook (DSSL/Jade) tools |Generates PDF from XML.
142 Also known as docbook-utils.
143 |=============================================================================