Code

tig.git
18 years agoCSS fix: s/monospaced/monospace/
Jonas Fonseca [Wed, 14 Jun 2006 21:28:19 +0000 (23:28 +0200)]
CSS fix: s/monospaced/monospace/

18 years agoUse tables for the listing of default keybindings
Jonas Fonseca [Wed, 14 Jun 2006 21:26:06 +0000 (23:26 +0200)]
Use tables for the listing of default keybindings

18 years agoDocumentation update
Jonas Fonseca [Wed, 14 Jun 2006 20:28:10 +0000 (22:28 +0200)]
Documentation update

Brings tigrc(5) into sync. A small fix in INSTALL.

18 years agoAdd "Hash" key name mapped to "#"; Don't use ";" as a comment character
Jonas Fonseca [Wed, 14 Jun 2006 20:27:44 +0000 (22:27 +0200)]
Add "Hash" key name mapped to "#"; Don't use ";" as a comment character

18 years agoAllow strings to be enclosed in either ' or "
Jonas Fonseca [Wed, 14 Jun 2006 19:38:03 +0000 (21:38 +0200)]
Allow strings to be enclosed in either ' or "

So now you can use both:

set commit-encoding = "UTF-8"
set commit-encoding = 'UTF-8'
set commit-encoding =  UTF-8

18 years agoMake prompt use internal user input reader
Jonas Fonseca [Sat, 10 Jun 2006 22:49:17 +0000 (00:49 +0200)]
Make prompt use internal user input reader

This allows it to be used while loading. Also, it will make it possible to
support more advanced editing facilities like history, completion etc.
needed for future search support at least.

It's still very primitive ...

18 years agoMerge with ssh://diku/~/tig
Jonas Fonseca [Fri, 9 Jun 2006 11:15:07 +0000 (13:15 +0200)]
Merge with ssh://diku/~/tig

18 years agoConfig: improve error reporting and do a few cleanups and simplifications
Jonas Fonseca [Fri, 9 Jun 2006 00:08:28 +0000 (02:08 +0200)]
Config: improve error reporting and do a few cleanups and simplifications

18 years agoRename "encoding" option to "commit-encoding"
Jonas Fonseca [Thu, 8 Jun 2006 13:30:12 +0000 (15:30 +0200)]
Rename "encoding" option to "commit-encoding"

18 years agoInstall HTML files into $(prefix)/share/doc/tig
Jonas Fonseca [Thu, 8 Jun 2006 02:33:07 +0000 (04:33 +0200)]
Install HTML files into $(prefix)/share/doc/tig

18 years agoAdd ToC to the tig manual
Jonas Fonseca [Thu, 8 Jun 2006 02:32:00 +0000 (04:32 +0200)]
Add ToC to the tig manual

18 years agoMisc doc improvements
Jonas Fonseca [Thu, 8 Jun 2006 01:57:55 +0000 (03:57 +0200)]
Misc doc improvements

18 years agoAdd support for keybindings
Jonas Fonseca [Thu, 8 Jun 2006 00:03:16 +0000 (02:03 +0200)]
Add support for keybindings

The syntax is

bind <keymap> <key> <request>

Keybindings are resolved by first looking in the keymap of the active view,
then in the generic keymap, and finally in the built-in default keybindings.

Examples to put in ~/.tigrc:

bind main w scroll-line-up
bind main s scroll-line-down
bind diff a previous
bind diff d next
bind diff b move-first-line
bind generic g view-next

18 years agoRename keymap to keybinding, get_request to get_keybinding
Jonas Fonseca [Wed, 7 Jun 2006 23:52:50 +0000 (01:52 +0200)]
Rename keymap to keybinding, get_request to get_keybinding

18 years agoAdd default configuration file
Jonas Fonseca [Wed, 7 Jun 2006 22:14:43 +0000 (00:14 +0200)]
Add default configuration file

18 years agoAdd special string comparer for gracefully parsing ~/.tigrc identifiers
Jonas Fonseca [Wed, 7 Jun 2006 22:05:55 +0000 (00:05 +0200)]
Add special string comparer for gracefully parsing ~/.tigrc identifiers

18 years agoEstablish "Open view" section
Jonas Fonseca [Wed, 7 Jun 2006 00:07:47 +0000 (02:07 +0200)]
Establish "Open view" section

18 years agoRename load_help_page to open_help_view and move it up
Jonas Fonseca [Wed, 7 Jun 2006 00:06:01 +0000 (02:06 +0200)]
Rename load_help_page to open_help_view and move it up

Also use view->ops->read() instead of pager_read().

18 years agoMove keybinding stuff up after line stuff
Jonas Fonseca [Tue, 6 Jun 2006 23:55:10 +0000 (01:55 +0200)]
Move keybinding stuff up after line stuff

18 years agoSupport set command in ~/.tigrc; allows a few options to be configured
Jonas Fonseca [Tue, 6 Jun 2006 23:49:51 +0000 (01:49 +0200)]
Support set command in ~/.tigrc; allows a few options to be configured

18 years agoSimplify the option value tokenization by doing it one place
Jonas Fonseca [Tue, 6 Jun 2006 23:15:46 +0000 (01:15 +0200)]
Simplify the option value tokenization by doing it one place

18 years agoFactor out set_option_color from set_option
Jonas Fonseca [Tue, 6 Jun 2006 22:43:24 +0000 (00:43 +0200)]
Factor out set_option_color from set_option

18 years agoMake declaration of die() specify the __NORETURN attribute
Jonas Fonseca [Tue, 6 Jun 2006 22:26:27 +0000 (00:26 +0200)]
Make declaration of die() specify the __NORETURN attribute

Avoids warnings with gcc 3.3.5.

18 years agoImprove error reporting for unknown options
Jonas Fonseca [Tue, 6 Jun 2006 11:35:25 +0000 (13:35 +0200)]
Improve error reporting for unknown options

It will now also show usage help.

18 years agoAdd feature request for showing nearest branch heads or tags for a commit
Jonas Fonseca [Mon, 5 Jun 2006 22:29:22 +0000 (00:29 +0200)]
Add feature request for showing nearest branch heads or tags for a commit

Requested by Junio.

18 years agoMakefile: make customization of installation locations easier
Junio C Hamano [Mon, 5 Jun 2006 00:11:05 +0000 (02:11 +0200)]
Makefile: make customization of installation locations easier

Signed-off-by: Junio C Hamano <junkio@cox.net>
Signed-off-by: Jonas F Madsen <fonseca@diku.dk>
18 years agoMake the view title show percentage shown like less
Jonas Fonseca [Sun, 4 Jun 2006 00:46:30 +0000 (02:46 +0200)]
Make the view title show percentage shown like less

The cursor position is already summoned up as "line x of X".

18 years agoImplement the basic controlling of revision graph visualization
Jonas Fonseca [Sat, 3 Jun 2006 23:53:32 +0000 (01:53 +0200)]
Implement the basic controlling of revision graph visualization

It is toggleable via 'g', on by default, and restricted to max being 19
chars wide. Note, it still only shows just the left tee.

18 years agoAdd strip rule
Jonas Fonseca [Sat, 3 Jun 2006 22:41:38 +0000 (00:41 +0200)]
Add strip rule

18 years agoDon't begin any update for the built-in help page
Jonas Fonseca [Thu, 1 Jun 2006 02:48:32 +0000 (04:48 +0200)]
Don't begin any update for the built-in help page

18 years agoMore color and attribute maps closer to the users
Jonas Fonseca [Thu, 1 Jun 2006 02:12:48 +0000 (04:12 +0200)]
More color and attribute maps closer to the users

18 years agoSimplify detection of tag commits via ^{}
Jonas Fonseca [Thu, 1 Jun 2006 02:08:44 +0000 (04:08 +0200)]
Simplify detection of tag commits via ^{}

18 years agoMinor tidyup
Jonas Fonseca [Thu, 1 Jun 2006 02:05:02 +0000 (04:05 +0200)]
Minor tidyup

18 years agoGeneralize the option parsing
Jonas Fonseca [Thu, 1 Jun 2006 01:36:35 +0000 (03:36 +0200)]
Generalize the option parsing

18 years agoMove tig(1) material to tig.1.txt
Jonas Fonseca [Thu, 1 Jun 2006 00:16:16 +0000 (02:16 +0200)]
Move tig(1) material to tig.1.txt

18 years agoCorrect error checking
Jonas Fonseca [Wed, 31 May 2006 23:41:52 +0000 (01:41 +0200)]
Correct error checking

Fixes: cc2d13642a837163fb0e35d87a51ff96b7bf3cb0
18 years agoRemove prev arg to view->ops->read()
Jonas Fonseca [Wed, 31 May 2006 23:37:30 +0000 (01:37 +0200)]
Remove prev arg to view->ops->read()

18 years agoWrap all snprintf usage to simplify error handling
Jonas Fonseca [Wed, 31 May 2006 21:16:38 +0000 (23:16 +0200)]
Wrap all snprintf usage to simplify error handling

18 years agoAdd support for showing tags and other repo refs in the diff and log view
Jonas Fonseca [Wed, 31 May 2006 20:47:46 +0000 (22:47 +0200)]
Add support for showing tags and other repo refs in the diff and log view

18 years agoRefactor view->line reallocation
Jonas Fonseca [Wed, 31 May 2006 20:14:34 +0000 (22:14 +0200)]
Refactor view->line reallocation

18 years agoMake 'h' and '?' show built-in key binding quick reference
Jonas Fonseca [Wed, 31 May 2006 19:07:13 +0000 (21:07 +0200)]
Make 'h' and '?' show built-in key binding quick reference

18 years agoRename documentation build rules using s/docs/doc/; more like git
Jonas Fonseca [Tue, 30 May 2006 23:04:36 +0000 (01:04 +0200)]
Rename documentation build rules using s/docs/doc/; more like git

18 years agoAdd COPYING file
Jonas Fonseca [Tue, 30 May 2006 13:23:19 +0000 (15:23 +0200)]
Add COPYING file

18 years agoFix segfault where current_view would become >= sizeof(display)
Jonas Fonseca [Mon, 29 May 2006 21:29:38 +0000 (23:29 +0200)]
Fix segfault where current_view would become >= sizeof(display)

Hard code current_view indexes for split screen setup.

Reported-by: Dennis (dst_) on #git
18 years agoRemove SITES title so it is more adaptive to where it is included
Jonas Fonseca [Mon, 29 May 2006 19:37:24 +0000 (21:37 +0200)]
Remove SITES title so it is more adaptive to where it is included

18 years agoSplit out manual material to separate file
Jonas Fonseca [Mon, 29 May 2006 19:36:57 +0000 (21:36 +0200)]
Split out manual material to separate file

18 years agoList SITES in tig(1)
Jonas Fonseca [Mon, 29 May 2006 01:27:36 +0000 (03:27 +0200)]
List SITES in tig(1)

18 years agoMove stuff to SITES and INSTALL files
Jonas Fonseca [Mon, 29 May 2006 01:25:43 +0000 (03:25 +0200)]
Move stuff to SITES and INSTALL files

18 years agoMove stuff to BUGS and TODO files; only show BUGS in tig(1)
Jonas Fonseca [Mon, 29 May 2006 01:19:16 +0000 (03:19 +0200)]
Move stuff to BUGS and TODO files; only show BUGS in tig(1)

18 years agoMove ~/.tigrc documentation into it's own man page, tigrc(5)
Jonas Fonseca [Mon, 29 May 2006 01:15:20 +0000 (03:15 +0200)]
Move ~/.tigrc documentation into it's own man page, tigrc(5)

18 years agoUse ~/.tigrc for user configuration rather than ~/.tig
Jonas Fonseca [Mon, 29 May 2006 01:01:27 +0000 (03:01 +0200)]
Use ~/.tigrc for user configuration rather than ~/.tig

18 years agoAdd TODO about keybinding cheat sheet
Jonas Fonseca [Sun, 28 May 2006 21:51:48 +0000 (23:51 +0200)]
Add TODO about keybinding cheat sheet

Requested by gitster on IRC.

18 years agoEmit more informative error messages when loading ~/.tig
Jonas Fonseca [Sun, 28 May 2006 18:59:31 +0000 (20:59 +0200)]
Emit more informative error messages when loading ~/.tig

18 years agoOnly touch the option strings if necessary
Jonas Fonseca [Sun, 28 May 2006 18:19:32 +0000 (20:19 +0200)]
Only touch the option strings if necessary

18 years agoImprove color documentation
Jonas Fonseca [Sun, 28 May 2006 18:11:47 +0000 (20:11 +0200)]
Improve color documentation

18 years agoAdd support for setting color options in the ~/.tig user configuration file
Jonas Fonseca [Sun, 28 May 2006 14:38:32 +0000 (16:38 +0200)]
Add support for setting color options in the ~/.tig user configuration file

Now you can put stuff like this in ~/.tig:

# Diff colors
color diff-header yellow default
color diff-index blue default
color diff-chunk magenta default
# UI colors
color title-blur white blue
color title-focus white blue bold

18 years agoMake read_properties take several separator characters; chomp name & value
Jonas Fonseca [Sun, 28 May 2006 03:23:52 +0000 (05:23 +0200)]
Make read_properties take several separator characters; chomp name & value

This concludes the fundation for using read_properties to read options from
a config file.

18 years agoOops, fix short help wrt tab size short option
Jonas Fonseca [Sun, 28 May 2006 02:36:34 +0000 (04:36 +0200)]
Oops, fix short help wrt tab size short option

18 years agoRename repo config loaders using s/config/repo_config/
Jonas Fonseca [Sun, 28 May 2006 02:29:45 +0000 (04:29 +0200)]
Rename repo config loaders using s/config/repo_config/

load_config    -> load_repo_config
read_config_option -> read_repo_config_option

18 years agoMake read_properties() take FILE *pipe instead of command line
Jonas Fonseca [Sun, 28 May 2006 02:19:46 +0000 (04:19 +0200)]
Make read_properties() take FILE *pipe instead of command line

18 years agoDocument the loading time displayed in the title window after 3 seconds
Jonas Fonseca [Sun, 28 May 2006 02:19:08 +0000 (04:19 +0200)]
Document the loading time displayed in the title window after 3 seconds

18 years agoMake the stop all loading request stop all loading
Jonas Fonseca [Sun, 28 May 2006 01:55:31 +0000 (03:55 +0200)]
Make the stop all loading request stop all loading

18 years agoNotify that the prompt is unusable while loading
Jonas Fonseca [Sun, 28 May 2006 01:51:53 +0000 (03:51 +0200)]
Notify that the prompt is unusable while loading

List it as a bug.

18 years agoTab size short option changes from -t to -b
Jonas Fonseca [Sun, 28 May 2006 01:02:19 +0000 (03:02 +0200)]
Tab size short option changes from -t to -b

18 years agoMinor usability fix: when closing never switch to an already closed view
Jonas Fonseca [Sat, 27 May 2006 22:58:04 +0000 (00:58 +0200)]
Minor usability fix: when closing never switch to an already closed view

18 years ago"View commands" section becomes "History commands".
Jonas Fonseca [Sat, 27 May 2006 21:21:28 +0000 (23:21 +0200)]
"View commands" section becomes "History commands".

18 years agoLicense revisited: it's GPLv2 or later
Jonas Fonseca [Fri, 26 May 2006 21:47:23 +0000 (23:47 +0200)]
License revisited: it's GPLv2 or later

18 years agoFix off by one error; makes tags visible again
Jonas Fonseca [Fri, 26 May 2006 20:26:32 +0000 (22:26 +0200)]
Fix off by one error; makes tags visible again

Fixes: d0cea5f929be563d049bc5205fb8de08fd080c32
18 years agoWhen updating the title window, move the cursor to the end of line
Jonas Fonseca [Fri, 26 May 2006 20:09:50 +0000 (22:09 +0200)]
When updating the title window, move the cursor to the end of line

This way the cursor (hopefully) won't feel so jumpy.

18 years agoFactor out cursor moving
Jonas Fonseca [Fri, 26 May 2006 20:08:06 +0000 (22:08 +0200)]
Factor out cursor moving

18 years agoMake window switching smother; fix blurring of previous view when switching
Jonas Fonseca [Fri, 26 May 2006 19:12:43 +0000 (21:12 +0200)]
Make window switching smother; fix blurring of previous view when switching

Don't refresh after a resize, since it causes the previous content to be
shortly displayed. We now simply resize and clear and waits for the first
read to start displaying the new content.

18 years agoNever close backgrounded loads; only clear window when starting to update
Jonas Fonseca [Fri, 26 May 2006 18:02:01 +0000 (20:02 +0200)]
Never close backgrounded loads; only clear window when starting to update

Before windows was cleared each time open_view maximized for example the
main view when it was still loading.

18 years agoOnly pass on properies with non-zero length names
Jonas Fonseca [Wed, 24 May 2006 22:41:53 +0000 (00:41 +0200)]
Only pass on properies with non-zero length names

18 years agoRefactor reading of properties from pipes
Jonas Fonseca [Wed, 24 May 2006 21:57:52 +0000 (23:57 +0200)]
Refactor reading of properties from pipes

18 years agoLoad config before parsing command line options so they can override
Jonas Fonseca [Wed, 24 May 2006 21:12:28 +0000 (23:12 +0200)]
Load config before parsing command line options so they can override

18 years agoMake UTF-8 handling optional but still default
Jonas Fonseca [Wed, 24 May 2006 20:58:11 +0000 (22:58 +0200)]
Make UTF-8 handling optional but still default

Handling of output encoding still missing.

18 years agoAdd support for loading repo config
Jonas Fonseca [Wed, 24 May 2006 17:51:11 +0000 (19:51 +0200)]
Add support for loading repo config

Test it by storing i18n.commitencoding, soon to be uesd.

18 years agoCleanup see also section
Jonas Fonseca [Wed, 24 May 2006 15:18:33 +0000 (17:18 +0200)]
Cleanup see also section

18 years agoMove env handling up below option handling
Jonas Fonseca [Wed, 24 May 2006 15:16:41 +0000 (17:16 +0200)]
Move env handling up below option handling

18 years agoPut license also in the program header
Jonas Fonseca [Wed, 24 May 2006 15:01:16 +0000 (17:01 +0200)]
Put license also in the program header

18 years agoRearrange pager_enter logic
Jonas Fonseca [Wed, 24 May 2006 14:56:52 +0000 (16:56 +0200)]
Rearrange pager_enter logic

18 years agoUpdate README; set a less ugly font-family
Jonas Fonseca [Wed, 24 May 2006 02:32:36 +0000 (04:32 +0200)]
Update README; set a less ugly font-family

18 years agoIntroduce struct line and use it for view->line
Jonas Fonseca [Wed, 24 May 2006 01:23:43 +0000 (03:23 +0200)]
Introduce struct line and use it for view->line

Somewhat experimental. This will call get_line_type() on every read line.

18 years agoImprove title updating and remove flickering
Jonas Fonseca [Tue, 23 May 2006 22:29:24 +0000 (00:29 +0200)]
Improve title updating and remove flickering

 - Show line info even if no lines has been loaded, so less has to be
   redrawn.

 - Don't make the view window one line bigger causing the title window
   to be overwritten. This reinstates the bug in last line drawing.

18 years agoMake update reporting less verbose
Jonas Fonseca [Tue, 23 May 2006 21:54:55 +0000 (23:54 +0200)]
Make update reporting less verbose

It got too annoying when browsing through the split main/diff screen.
Instead put the update timer in the title window if it grows beyond
2 seconds.

18 years agoFix spurious resizing of the display (take 2)
Jonas Fonseca [Mon, 22 May 2006 22:19:27 +0000 (00:19 +0200)]
Fix spurious resizing of the display (take 2)

18 years agoAdd macro for getting number of displayed views
Jonas Fonseca [Mon, 22 May 2006 22:08:11 +0000 (00:08 +0200)]
Add macro for getting number of displayed views

18 years agoOnly resize the display when actually required
Jonas Fonseca [Sun, 21 May 2006 23:26:22 +0000 (01:26 +0200)]
Only resize the display when actually required

18 years agoFix updating of the main view title when the screen isn't split
Jonas Fonseca [Sun, 21 May 2006 23:18:13 +0000 (01:18 +0200)]
Fix updating of the main view title when the screen isn't split

18 years agoEnd the current update before begining a new one; fixes CPU hogging
Jonas Fonseca [Sun, 21 May 2006 23:04:49 +0000 (01:04 +0200)]
End the current update before begining a new one; fixes CPU hogging

18 years agoBind 'j'/'k' to moving up/down; add next/previous requests bound to Down/Up
Jonas Fonseca [Sun, 21 May 2006 02:44:08 +0000 (04:44 +0200)]
Bind 'j'/'k' to moving up/down; add next/previous requests bound to Down/Up

This adds support for using these next/previous requests for changing the
current commit in the main view from the diff view, if the diff view has
the main view as it's parent.

Works for both split- and full-screen diff views by making redrawing
conditional when moving (and doing the lowlevel scrolling).

Replaces REQ_MOVE_{UP,DOWN}_ENTER.

18 years agoMove struct commit to appear just above the main view backend
Jonas Fonseca [Sun, 21 May 2006 02:08:52 +0000 (04:08 +0200)]
Move struct commit to appear just above the main view backend

18 years agoAdd -O2 to CFLAGS to get more warnings
Jonas Fonseca [Sun, 21 May 2006 01:19:19 +0000 (03:19 +0200)]
Add -O2 to CFLAGS to get more warnings

18 years agoCache all queries for refs based on ID
Jonas Fonseca [Sun, 21 May 2006 01:18:56 +0000 (03:18 +0200)]
Cache all queries for refs based on ID

At least then they won't appear as a source of leaking and in the future
the main view can be reloaded without having to deal freeing them.

18 years agoMove git directory assertion to main; don't require .git repo in pager mode
Jonas Fonseca [Sat, 20 May 2006 19:07:44 +0000 (21:07 +0200)]
Move git directory assertion to main; don't require .git repo in pager mode

18 years agoIn pager mode, fix entering commit lines from log and pager view
Jonas Fonseca [Sat, 20 May 2006 16:42:26 +0000 (18:42 +0200)]
In pager mode, fix entering commit lines from log and pager view

18 years agoRemove old window cycling code from before enter request appeared
Jonas Fonseca [Sat, 20 May 2006 15:56:10 +0000 (17:56 +0200)]
Remove old window cycling code from before enter request appeared

18 years agoAdd simple window stack, tracking view relation ship via parent member
Jonas Fonseca [Sat, 20 May 2006 15:39:25 +0000 (17:39 +0200)]
Add simple window stack, tracking view relation ship via parent member

This makes it possible to easily switch back to the main (or log) view
by closing the diff view, regardless of whether it is split or full-screen.

Requested-by: Aneesh Kumar <aneesh.kumar@gmail.com>
Signed-off-by: Jonas Fonseca <fonseca@diku.dk>
18 years agoRemove objsize member from struct commit
Jonas Fonseca [Sat, 20 May 2006 14:10:15 +0000 (16:10 +0200)]
Remove objsize member from struct commit

It is unused.

18 years agoMake Enter in the pager view always scroll
Jonas Fonseca [Sat, 20 May 2006 13:22:28 +0000 (15:22 +0200)]
Make Enter in the pager view always scroll

It will still split to diff view if a commit line is detected.