unofficial mirror of gwl-devel@gnu.org
 help / color / mirror / Atom feed
* what colour should the bikeshed have?
@ 2019-06-21 13:14 Ricardo Wurmus
  2019-06-24 10:23 ` zimoun
  2019-06-24 22:24 ` Ricardo Wurmus
  0 siblings, 2 replies; 5+ messages in thread
From: Ricardo Wurmus @ 2019-06-21 13:14 UTC (permalink / raw)
  To: gwl-devel

Hello there,

recently we changed some <process> field names (“package-inputs” and
“data-inputs”) and I thought that maybe we should talk about the
“procedure” field.

Currently, a process might look like this:

  process: greet
    packages "hello"
    procedure '(system "hello")

Or like this:

  process: sleep
    packages "coreutils"
    procedure # bash {
      echo "Sleeping..."
      sleep 10
    }

I think “procedure # bash {” is a bit long for a very common use case.
Since “# bash {…}” is special syntax implemented with a reader macro I’m
not sure if or how we can do better.

I think we might be able to do this:

  process: sleep
    packages "coreutils"
    # bash {
      echo "Sleeping..."
      sleep 10
    }

…if we somehow rewrote the reader macro to expand to the full field
definition, or if we changed the “process:” macro to expect a bare code
snippet at the end without the need for a field assignment, though this
would not be possible (or too ugly) in plain Scheme.

But even if we can’t do that, maybe we could just replace
the very long “procedure” with the much shorter “run”:

  process: sleep
    packages "coreutils"
    run # bash {
      echo "Sleeping..."
      sleep 10
    }

Obviously, this would work fine in plain Scheme.

What do you think?  Is it worth trying / doing?

--
Ricardo

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2019-06-25 15:32 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-06-21 13:14 what colour should the bikeshed have? Ricardo Wurmus
2019-06-24 10:23 ` zimoun
2019-06-24 13:33   ` Ricardo Wurmus
2019-06-25 15:32   ` Ricardo Wurmus
2019-06-24 22:24 ` Ricardo Wurmus

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).