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=-1.8 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_DNSWL_LOW, UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 19562 invoked from network); 11 Sep 2020 08:21:55 -0000 Received: from zero.zsh.org (2a02:898:31:0:48:4558:7a:7368) by inbox.vuxu.org with ESMTPUTF8; 11 Sep 2020 08:21:55 -0000 ARC-Seal: i=1; cv=none; a=rsa-sha256; d=zsh.org; s=rsa-20200801; t=1599812515; b=QEj0OybzgaEG7OcHLZz148rV4pBfpqtl0p7WKsVCSbrQ1fyxCPrIdOEuxmnRQvCadygppXwEEF mKIiVTqi8g70ggnoVzn41FZ5/Uf5Z2wDg6w2UOS8L49Q5d/sCF8Pi1YMGB/pzGXhJGrDT+nJ5s NL+EeXlETpxO6z8sBmVrXdP3iVW3NCecmLVbs+Ylu/SmurdwfOyDOClixrUQiu5W7BXy0vItt1 TL+/xavsTexXdHbhjibXwZ6eaZWc7Tw/0XngKFb1V6gX1+dqlpYkR7SJpo/0nQCXojFy7izlFm QQ7ac7gJOPpf9sKy3edgkxbaAWMiGugup6xoyMbRVEbqjQ==; ARC-Authentication-Results: i=1; zsh.org; iprev=pass (mail-io1-f48.google.com) smtp.remote-ip=209.85.166.48; dkim=pass header.d=gmail.com header.s=20161025 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-20200801; t=1599812515; bh=2sPlGO3bSJv+LGA6sX3IwrMDYni4i2sbQ8VGF5MTbSE=; h=List-Archive:List-Owner:List-Post:List-Unsubscribe:List-Subscribe:List-Help: List-Id:Sender:Content-Type:To:Subject:Message-ID:Date:From:MIME-Version: DKIM-Signature:DKIM-Signature; b=xRU5Cih3LTQMpedCaz97AA7+q+3Syk/etOpZDdu71iFeOun9z9zlOc1hrMmIimjiFp4zhAlKSM V3k8D0bkNSS25UIJ7KjlYt9dfCHxiXs0CKXwTr8i7tlFyejhfyL4VDJ7TVUyKdU/PW1HNbw4Nz 2Hd1jHlseGBWG8b6AtDz+Bebug7y+x8d1mhsX8ysLbHG1y1u0j3dwXEE4p8txuW9olGyf5ubq7 5MuS8YgoeFRYntujtxNamTSCRMUiFQ5g5rqdFVV6GCRd6+BU9ejEK5z+vkYsrXSrQky1FL9AN+ E9wQ5eFFnhujzSvpcC4FVs0NHwrty0u/AcBYJ67nr6fOdQ==; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=zsh.org; s=rsa-20200801; h=List-Archive:List-Owner:List-Post:List-Unsubscribe: List-Subscribe:List-Help:List-Id:Sender:Content-Type:To:Subject:Message-ID: Date:From:MIME-Version:Reply-To:Cc:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References; bh=ZxmX86TODZhkNA7J7MAeqkEsaz8LCiBtaHSoQDGQZ/g=; b=jofQ8bq9we04bsqpYbLi21JExY 7aYmn9Nrzdvz9rvHLRbqpYcq90Zs0Nn90OWZ+qphDYloPh3nB6aphvX1unOoymhYtHtwzEVsu1BKg PROusjQuUYWuch8P37w9R4YwUg8ir+DZJW/1hA/l/r+AcYzwZ0chcac/9PVqjeIQRfzfHo2PZHMxv SmjSgmNJx5Sy8XQKG+jkW2aQO4cTnvv5tntLrPQmjKgViGlRvHxu2i8mDUcl/pkba5JGLPLjzav/C WC1eU3ekIqjE32V7GPbC3+rictPk1huKj3HsHVltpIGo7BiMksAGyJOZkgcIy2d4JuQK8BderwvuD x9535u2g==; Received: from authenticated user by zero.zsh.org with local id 1kGeJd-0006Jy-M7; Fri, 11 Sep 2020 08:21:53 +0000 Authentication-Results: zsh.org; iprev=pass (mail-io1-f48.google.com) smtp.remote-ip=209.85.166.48; dkim=pass header.d=gmail.com header.s=20161025 header.a=rsa-sha256; dmarc=pass header.from=gmail.com; arc=none Received: from mail-io1-f48.google.com ([209.85.166.48]:37070) by zero.zsh.org with esmtps (TLS1.3:TLS_AES_128_GCM_SHA256:128) id 1kGeJI-0006B6-K7; Fri, 11 Sep 2020 08:21:33 +0000 Received: by mail-io1-f48.google.com with SMTP id y13so10159602iow.4 for ; Fri, 11 Sep 2020 01:21:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=ZxmX86TODZhkNA7J7MAeqkEsaz8LCiBtaHSoQDGQZ/g=; b=qDIXk16MMpd+nUCvTdpHTdMmYw4HZ0BTwhg0/tidYe7SyCSMwdpOQH5j+FWOBVFY/U 0Ji4cwkodx8q1mPJG8pTcw17derY/2WUtK4QYhQU9rKwDZykVvv/o0IUNiDFWcRkIRdC bq1NL0ARRb5SlstHqwatmjIUZoAkI7utTNfC8TNqb4EPob9uh4L4V5nWIW/zZHcHAjo2 wP52nSRtA0ymH+F5RsGv6xpvKhaPqf7FAFsu1CHKGPT/lYyarZyGOZLZd4ccE+co1qoJ FBFCYJqsR0LFKuTqYG1BgFruFuimJbZd3dqFqTgWU9zP+xY5l6hi8iQdJCfzHxYZFT48 fAmw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=ZxmX86TODZhkNA7J7MAeqkEsaz8LCiBtaHSoQDGQZ/g=; b=A1TRdFW0r/u0hLOIoQSCfDASvk8yHGB3k5HD7Gb5HQhXS89tQ3x0zesgIbgYQI4xbe HimgJOYKe3WqRQ8Mi3i8tEHxRoc8z/x0Kocf2EADoDavUsujFRich3blXuz5J4UqcWfN wwDMid1xqKXpd7yUdDHnL57lHF7w+doo0IcczM7Pr+sIjRduITJ/YXKtZXDvTJrTpCpV 9/pipGIXMrYE4X5vWqxOkqr8Uh+I2bWF863hI2amD7XNwCxlEUDUYAUSFvTKu3+ZocAt 9RfycPKLbnkcOQQ0/DfACI90t3NJLXb0IZNaQjJKEN+CQc/egsDTKGVg5wckJtBkyBhs pT/Q== X-Gm-Message-State: AOAM531ov59i2IoqaEN9UWv5jDu1sxSaj/1IYCeYv2Wxjm9XewKvDdX9 AZV+6wNvQ8NGGn9+zPuIPLDU42shI07c1gJFHlmKMkyz59KAAA== X-Google-Smtp-Source: ABdhPJxPE6HHyF0OjdWgd7CsLyBae1b0cfksOq5T8XnU4nH9Q2Cdac/FLcPTZ+UEmaV+8zVPEJ9/jiqJ+fA8XNUAffA= X-Received: by 2002:a5d:8755:: with SMTP id k21mr922738iol.142.1599812490673; Fri, 11 Sep 2020 01:21:30 -0700 (PDT) MIME-Version: 1.0 From: Roman Perepelitsa Date: Fri, 11 Sep 2020 10:21:19 +0200 Message-ID: Subject: Possible bug: HASH_CMDS has no observable effect To: Zsh hackers list Content-Type: text/plain; charset="UTF-8" X-Seq: 47366 Archived-At: X-Loop: zsh-workers@zsh.org Errors-To: zsh-workers-owner@zsh.org Precedence: list Precedence: bulk Sender: zsh-workers-request@zsh.org X-no-archive: yes List-Id: List-Help: List-Subscribe: List-Unsubscribe: List-Post: List-Owner: List-Archive: Archived-At: >From the documentation for HASH_CMDS option: Note the location of each command the first time it is executed. Subsequent invocations of the same command will use the saved location, avoiding a path search. If this option is unset, no path hashing is done at all. However, when CORRECT is set, commands whose names do not appear in the functions or aliases hash tables are hashed in order to avoid reporting them as spelling errors. I took this to mean that after installing rsync and invoking it, ${commands[rsync]} will be set and running `hash` will display an entry for rsync. This, however, is not the case. % sudo docker run -e TERM -it --rm zshusers/zsh:5.8 # print $options[hash_cmds] on # rsync zsh: command not found: rsync # apt-get update && apt-get install -y rsync # rsync rsync version 3.1.2 protocol version 31 # print $+commands[rsync] 0 # hash | grep rsync # Discovered during the discussion of https://github.com/zsh-users/zsh-syntax-highlighting/pull/764. Roman.