Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
I
inferior-shell
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
qitab
inferior-shell
Commits
ecd21c67
Commit
ecd21c67
authored
12 years ago
by
Francois-Rene Rideau
Browse files
Options
Downloads
Patches
Plain Diff
Support :output :interactively as a hack on CCL and SBCL.
parent
8914d215
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
run.lisp
+29
-13
29 additions, 13 deletions
run.lisp
with
29 additions
and
13 deletions
run.lisp
+
29
−
13
View file @
ecd21c67
...
@@ -28,26 +28,42 @@
...
@@ -28,26 +28,42 @@
spec
spec
`
(
ssh
,
host
,
(
print-process-spec
spec
))))
`
(
ssh
,
host
,
(
print-process-spec
spec
))))
(
deftype
direct-command-spec
()
'
(
and
command-spec
(
satisfies
direct-command-spec-p
)))
(
defun
direct-command-spec-p
(
spec
)
(
and
(
typep
spec
'command-spec
)
(
null
(
command-redirections
spec
))))
(
defun
run-spec
(
spec
&key
ignore-error-status
output
)
(
defun
run-spec
(
spec
&key
ignore-error-status
output
)
(
let
((
command
(
let*
((
command
(
if
(
and
(
typep
spec
'command-spec
)
(
if
(
consp
spec
)
(
null
(
command-redirections
spec
)))
(
parse-process-spec
spec
)
(
command-arguments
spec
)
spec
))
(
print-process-spec
spec
))))
(
command
(
if
(
eq
output
t
)
(
etypecase
command
(
run-program/
command
:ignore-error-status
ignore-error-status
)
(
direct-command-spec
(
run-program/
command
(
command-arguments
spec
))
:ignore-error-status
ignore-error-status
(
process-spec
:output
output
))))
(
print-process-spec
spec
))
(
string
spec
))))
(
case
output
((
t
)
(
run-program/
command
:ignore-error-status
ignore-error-status
))
((
:interactively
)
(
run-program/interactively
command
:ignore-error-status
ignore-error-status
))
(
otherwise
(
run-program/
command
:ignore-error-status
ignore-error-status
:output
output
)))))
(
defun
run-process-spec
(
spec
&rest
keys
&key
ignore-error-status
output
host
backend
)
(
defun
run-process-spec
(
spec
&rest
keys
&key
ignore-error-status
output
host
backend
)
(
etypecase
host
(
etypecase
host
(
null
(
null
(
etypecase
spec
(
etypecase
spec
(
string
(
string
(
if
(
eq
output
t
)
(
run-spec
spec
:ignore-error-status
ignore-error-status
:output
output
))
(
run-program/
spec
:ignore-error-status
ignore-error-status
)
(
apply
'run-program/
spec
keys
)))
(
cons
(
cons
(
apply
'run-process-spec
(
parse-process-spec
spec
)
keys
))
(
apply
'run-process-spec
(
parse-process-spec
spec
)
keys
))
(
process-spec
(
process-spec
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment