Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Jan 28 2019 22:21
    verdie-g opened #893
  • Jan 28 2019 10:19
    VonUniGE commented #340
  • Jan 28 2019 02:20
    rcywongaa closed #869
  • Jan 26 2019 20:30
    smkniazi edited #892
  • Jan 26 2019 20:29
    smkniazi edited #892
  • Jan 26 2019 20:28
    smkniazi opened #892
  • Jan 24 2019 10:38
    timotheecour edited #890
  • Jan 24 2019 09:20
    timotheecour opened #891
  • Jan 24 2019 00:29
    timotheecour opened #890
  • Jan 23 2019 22:09
    KeeReal commented #869
  • Jan 23 2019 20:58
    avivey opened #889
  • Jan 21 2019 23:26
    timotheecour commented #559
  • Jan 21 2019 21:16
    koutcher commented #559
  • Jan 21 2019 20:47
    koutcher commented #559
  • Jan 21 2019 18:39
    smancill commented #559
  • Jan 21 2019 07:11
    timotheecour commented #559
  • Jan 20 2019 17:01
    smancill commented #559
  • Jan 20 2019 10:25
    koutcher commented #559
  • Jan 20 2019 02:54
    timotheecour commented #559
  • Jan 20 2019 01:56
    timotheecour opened #888
Sebastian Gniazdowski
@psprint
I have one more question – could I start up TIG with some columns like ID/SHA shown via command line options? Like: tig reflog --pretty=raw | tig --pretty=raw --Show-sha. Is there something like --Show-sha option or a way to execute a :set command on startup?
Johannes Altmanninger
@krobelus
@psprint you can do something like TIG_SCRIPT=<(echo :set main-view-commit-title-graph = no) tig
Sebastian Gniazdowski
@psprint
@krobelus Thanks!
I have an idea for a cool feature request – EditAll – to open an editor with all filles from a foremost commit passed as arguments :)
Think of it – tig as a central console place (it already has such connotations, I very often open editor(s) from tig) of the console – the place where editor sessions are being kept ↔ i.e.: the sets of files related to each other by a feature and edited together… :)
Johannes Altmanninger
@krobelus
ah, I just replied to your issue ;)
Brian Spilner
@Try2Code
@psprint Exactly what I am looking for :thumbsup:
Brian Spilner
@Try2Code
bind generic E !sh -c "vim -p $(git diff-tree --no-commit-id --name-only -r %(commit) )" @psprint
kaddkaka
@kaddkaka
@psprint what is the tree-view you mentioned?
damani42
@damani42
&bu52
kaddkaka
@kaddkaka
Hi, has anyone explored interaction between tig and fzf?
blayz3r
@blayz3r
Has anyone set up an external TIG_EDITOR
Brian Spilner
@Try2Code
@blayz3r not needed because I stick to $EDITOR, but TIG_EDITOR=emacs tig seems to work nicely
Kohei Yamada
@iberianpig
vim users should give this plugin a try! Prevents vim processes from nesting as child processes. https://github.com/iberianpig/tig-explorer.vim
Sebastian Gniazdowski
@psprint
Can you search for a specific string directly from a bound command?
I have a super-useful configuration – a bind to <Enter> that opens up this simple Zsh script on '%(text)' passed as 1st argument:
This message was deleted
#!/usr/bin/env zsh

emulate zsh -o extended_glob

if [[ $1 == (#b)([^:]##):([0-9]##):* ]]; then
    [[ -z $EDITOR ]] && EDITOR=mcedit

    $EDITOR +$match[2] **/$match[1];t
fi
It allows to open the compiler error-line by pointing cursor and pressing enter. It will automatically jump to the line with the error.
So, :!make and browse freely :)
Sebastian Gniazdowski
@psprint
However, I would need also a way to jump to the errors, hence the question: how to search for "(error:|warning:)" directly via a key binding??
Johannes Altmanninger
@krobelus
@psprint @ is bound to :/^@@ in /etc/tigrc, you can the same for errors
though why would you execute Make in Tig, and not your editor?
Sebastian Gniazdowski
@psprint
Guys, I've submitted an interesting PR (#1139); autoscroll and colorizing of compiler errors in pager view, to implement this simple IDE-like round-trip error fixing use case: https://asciinema.org/a/430460. You can
have this functionality also without the PR, just without autoscroll and colorizing of errors, as described in the PR.
Sebastian Gniazdowski
@psprint
Is there a way to properly pass %(text) to a sh command, if it contains string like: undefined reference to SOME_VAR'? Notice and ', whose basically, apparently block any way of quoting the text, e.g.: !sh -c 'ls "%(text)"' will not work, nor will !sh -c "ls '%(text)'". So, is there a way to properly pass such %(text) to a sh command?
Johannes Altmanninger
@krobelus
@psprint yeah, I think you can do somehting like bind generic aa !sh -c 'printf "%s\n" "$1"' -- %(text)
Kai Hendry
@kaihendry
hi, when I am looking at a tig blame $filetname how do i preceed to go back and forth through the history?
Johannes Altmanninger
@krobelus
@kaihendry b pushes a new blame view on the stack, and , (:parent) goes back (pops from the stack)
Kai Hendry
@kaihendry
doesn't feel right, hmm
roman-khazanskii
@roman-khazanskii
Hello everyone! I was wondering if it's possible to make three-way view; log on the left, list of changed files in the middle and file changes on the right? That would mimic workflow from many git GUI tools (e.g. tortoisegit, gitkraken etc)
1 reply
Etorth
@etorth
image.png
anyone can help on this?
1 reply
I set the .tigrc as the messge, but still doesn't work
BuZZ-dEE
@buzz-dee:matrix.org
[m]
hi, is it possible to revert commits in tig, if yes, how?
1 reply
Gerep
@gerep
Is there a configuration to change how the usernames are displayed?
Ash Summers
@Asheboy_twitter
Am I going mad, or has the key binding to change the order (ascending/descending) of the refs view gone?
Ah, I bet you I've overwritten it with this External commands: I @sh -c "echo -n %(commit) | xclip -selection c"
Ash Summers
@Asheboy_twitter
Yup, that was it!
kaddkaka
@kaddkaka:matrix.org
[m]
Is there some way to search within the diffs of the commits from the main view? Currently the / search only takes the commits message into consideration, and when the diffview is open only the content of the diff of that specific commit is searched. Instead I would like to find the most recent commit that touched a variable called rare_banana. Can this be done in tig?
gseba
@gseba:matrix.org
[m]
Why isn't a .patch/.diff file automatically colorized in pager? After selecting it with enter in [status] view? The view opened after pressing the enter looks like the pager view, but it says "[stage]" in the bottom bar line. Could this be fixed?
It is pretty inconsistent with general rule of colorizing like diff everything that looks like a diff (for example, when invoking something like git diff | tig)
kaddkaka
@kaddkaka:matrix.org
[m]
Hah, I think I found a bug git log -G bananaramamama | tig and press q, the tig window will close, but the process will stay alive and hence not give you back the prompt. You can kill it with ctrl-c
Johannes Altmanninger
@krobelus
@kaddkaka:matrix.org if tig has exited, git log will receive EPIPE on the next write(2). Since there is no data to write, this won't happen, so it keeps running until it has finished searching. So this is an artifact of how Unix pipes work.
1 reply
Brian Spilner
@Try2Code
hi folks! is there a way to select/mark a bunch of commit and call 'git format-patch' on them via tig?
Brian Spilner
@Try2Code
bind generic <C-s> @git format-patch %(commit)~ is a good workaround for now ;-)
kaddkaka
@kaddkaka:matrix.org
[m]
From time to time, I'm a bit sad that tig lacks functionality from git, so I'm wondering. Has there been any consideration in supporting something git log | tig as an alternative way of starting tig? so That git log -S banana | tig could work, for example?
Or does anyone know of some other tool that just acts as a pager for git log output?
Edward E.
@cbrt64
@kaddkaka:matrix.org try tig -Sbanana. This also works for -G. (man git-log shows opt&arg concatenated like this, though including a space also works; I don't know specifically why tig won't as well.)
Brian Spilner
@Try2Code
@kaddkaka:matrix.org what's wrong with a simple shell alias: alias gtig='git log | tig' ?
1 reply