emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/pq 795260553a 17/63: Use load-path in test.el


From: ELPA Syncer
Subject: [elpa] externals/pq 795260553a 17/63: Use load-path in test.el
Date: Mon, 14 Feb 2022 23:24:20 -0500 (EST)

branch: externals/pq
commit 795260553ad4252f74f90bbcc7b4a00fc2b76166
Author: Mario Rodas <marsam@users.noreply.github.com>
Commit: Mario Rodas <marsam@users.noreply.github.com>

    Use load-path in test.el
    
    To avoid hard coding library path
---
 test.el | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/test.el b/test.el
index cf7e92e6e9..c999567ef2 100644
--- a/test.el
+++ b/test.el
@@ -1,4 +1,8 @@
-(load-library "~/src/emacs-module-postgres/pq.so")
+(add-to-list 'load-path
+             (file-name-directory (or #$ (expand-file-name 
(buffer-file-name)))))
+
+(require 'pq)
+
 (setq con (pq:connectdb "port=5433 dbname=smith"))
 (pq:query con "select version()")
 ;; ("PostgreSQL 9.4.8 on i686-pc-linux-gnu, compiled by gcc (Debian 4.9.2-10) 
4.9.2, 32-bit")



reply via email to

[Prev in Thread] Current Thread [Next in Thread]