aboutsummaryrefslogtreecommitdiff
path: root/src/connection.lisp
diff options
context:
space:
mode:
authorSean Whitton <spwhitton@spwhitton.name>2021-05-02 13:06:57 -0700
committerSean Whitton <spwhitton@spwhitton.name>2021-05-06 12:23:51 -0700
commit41b04c179964b7cc6a83e6749c436b3ba6cb0d39 (patch)
tree97216f221effbaea3ca1762cc0b2fcdf0b8efe25 /src/connection.lisp
parent0f9b6517daad070a144baae9925f12b15fec3ff7 (diff)
downloadconsfigurator-41b04c179964b7cc6a83e6749c436b3ba6cb0d39.tar.gz
replace WITH-LOCAL-... with an EVALS property
Signed-off-by: Sean Whitton <spwhitton@spwhitton.name>
Diffstat (limited to 'src/connection.lisp')
-rw-r--r--src/connection.lisp16
1 files changed, 0 insertions, 16 deletions
diff --git a/src/connection.lisp b/src/connection.lisp
index 0ebe348..487559d 100644
--- a/src/connection.lisp
+++ b/src/connection.lisp
@@ -436,22 +436,6 @@ PATH may be any kind of file, including directories."
(mrun :may-fail #?"chown ${uid}:${gid} ${namestring}")))))
(connection-writefile *connection* namestring content mode)))
-(defmacro with-local-connection (&body forms)
- "Execute FORMS as though a :LOCAL connection had been established.
-This is for testing purposes at the REPL and in Consfigurator's test suite.
-FORMS is typically the programmatic application of one or more properties."
- `(let ((*host* (make-host :propspec (make-propspec :systems nil)))
- (*connection* (establish-connection :local nil)))
- ,@forms))
-
-(defmacro with-local-passwordless-sudo-connection (&body forms)
- "Execute FORMS as though a passwordless :SUDO connection to localhost had been
-established. Occasionally useful for testing purposes at the REPL."
- `(with-local-connection
- (let ((*connection* (establish-connection :sudo nil
- :user "root" :password nil)))
- ,@forms)))
-
;;;; Connection attributes