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.4 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED, UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 13248 invoked from network); 25 Sep 2022 15:44:00 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 25 Sep 2022 15:44:00 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20210803; t=1664120640; b=mmtstFHTkyqfb3zlhULl2Jl0kqpBGoAc5nXeqppGFwwhPSydbL7sr/FGyt8TBL+Mk8PAPSOKCZ 4D/oUeZVSxvvvP550/fq7M/skdEoEu/++CKq3bxyI7RfTkha2pA0D1/nu1INt5ciPlaVeEWJeN BUmvWkY4EVSdx2UYVm9dXq8gOoQLBOenp3krf/PxW8d5/OJmuWD1NG21V/uwtSs7AGGL9mhAO+ 8zNopEwS//sF36wTnW0qmojHDhjYgoWUMEEcem7jKccaTb/pj/TF+2OxaYRq/e+y3uageL8rMb OlooB07e9Q6znTvxG79oXgl6m1+SmotY5vqHzhz3D7QZVQ==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (mail-yb1-f169.google.com) smtp.remote-ip=209.85.219.169; dkim=pass header.d=gmail.com header.s=20210112 header.a=rsa-sha256; dmarc=pass header.from=gmail.com; arc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed; d=zsh.org; s=rsa-20210803; t=1664120640; bh=2s90mZEGTWo2dw4ueYoy3UEAeXsUJrnD6wlr1SgMCug=; 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=qWaha+dh0OvNb6Fq8FDMuAGrlHulTdlzQnewyVbVy7svmYCTdN9bAlR3A/sN680KwNgAznvQ2n 3509QsbXj/flQmMopDQutVfjdMfz4KUkIbQKDTH8ahh5nmuBBCvz6t3k8N6mfZuyU7hxDBbi9a SxvevWY46K1m94MVuoNG8iXjQ3QlE0A+Rjxg/Ht6UvjW/xem3gDmzrav2rsQQf0VYtVvpz120g HybUXF+qyXM4rJMID5DmADFhp2KDXl3+rDPzZNuBVc9+TqASo9806lxXKihRm/Q/cEzhU2REpJ euvmkwpB9DXe9Lc+sRQLMg3DWNFFIUe0l/RcJyJiP9xxWA==; 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=jPiZCQuMymot/DYf01qa0nyvIJ/5SvsyTOxiwmpfgHw=; b=XXT2htMG7Dqfm4509jnFioS7/r vX4VSUoIyh2a9WS1rE4uplcUy2SqhtqCYtSdKXQ/cWsXyj3VzhXRc2npp3h4nqzoHMwXsdulwMT9f k5xS+n+3OGZ7KbQLwukW0/oacIqokAqz5EXMyEjz3M1i3Ao3A36J45kJZYjFqPZUNXgFb/5EXOI9A SQszusKxdm5Sz8c5CGq+uxVVhG4nYN+0CCZWBG4MNbiDSbBQ/V7sy9F8BvjYg7IwI//zlIuvJ9iXk zlszjqpImfkkvuqQTomIQi8YZ3zNcLEXLHc9yZcxGECP5K0KS14j2RfTcNqFvI8VdbqCzQwIDockz AoMLjr4g==; Received: from authenticated user by zero.zsh.org with local id 1ocTnT-000JpK-JV; Sun, 25 Sep 2022 15:43:59 +0000 Authentication-Results: zsh.org; iprev=pass (mail-yb1-f169.google.com) smtp.remote-ip=209.85.219.169; dkim=pass header.d=gmail.com header.s=20210112 header.a=rsa-sha256; dmarc=pass header.from=gmail.com; arc=none Received: from mail-yb1-f169.google.com ([209.85.219.169]:36841) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_128_GCM_SHA256:128) id 1ocTmB-000J5c-Dy; Sun, 25 Sep 2022 15:42:40 +0000 Received: by mail-yb1-f169.google.com with SMTP id 126so5524335ybw.3 for ; Sun, 25 Sep 2022 08:42:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date; bh=jPiZCQuMymot/DYf01qa0nyvIJ/5SvsyTOxiwmpfgHw=; b=K4ARI7qJxwT+GodVj6AsaYQu54qNkzF9viQc5cKTQcninT2E+nbakoa3N95RS2iHZg sGloEmH+rAGbA45JZ7PHtpL8wSjWpwCp5cij8Kfep0JHWtXzYgbbPFi0RQykrh/s+eOh bu4nJk9jVS8IMkaid+ORT5UOUuD7IT2syjvS6qeuWwXp9qxLxV6oTrQq87a4tpoqGUX4 x90ZyHYpSOfb0rJ/rSfAqHNdJHx3fY+1d0ozJPKux6pLkmSS4ws27x1DarCaYoQRLOCW sC4Zdo/NSHD29+pYLzTBTpRN1fYjKgT3bXp2sw45CtCRaFguOoyPNKn54dEKKhSEO7lC s3MA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date; bh=jPiZCQuMymot/DYf01qa0nyvIJ/5SvsyTOxiwmpfgHw=; b=o0aTEudl6BRJWExHMvFCU/dNNOAh3uvKJQeLJEOLqhKajdmWP+VNjqFlCVL48rY9kc JLby9gzcub47i6T6k7Ziv3EJvwAHawYIqVrhDv5nA1GXmJjzgNNBetVzbdOObOieq9CZ W5ZUSdvef2WrBdS618NZSQSne4EVQl+fnpXAb6K4ysRZb1Ta/+WvPT6jcjT6v73NQGOY Em3/ECeAKdV5a9yuWwsJ/mhzYFusL/4H4wyrlp8ODK/f035UnLt7sPdStr0/cSV5FViP vrnz1AKaMUHmAs8d2fgVaBTWlElo3t9ylJNUpwcj+0nQjWuZo/apt5J9FEx/zTfqkNsD kybQ== X-Gm-Message-State: ACrzQf00TZY5rBRgiFeTVP4crQ22m+MLxogur2XNevTsPmro0rvdO31i wQM25+BopAvlZ6u7f3AeqP7ySJe9mb5qwdqahfQ= X-Google-Smtp-Source: AMsMyM4vZpThSU+4gXJ/y+fzX5T5k4mHCFYwpErTIEPTi6NLSSjl7R8K7/ZN6U23tiaGdPXmBtKyWe+y5oitsx1CNs4= X-Received: by 2002:a05:6902:728:b0:6b3:a898:b025 with SMTP id l8-20020a056902072800b006b3a898b025mr17229075ybt.622.1664120558317; Sun, 25 Sep 2022 08:42:38 -0700 (PDT) MIME-Version: 1.0 References: <34ffd90d-24f5-25b0-7b47-188c63e52cef@eastlink.ca> In-Reply-To: <34ffd90d-24f5-25b0-7b47-188c63e52cef@eastlink.ca> From: Roman Perepelitsa Date: Sun, 25 Sep 2022 17:42:26 +0200 Message-ID: Subject: Re: $_tty is gone after system upgrade To: Ray Andrews Cc: Zsh Users Content-Type: text/plain; charset="UTF-8" X-Seq: 28127 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 Sun, Sep 25, 2022 at 5:33 PM Ray Andrews wrote: > > I'm upgrading my system from Debian 9 to Debian 11 and my zsh is now > whatever Debian installed (vs. old system where I was running Roman's > pre-build). Prompt is: > > PS1=$'\n$_tty $_yel%d $_mag$cc$_nrm $ ' > > ... which returned just the number of the current terminal on the old > system but now > > $ echo $_tty > > ... returns nothing. I don't recall any version of zsh setting _tty. Debian 9 doesn't set it either. % docker run -e TERM --rm -it debian:stretch bash -c ' apt-get update && apt-get install -y zsh && zsh -c "typeset -p TTY _tty"' [...] zsh:typeset:1: no such variable: _tty typeset TTY=/dev/pts/0 If you were using https://github.com/romkatv/zsh-bin, that would be zsh 5.8. It doesn't set _tty. In any case, it seems better to use ${TTY:t} given that this parameter is (and has been for a long time) documented and working as intended. Roman.