From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id 2OYyEyJ2G2AAZgAA0tVLHw (envelope-from ) for ; Thu, 04 Feb 2021 04:20:50 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id eNWUDiJ2G2AXXgAAbx9fmQ (envelope-from ) for ; Thu, 04 Feb 2021 04:20:50 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 6A07F9404DF for ; Thu, 4 Feb 2021 04:20:49 +0000 (UTC) Received: from localhost ([::1]:55508 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1l7W8O-00038r-5M for larch@yhetil.org; Wed, 03 Feb 2021 23:20:48 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:42490) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l7W73-00038i-1M for emacs-orgmode@gnu.org; Wed, 03 Feb 2021 23:19:25 -0500 Received: from out1.migadu.com ([91.121.223.63]:53179) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l7W6y-0007I7-Em; Wed, 03 Feb 2021 23:19:24 -0500 X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kyleam.com; s=key1; t=1612412355; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=rIN2SjcVbaOx6uM7nWIUfoTF2WgETwSSDounsUW/iMc=; b=gNgRd/qS4GWjN2SBUtSfRXJHY5Isn4UnYwxCTl2RzGFtaSe3KnI0C8i30PmL89mZ53zML9 pJOlrt5nhi68t0vCgbDfXtUjPfeKGVvo0W0y77XkEhVWiFwUD6pW2/cfTWUCnZDRIQXeO7 iXyNBGCLxCU8YncrZbLrbZTKYKU92DH5LhJvUb7HqHcQU8bRvoJq4EUhvdDF8pn3O1onDS vTRYb9uMlrUnqY0wEzMm5jo+dNoSAXqypcmSQQSypbp4c718JjmAKLqUikTFdYqK8O5KkU OJ+7sDBsysZgXGIp0+yNrTbDAx9qE9RGf1sZSI/XmUIXKVNfBpZPtTBaDp7Vow== From: Kyle Meyer To: Alan Light Subject: Re: Bug fix attached: org-babel sql postgres, fix hardcode In-Reply-To: References: <87lfe2aosn.fsf@gnu.org> <877dpm7e3d.fsf@localhost> X-Woof-Patch: applied Date: Wed, 03 Feb 2021 23:19:14 -0500 Message-ID: <87wnvowjlp.fsf@kyleam.com> MIME-Version: 1.0 Content-Type: text/plain X-Migadu-Auth-User: kyle@kyleam.com Received-SPF: pass client-ip=91.121.223.63; envelope-from=kyle@kyleam.com; helo=out1.migadu.com X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Bastien , emacs-orgmode@gnu.org, Ihor Radchenko Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN X-Migadu-Spam-Score: -1.36 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=kyleam.com header.s=key1 header.b="gNgRd/qS"; dmarc=none; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Queue-Id: 6A07F9404DF X-Spam-Score: -1.36 X-Migadu-Scanner: scn1.migadu.com X-TUID: CW6mTGrrHKyE Thanks for the patch, and others for the review/feedback. Alan Light writes: > Subject: [PATCH 2/2] ob-sql.el: ob-sql.el (org-babel-execute:sql): Use > `sql-postgres-program' as postgresql executable (instead of psql) when > defined > > * ob-sql.el (org-babel-execute:sql): Use `sql-postgres-program' as > postgresql executable (instead of psql) when defined. psql will be the default I've squash this patch, which as Tom notes is a fixup on top of the initial one, into the first. I've also tweaked the commit message a bit, including adding TINYCHANGE. https://orgmode.org/worg/org-contribute.html#commit-messages > --- > lisp/org/ob-sql.el | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/lisp/org/ob-sql.el b/lisp/org/ob-sql.el > index 8eca769d02..f46c6c1c6a 100644 > --- a/lisp/org/ob-sql.el > +++ b/lisp/org/ob-sql.el > @@ -242,7 +242,7 @@ footer=off -F \"\t\" %s -f %s -o %s %s" > (if dbpassword > (format "PGPASSWORD=%s " dbpassword) > "") > - (or sql-postgres-program "psql") > + (or sql-postgres-program "psql") ;; default is psql As Tom noted, the use of sql-postgres-program here leads to a byte-compiler warning. It probably makes sense to just require sql.el in the file, but for now I've guarded this with a bound-and-true-p. Pushed (862048d4c). Thanks again.