From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15951 invoked by alias); 28 Apr 2012 21:46:02 -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: 17034 Received: (qmail 15102 invoked from network); 28 Apr 2012 21:45:50 -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,T_TO_NO_BRKTS_FREEMAIL autolearn=no version=3.3.2 Received-SPF: pass (ns1.primenet.com.au: SPF record at _spf.google.com designates 209.85.214.171 as permitted sender) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:message-id:in-reply-to:references:subject:x-mailer :mime-version:content-type:content-transfer-encoding :content-disposition; bh=BChgrgZknoUzMwSzelEQi8FkyYo21bblMzwvE1L9lBo=; b=yQnPee1c/TykESq0RARVjC02eTAxxW0Ja86iaqCcfTu5iEWOv/p8amvumQ2xrk7kAu NeukIeecAlk+x2m6ZNyRsEkOuzgImxCBp5ig24MECdDKo4Fx8jGkcHwMebdBIiJb17Zy Wl1+Hl/UdpboTSlpIrWOxHvHY+IdlpEBt6+C0YFrRiD+etVp6+G5Ei9qIF2PkR+cfJeu JE8oPtlHNnPnu1T8X3kCvnh1a1wB3io1/zf/k4iUJMaUr959O/UGwp3W68VXasTDHhsq 65vF/yC//UXRM0dMaN8JSfuDXFcDAFJgwnJQGm77GUqepMB93aCDkrG/QK02L9vjdtIk czQw== Date: Sat, 28 Apr 2012 17:45:46 -0400 From: TJ Luoma To: zsh-users@zsh.org Message-ID: <2C541918E59F49F193E5EEBCE2C73CAF@gmail.com> In-Reply-To: References: <29B9CC7BDEB94DA784265196AE5C7EEE@gmail.com> Subject: Re: can strftime show 'p.m.' instead of 'PM'? X-Mailer: sparrow 1.5 (build 1043) MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Content-Disposition: inline On Saturday, April 28, 2012 at 5:10 PM, Benjamin R. Haskell wrote: > AFAIK, the strftime provided by zsh/datetime just passes its format > string to the C library function. (So, right now, %p and %P get me 'PM' > and 'pm', respectively.) Ah! That explains why it seems to work sometimes but not others. I must have seen it differently on my Linux account on my web host. > Since it's system-dependent, you're probably better off munging it > yourself. But if you're extremely worried about efficiency, you don't > need to pipe to `tr` or `sed` (so you can avoid launching an external > process): > > print -r - ${${${:-"$(strftime "%F %r" "$EPOCHSECONDS")"}/AM/a.m.}/PM/p.m.} Terrific! Thanks. I'm not so much worried about efficiency as I like to know what my alternatives are. I'm going to alias this anyway, so I might as well use the 'efficient' version. (more below) On Saturday, April 28, 2012 at 5:20 PM, Mark van Dijk wrote: > One shall never debate the validity of taste. Unless it regards > the dreadful modern popular music. These kids these days with their rock & roll music! :-) > But in my experience the > exploration of zsh is all about, erm, "picayunicies". If I ever create my own Linux distribution customized to my own preferences, I'm going to call it "picayunicies" :-) TjL ps - thanks!