Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nkSy9-0003IV-0A for pgsql-general@arkaria.postgresql.org; Fri, 29 Apr 2022 15:55:45 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1nkSy6-0000q7-Ra for pgsql-general@arkaria.postgresql.org; Fri, 29 Apr 2022 15:55:42 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nkSy6-0000kz-GP for pgsql-general@lists.postgresql.org; Fri, 29 Apr 2022 15:55:42 +0000 Received: from mail.appl-ecosys.com ([50.126.108.78]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nkSy4-00065f-Fu for pgsql-general@lists.postgresql.org; Fri, 29 Apr 2022 15:55:42 +0000 Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by mail.appl-ecosys.com (Postfix) with ESMTP id D09F72A0108 for ; Fri, 29 Apr 2022 08:55:37 -0700 (PDT) Date: Fri, 29 Apr 2022 08:55:37 -0700 (PDT) From: Rich Shepard Reply-To: Rich Shepard To: pgsql-general@lists.postgresql.org Subject: External psql editor Message-ID: MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset=US-ASCII List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk I do all my postgres work using the psql shell. Editing a command reguires moving character-by-character and I'd like to use my small text editor (joe) because it allows more control over line movement. A web search found a stackexchange thread that suggested adding to ~/.bash_profile the line: export PSQL_EDITOR=/usr/bin/joe so I did this yesterday. Today I've learned that the keyboard chords I use in joe in other applications aren't working here. For example, C-w should delete the word to the right of the point (cursor location). It doesn't. Instead, it deletes from the cursor postion to the head of the line. C-x doesn't move the cursor one word to the right, but cancels the command. Is there a way for me to specify use of joe at the psql command line? (I'd use emacs but that's gross overkill.) Regards, Rich