Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: view onto command pipeline?
- X-seq: zsh-users 27901
- From: "Anthony Heading" <ajrh@xxxxxxxx>
- To: "Bart Schaefer" <schaefer@xxxxxxxxxxxxxxxx>
- Cc: "Zsh Users" <zsh-users@xxxxxxx>
- Subject: Re: view onto command pipeline?
- Date: Wed, 20 Jul 2022 07:23:46 -0400
- Archived-at: <https://zsh.org/users/27901>
- Feedback-id: i6aa94791:Fastmail
- In-reply-to: <CAH+w=7Z9CO84cRiYcr8n25=e5kz72KsSGrmwKGsdg6W79ONYXw@mail.gmail.com>
- List-id: <zsh-users.zsh.org>
- References: <28c00da7-cfdd-4f58-a539-8deebbe5dfa5@www.fastmail.com> <CAH+w=7Z9CO84cRiYcr8n25=e5kz72KsSGrmwKGsdg6W79ONYXw@mail.gmail.com>
On Sat, Jul 16, 2022, at 5:30 PM, Bart Schaefer wrote:
> You need to look at the preexec hook.
Ah, many thanks Bart! Much appreciated. Don't know how I missed that.
For the record, I used just the following, and it works great.
git () {
local opts=()
if [[ -o interactive && ( -t 1 || -n $pager ) ]]
then
opts=(-c color.ui=always)
fi
command git $opts $@
}
Messages sorted by:
Reverse Date,
Date,
Thread,
Author