aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOmar Polo <op@omarpolo.com>2020-11-28 12:06:47 +0100
committerOmar Polo <op@omarpolo.com>2020-11-28 12:06:47 +0100
commitd4069e1560eda6edd0f1d7258e1cea78a5e62a81 (patch)
treed5a4997f7b83d250d172b4c2180f32e6d4544f94
parent7de51bee1e5fe03de8a5e4c566d6f104414c4bf6 (diff)
downloadsam.el-d4069e1560eda6edd0f1d7258e1cea78a5e62a81.tar.gz
sam.el-d4069e1560eda6edd0f1d7258e1cea78a5e62a81.tar.bz2
docs & style changes for sam-exec-command
-rw-r--r--sam.el10
1 files changed, 5 insertions, 5 deletions
diff --git a/sam.el b/sam.el
index 7230a49..6019c0d 100644
--- a/sam.el
+++ b/sam.el
@@ -135,11 +135,11 @@
when (string-equal command cmd) return `(,command . ,fn)))
(defun sam-exec-command (cmd)
- (let ((tmp (sam-parse-command cmd)))
- (if tmp
- (cl-destructuring-bind (cmd . fn) tmp
- (funcall fn (substring cmd (length cmd))))
- (sam-report-error (concat "unknown command: " cmd)))))
+ "Execute the string CMD as sam command."
+ (if-let (tmp (sam-parse-command cmd))
+ (cl-destructuring-bind (cmd . fn) tmp
+ (funcall fn (substring cmd (length cmd))))
+ (sam-report-error (concat "unknown command: " cmd))))
(defun sam-exec-line ()
"Run the sam command on this line."