From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE autolearn=ham autolearn_force=no version=3.4.2 Received: from primenet.com.au (ns1.primenet.com.au [203.24.36.2]) by inbox.vuxu.org (OpenSMTPD) with ESMTP id 2b97e70b for ; Mon, 15 Jul 2019 22:09:20 +0000 (UTC) Received: (qmail 2617 invoked by alias); 15 Jul 2019 22:09: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: List-Unsubscribe: X-Seq: 24067 Received: (qmail 6115 invoked by uid 1010); 15 Jul 2019 22:09:02 -0000 X-Qmail-Scanner-Diagnostics: from mail-eopbgr730123.outbound.protection.outlook.com by f.primenet.com.au (envelope-from , uid 7791) with qmail-scanner-2.11 (clamdscan: 0.101.2/25510. spamassassin: 3.4.2. Clear:RC:0(40.107.73.123):SA:0(-1.9/5.0):. Processed in 1.8601 secs); 15 Jul 2019 22:09:02 -0000 X-Envelope-From: Christopher.Paul@hitachivantara.com X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | Received-SPF: pass (ns1.primenet.com.au: SPF record at spfa.protection.outlook.com designates 40.107.73.123 as permitted sender) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=MH2XpxI0Vv6sxtGheTU8P6cjyHiQGdvk7GT62pCSsuYiJ0lxlKlBEWhJ3Ex5F2TYxwBI4gf1g5RSTCWo7gyx7cNbIE7Vs9m6bNOkTSkIEFomSaLtE3egXQdKLvkxq3x2IEexy8wpUY24iH4oG4tvcnXoCWIhTj4yiDCi/3RQBKXnFuWpAQZ6qQqddsL5Z0EMkmFJVkKXi5C8R/zCzt3m80Wn142Yeg/Hnhi9k+eAkX1eCiygKm4btjW8qEPpQsFAzaZwN3bYKgpUeTOOGG7VMARIbicPvMehjP6StaggaZENDe9ceG1HeNCfIxsSTQNU9hXEmzMtIcn0o6/hQP/zeg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=h35/k32agSVGaQqXbs38ocP5T6fvTLPBmAZCG29tCz4=; b=XJhxrduDVe59CUo2QQI6bGNu3GSOiqHid393nxwf5x2T10pwb6NBlc+OJSUkRGNGHusw8tIHI6ycHmDCa5jFBp9yBUm02m/7znEqXA4QMooEuB2l21HmONqFrHCOaxq5e8Hem95jp353NUK7ZH6Gf62kK14L9E6pve+/pTep63CzhI4jMNWPq1xYy8hDsxTXOxdxdAePAfXtEEmxZsSThzWwGMFjB+PIxWSdpNSr+BHjZp1nNooTg7sgHFKxVZvUpMK0+HM3EmCL6oXt1L0i6GyPOQg+gcULhOCk+eyZhxshID/cZQsqJb2ihKtPN4MSbE9WImxPqG+si8Jgh1LZ3w== ARC-Authentication-Results: i=1; mx.microsoft.com 1;spf=pass smtp.mailfrom=hitachivantara.com;dmarc=pass action=none header.from=hitachivantara.com;dkim=pass header.d=hitachivantara.com;arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hitachidatasystems.onmicrosoft.com; s=selector1-hitachidatasystems-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=h35/k32agSVGaQqXbs38ocP5T6fvTLPBmAZCG29tCz4=; b=uSAR6st8LbN6zkU9CIh71+PPXkW1+TX1mdhL56XezRPX4X3AhoIAvVod01gyWi2hQcuQP3iZEeXxeYLkuheKl28DpXQe4B7rcCiqLsBqg4xvjF4e1QtM2dOyaUQeSH4MNblF3z8JECWrdpa9TB6JS4Y1q4FMLZGeZzJZ9Z8AAjs= From: Christopher Paul To: Oliver Kiddle CC: "zsh-users@zsh.org" Subject: RE: vi mode cursor position Thread-Topic: vi mode cursor position Thread-Index: AdU4QvR0qdTvR8TjQ6KMDZBOPZqKsABGdBoAAH8d4RA= Date: Mon, 15 Jul 2019 22:08:22 +0000 Message-ID: References: <41960-1563009868.475157@HUWd.vdv5.55oG> In-Reply-To: <41960-1563009868.475157@HUWd.vdv5.55oG> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=Christopher.Paul@hitachivantara.com; x-originating-ip: [207.126.241.6] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: a6369461-7df7-4dde-4e8c-08d70970f38f x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600148)(711020)(4605104)(1401327)(2017052603328)(7193020);SRVR:CY4PR08MB3574; x-ms-traffictypediagnostic: CY4PR08MB3574: x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:8882; x-forefront-prvs: 00997889E7 x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(4636009)(376002)(136003)(396003)(366004)(346002)(39860400002)(189003)(199004)(25786009)(256004)(14454004)(33656002)(6916009)(6116002)(486006)(68736007)(11346002)(26005)(446003)(186003)(7736002)(102836004)(6506007)(305945005)(3846002)(74316002)(476003)(7696005)(76176011)(316002)(99286004)(81156014)(81166006)(229853002)(55016002)(71190400001)(4326008)(6246003)(8676002)(2906002)(9686003)(66066001)(6436002)(52536014)(8936002)(5660300002)(66556008)(86362001)(3480700005)(478600001)(66476007)(71200400001)(76116006)(66946007)(64756008)(66446008)(4744005)(53936002);DIR:OUT;SFP:1102;SCL:1;SRVR:CY4PR08MB3574;H:CY4PR08MB2437.namprd08.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;MX:1;A:1; received-spf: None (protection.outlook.com: hitachivantara.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: pImpGNTP2ILg4ioBkvcibAWKsp/QVIaCTFCXubchfCnbXsHNdto+OzELybF6u61SlMs2RSpXuxrjbJO/PhJls9zSqQAm8ZIYudD2FAI+ZuGNK5KqHxRc3FLerqkzVjXOpuJ5EfLf/7rnn8UvhitYVVqMadNwluM1bdWZpwWNH59nRNpbED0/cXemvlMEidjCwqQXWJ3J0iT0IdAeZ+z7R6f/HE2fQP+hkAwClH4FxuZcpOBUKItLQA1m5wduqHVOyyObu7AIpuAS5EaNHTqyuYG7Mho6KHI9wweEKD5XaJwlfsf6LU/Qx1kVkViCVntSzBC1K8RTHDlZKQaMuDt0XroIcirCOoBOvl6FB+NG6oepffiRPJBHl+BW7WBSR/P5Buj/DuNDG4ntNTipw3pBDHXbk2aHL1EmsvpShXoWNAY= Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: hitachivantara.com X-MS-Exchange-CrossTenant-Network-Message-Id: a6369461-7df7-4dde-4e8c-08d70970f38f X-MS-Exchange-CrossTenant-originalarrivaltime: 15 Jul 2019 22:08:22.2427 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 18791e17-6159-4f52-a8d4-de814ca8284a X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: Christopher.Paul@hitachivantara.com X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR08MB3574 Oliver Kiddle wrote: =20 > By default, k is bound to up-line-or-history. > There are alternatives that differ in terms of the cursor position. For > example: >=20 > bindkey -a k history-beginning-search-backward Thanks! This seems to work for me. > However that may break other things like moving the cursor in a multi-lin= e > buffer so you may want to use a custom widget that does something like: Hmm; I guess I'll know about that once I see it, but testing a multi-line b= uffer seems to work fine. I tested a multi-line buffer with: echo "now is the time "\ > "for all good men" > if [[ $LBUFFER =3D=3D *$'\n'* ]]; then > zle .up-line > else > zle .history-beginning-search-backward > fi I put this in my .zshrc file and it didn't seem to change anything. Thanks again, Oliver, I really appreciate your response. CP