From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22420 invoked by alias); 5 Nov 2012 17:31:27 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: X-Seq: 17378 Received: (qmail 12079 invoked from network); 5 Nov 2012 17:31:26 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.6 required=5.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED,FREEMAIL_FROM,NML_ADSP_CUSTOM_MED,RCVD_IN_DNSWL_LOW, T_DKIM_INVALID autolearn=no version=3.3.2 Received-SPF: pass (ns1.primenet.com.au: SPF record at _spf.google.com designates 209.85.217.171 as permitted sender) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=yfc2FFwAoteCV1y7UxFkTyCetirLBgI4qUbO/GI65JM=; b=uNqvE9VMJN7XpzE4O0C5QsUSwvhdsYm+MfA1RlOtepJ0pp8dBjMiFndHPPMm34zvzc wvs+eUi+Z2ZSzTxz2pvg90Io+nRQESCgz2sUO3AYc/+AcF7ubLHM0gGYfdFA4nIrApl0 zqiUwzkcaRv06CnlchiEG0a3BJcNmp7RhZ4jGfHA9UHyDmfzsAblLDleVItCVSVSNm3p NA+Lfrzc+1IlIQeN89pk5wsOXFRxrXEN2dFt+mMvQFxbU1fINcPjYOMXscyLwzX51y4I dHmxDq5YjIw2Lcx4/1vbdnIO+Fd5x+OZ6qGHOmpSIE3dTvT57fupoQ0eI4IiDv7hVyBg uIjw== MIME-Version: 1.0 In-Reply-To: References: From: shawn wilson Date: Mon, 5 Nov 2012 17:22:49 +0000 Message-ID: Subject: Re: pipe every command To: "Benjamin R. Haskell" Cc: Zsh Users Content-Type: text/plain; charset=UTF-8 On Mon, Nov 5, 2012 at 3:03 PM, Benjamin R. Haskell wrote: > On Mon, 5 Nov 2012, shawn wilson wrote: > >> is there a way to put every command through a pipe or redirect? >> >> i'd prefer some way that i can put logic in so that i can exclude some >> commands. but, basically i want everything to go through 'source-highlight' >> so: >> ps ax | grep ssh >> will end up: >> ps ax | grep ssh | source-highlight -f esc256 -s shell >> >> and: >> sa >> would end up: >> sa | source-highlight -f esc256 -s shell > > > There might be a way to do this in the way you're talking about, but I > accomplish a similar goal (being able to easily pipe things through `less`) > using global aliases: > > alias -g L='| less' > > You could use: > > # H = highlight > alias -g H='| source-highlight -f esc256 -s shell' > not as nicely baked in as i was hoping, but i guess it'll work. thanks