Received: from malur.postgresql.org ([2a02:16a8:dc51::56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fkrTV-0001zi-Mm for pgsql-general@arkaria.postgresql.org; Wed, 01 Aug 2018 13:47:37 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1fkrTT-0008Mq-MM for pgsql-general@arkaria.postgresql.org; Wed, 01 Aug 2018 13:47:35 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fkrTT-0008Mj-ET for pgsql-general@lists.postgresql.org; Wed, 01 Aug 2018 13:47:35 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fkrTQ-0006cU-Bd for pgsql-general@postgresql.org; Wed, 01 Aug 2018 13:47:35 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id w71DlTM3026303; Wed, 1 Aug 2018 09:47:29 -0400 From: Tom Lane To: ik cc: pgsql-general@postgresql.org Subject: Re: Adding terminal title support for psqlrc In-reply-to: References: Comments: In-reply-to ik message dated "Wed, 01 Aug 2018 11:52:14 +0300" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <26301.1533131249.1@sss.pgh.pa.us> Date: Wed, 01 Aug 2018 09:47:29 -0400 Message-ID: <26302.1533131249@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk ik writes: > Is there a way to add terminal title information for psqlrc that cn display > what schema I am, operation that is execute and stuff like that? Most terminal programs recognize escape sequences to set the window title. So you could set values for PROMPTn that cause updates in the title. There's an example in https://www.postgresql.org/docs/devel/static/app-psql.html#APP-PSQL-PROMPTING although it's just talking about a color change. regards, tom lane