From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5058 invoked by alias); 4 Jun 2016 08:42:57 -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: 21611 Received: (qmail 10353 invoked from network); 4 Jun 2016 08:42:57 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, T_DKIM_INVALID autolearn=ham autolearn_force=no version=3.4.1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:from:date:message-id:subject:to; bh=1muJEJEYWlDilOxj+/pjrWWinb7gj7LjAJayHNQIcww=; b=qqlqQjeqvJ/pZisYk66M2PoXW1N7L/wMag2pnt2ASAqKvoks0kqsRcOrJsjxHzNWEM l5lBV17VBmpn2FCbc+0FT3sTvXu/6NZG4KiP8mh+UgK6DR3GgLSntmrbZltdLuEJd0QS qUvd08G1DQiSvnUl3e6ykboU14IxsyiEEgW4c6GXUmWCCzEv1MFwBt9CwU93FYRgrkhq 97cojR0ggpumiHUtsvm6G69DA/HjoT+xuPd0MYeGiF4tUTmhb6GJcBB3Ul2c+ABH5ack K1h6aKQLkT8ZG6vBSO4eNYtlZ47Cz8YrZ/+kuvEgrj9l5TQZ2zGRJvrBEvfiJR4FQZPT 45qA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=1muJEJEYWlDilOxj+/pjrWWinb7gj7LjAJayHNQIcww=; b=EZScjAS5Vu+euJF679kaXi8yBPEYWJPcUd5Kf21lNnKfSZ2aBTUmxra8b4hNQucqn/ QyQp2zdGlc7ReLCUTppLTMaYad0c7USsSgYE1pPsJnJk135r/fe/E6NkYndOnvkkYWJV Vq+diQ13LhiPO5oQRbkyEwaC46uT2R2ON4mJpNSmIxyA38IqS7cZmeODy0Xzu1NsU6IK d+9UtTfwkqE0nNtJFGniDmstW+rBQVwFG46wmg/wVTww7TNKARvLP0ExdAZW46zJ8VZ2 /kasvl+KIUV3oaQ9wADhfD41R+NRbeMlW4zLwerRFWHqY+aUXffGz95TjHyh+ehMGhrR d2Lw== X-Gm-Message-State: ALyK8tIWc33bo4GCg8VwUhMo7Tpt+cbMtDaRzaY3cb7LHwi79RnL1LOF4XLoibeMiDwE9xWtXrAE/8v5TBEpWw== X-Received: by 10.140.216.67 with SMTP id m64mr6812751qhb.73.1465029775893; Sat, 04 Jun 2016 01:42:55 -0700 (PDT) MIME-Version: 1.0 From: Sebastian Gniazdowski Date: Sat, 4 Jun 2016 10:42:36 +0200 Message-ID: Subject: Unexpected behavior with prompt -p {prompt name} To: Zsh Users Content-Type: text/plain; charset=UTF-8 Hello, I've started a project to gather themes for Zsh that base on the original Zshell prompt subsystem: https://github.com/psprint/zprompts i have problem with first theme added. I build prompt in following way: local _lpar="${cl_parens}[" local _rpar="${cl_parens}]" local _time="$cl_time_line%D{%H:%M}" local _user="$cl_text%n" local _at="$cl_at_colon@$cl_text%m" local _path="$cl_at_colon:$cl_text%30<*<%/" local _line="$cl_time_line%i" local _prompt="$cl_prompt# " PS1="$_time$_lpar$_user$_at$_path$_rpar$_line$_prompt$cl_rst" And it works fine, displaying: 10:38[sgniazdowski@MacMini:/Users/sgniazdowski]2# However, prompt -p results in "]" being eaten, right after the path. I tried adding various things after $_path, and they all get eaten. Resulting in: 10:40[sgniazdowski@MacMini:*4# command arg1 arg2 ... argn What is wrong with the line: local _path="$cl_at_colon:$cl_text%30<*<%/" ? $cl_* are just colors, the two are defined as: local col_text=${3:-'cyan'} local col_at_colon=${4:-'yellow'} local cl_text="%b%F{$col_text}" local cl_at_colon="%b%F{$col_at_colon}" Best regards, Sebastian Gniazdowski