From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-3.3 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 16777 invoked from network); 12 Jan 2022 19:11:05 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 12 Jan 2022 19:11:05 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20210803; t=1642014665; b=lv/Nmp09eei/iBJbyZ/VmRaNEYZEfZ8b/V8wAa4ocj16hmFVfWsuB2JtWZ7cnbZ19tiobt59wC 4D5JprZdP0K0Bjfq3z+MntVnq1OtBX6rcz5UnACiFNo4MTOCaHv/XvZDn9dHV9k0Kco0A9yauD F7nOXrHSvcaki1wOskL1egfPw1ROF4nzkacovPfPny1K+HrT2Ao6CMpQcD5MFaxry5Dbkrme8T DKjw98vLv7yAV9kLhf4ibHabAgx2V9PwZlSfgEM0pPxeUKmbLoSIbYiUfIFXCBiestagmuNzE3 PaTjmUyXE8MW5BrQKjkwRNfJbq5ZqSVnawd4yx0/QAhkLA==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (mail-yb1-f180.google.com) smtp.remote-ip=209.85.219.180; dkim=pass header.d=brasslantern-com.20210112.gappssmtp.com header.s=20210112 header.a=rsa-sha256; dmarc=none header.from=brasslantern.com; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20210803; t=1642014665; bh=jeH6FI+HXCk4Oy0uoM12NfVMiQoVSyZecshGyhfvZ/M=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:Content-Type:Cc:To:Subject:Message-ID:Date:From:In-Reply-To: References:MIME-Version:DKIM-Signature:DKIM-Signature; b=Ww3vUPJa35Kgx/9dSczTN9qjgFyJ2nC/JE5UU+UfWWKMKPdy5XSTQzqfOfg+4cZRj5nKcroXGg 2Q2TiwF45I/f95fkRYEJuIqt/03WAAsZgp1UQ1QBf+xzUnZ8ODqhmoJDHP1TbpYVhrfxoG+syh 15fv6SRLvOr7m7c6eeUu9wSVqUnb3NwciYysZQERQoSGLChS6aIo4VWFrjOQeiXFUedVuwCUWE 9sOcsPsV+9oD3ITIV4jRTy38y6iVhXyl3D1ehRJITX8sarFDpSdeJuhTHUhiNhSTyqooMkX6mq NuOoBKqrR2UYWdFtWIQaIKv6PoiOvufcKb5fzyHBGE1c8Q==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20210803; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:Content-Type:Cc:To:Subject:Message-ID :Date:From:In-Reply-To:References:MIME-Version:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID; bh=dRTONbiZK4BVnXRT0MNHcf5FHaOKk8IML99PfmKjv+A=; b=JnlH8f7lGlriMrWwpG1jAwl2sL Hhber7Zs+RGz7VeXTcUUaYTIMuukqzlTsn/cXxIXCwcY6YOJjDW66PE0NIolQQKerskA/R0CLAo8n ICkqVHSiYTkXsTDZMQ6LEeDkMTq24Zwhp/zpd4Vm33/Mr/6m/W6u+TBfW5PLILc5TouS2MeXjjWPt 4Vp9Am3cGGkN+vSnj0p+gSSsSS8nASZ+VtF+P4hAs8M6Yw4SlPIYtXaJYbn6xm9CHgc+cXm4RkYBE QzIPrcSaHa/cwlJFTk3W+QsLwRo/5JViEqw6jY3l9oGgILzttPSQCzWVzwzfep8IkKUmC3jcPra86 c74iBJ6w==; Received: from authenticated user by zero.zsh.org with local id 1n7j1U-0005iE-2l; Wed, 12 Jan 2022 19:11:04 +0000 Authentication-Results: zsh.org; iprev=pass (mail-yb1-f180.google.com) smtp.remote-ip=209.85.219.180; dkim=pass header.d=brasslantern-com.20210112.gappssmtp.com header.s=20210112 header.a=rsa-sha256; dmarc=none header.from=brasslantern.com; arc=none Received: from mail-yb1-f180.google.com ([209.85.219.180]:44934) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_128_GCM_SHA256:128) id 1n7j0a-0004yR-5B; Wed, 12 Jan 2022 19:10:09 +0000 Received: by mail-yb1-f180.google.com with SMTP id z22so7911305ybi.11 for ; Wed, 12 Jan 2022 11:10:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=brasslantern-com.20210112.gappssmtp.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=dRTONbiZK4BVnXRT0MNHcf5FHaOKk8IML99PfmKjv+A=; b=1gkTsX0jv48OBgNAejgSPcHVsCUJe/mldKCAHHQV2qdMTzJrVJU7gHL6g5ZXhYm9zt cbRsnBmNJmeKIfaIXiu3WjaFILo+pqrmBXHj78FUB4PBB/6rqiUI8eh61qLtPu8R/aPI F6x2oQ1+JDqQyJzPrSTyHUIAkC9fUCHzobUj+UBpW8lih1BDxYqpVGTNadaA7nMz1t9C zxr98QpJ7LDz2+6lUT5nCph02ZScnE9x9FHY3nO6FUADB0XKiyKEflDMV3Pziy4V3vIG usTffuXO1VvQ2/BYjOwaFjkcs19m04vXE8XCHI8xXxTlW3c1plzwjJ4PHspNt1vP2VDz +Pew== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=dRTONbiZK4BVnXRT0MNHcf5FHaOKk8IML99PfmKjv+A=; b=mXzwZ+kbyPg1GCCkLhPRYWmVgHak0GLDJNtTwqLfS2jJDdQkAKK2Xo8sPKWxEgXZ+s aJlreaCtUjm+Q25lvF/PF0Pm581GAFOBAob+fLABKfOUKgM3LKUBnzZa3RDSogu0JycP +yZO9B4vObsnJ4LFZXvKsVRT95B74ne6d0LoJKLycWE1ndKqRJBa4ASCTF4/vPS70xHo vyc5pyorsgOYO7ZfAaZQY1m/KO7G/6UqA31DsrrTdx+ic7in8C1D9epuz/llnsuMZaAi lKdMst77DBnlnUHqpxHhuQMtTOVOmQNKihK6bI6ZH4lCSUqYctitkcsf9aTsAiPv/Dj2 3qMg== X-Gm-Message-State: AOAM530/cyfofMYGv5QZH8X/xbLAwEvds/YEwgp1toiTZXzl0wogfirM jv8a1zS6TBtab8wNdH0qKDo4fYLr+yRPs3YFvcqWXw== X-Google-Smtp-Source: ABdhPJwgn9NyRHq5w0t12F7o3t3ls0RCIv+S9dAUxtzB+1jP3CY+EaAeQ6r0w/8fJ3dEMaZYB1BEKUFYCVFNGHhGwlI= X-Received: by 2002:a25:d085:: with SMTP id h127mr1381242ybg.323.1642014606668; Wed, 12 Jan 2022 11:10:06 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Bart Schaefer Date: Wed, 12 Jan 2022 11:09:56 -0800 Message-ID: Subject: Re: Possible inconsistency with use of TZ to change zone output '%Z" To: linuxtechguy@gmail.com Cc: zsh Content-Type: text/plain; charset="UTF-8" X-Seq: 27464 Archived-At: X-Loop: zsh-users@zsh.org Errors-To: zsh-users-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-users-request@zsh.org X-no-archive: yes List-Id: List-Help: List-Subscribe: List-Unsubscribe: List-Post: List-Owner: List-Archive: On Sat, Jan 8, 2022 at 7:33 AM Jim wrote: > > Unfortunately my searches never found that mail thread. Sorry about that. > I'm sure the print builtin has nothing to do with the results I am getting. I didn't mean to imply that you should have found that thread on your own, sorry. The significant bit is that there is some discussion of possible patches in that thread. > But if parameter expansion is using zsh's strftime shouldn't it act the > same way as calling strftime directly. The %-replacements for zsh's strftime do not map 1-to-1 onto every underlying strftime implementation, so it's not a direct pass-through. However -- > 1) DT=${(%):-%D{$Fmt}} > 2) zstat -F $Fmt -A A +mtime $F > 3) strftime -s DT $Fmt $ET -- the patch discussion from the other thread comes down to: In the third case, the strftime builtin has an execution context in which it is able to implicitly create a temporary export of TZ and then delete it again before returning, so it does that (this was a change implemented some time after the datetime module was first created). In the first case there is no such context so a solution is messy, and in the second (zstat) case the equivalent export has simply never been implemented even though it would be possible to do so.