summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorArtyom V. Poptsov <poptsov.artyom@gmail.com>2016-12-18 10:52:34 +0300
committerArtyom V. Poptsov <poptsov.artyom@gmail.com>2016-12-18 10:52:34 +0300
commit9dedbbd546c08515ff6e569e317d3752a3981759 (patch)
treec0acead7be37dedb50b18cb6b62a1919d6dedee9 /modules
parentmodules/ssh/shell.scm: Fix commentary (diff)
downloadguile-ssh-9dedbbd546c08515ff6e569e317d3752a3981759.tar.gz
shell.scm (fallback-pgrep): Bugfix: Fix the format string
* modules/ssh/shell.scm (fallback-pgrep): Bugfix: Use (ice-9 format), replace all '~' with '~~'.
Diffstat (limited to 'modules')
-rw-r--r--modules/ssh/shell.scm3
1 files changed, 2 insertions, 1 deletions
diff --git a/modules/ssh/shell.scm b/modules/ssh/shell.scm
index a920825..62bf392 100644
--- a/modules/ssh/shell.scm
+++ b/modules/ssh/shell.scm
@@ -38,6 +38,7 @@
(define-module (ssh shell)
#:use-module (ice-9 rdelim)
#:use-module (ice-9 regex)
+ #:use-module (ice-9 format)
#:use-module (ssh channel)
#:use-module (ssh popen)
#:export (rexec which pgrep fallback-pgrep command-available?))
@@ -90,7 +91,7 @@ Return two values: a check result and a return code."
(format #f "\
echo '
for p in $(ls /proc); do
- if [[ \"$p\" =~ ^[0-9]+ ]]; then
+ if [[ \"$p\" =~~ ^[0-9]+ ]]; then
name=$(cat \"/proc/$p/status\" 2>/dev/null | head -1);
if [[ \"$name\" =~~ Name:.*guile ]]; then
cmdline=$(cat \"/proc/$p/cmdline\");