Erlang filesystem (a bit long) (was: Re: File versioning)

Luke Gorrie luke@REDACTED
Fri May 9 06:19:00 CEST 2003


Luke Gorrie <luke@REDACTED> writes:

> Of course, a real man would have no hesitation in doing it like this:

Sorry, bad joke.

Of course what I meant was:

  #!/bin/sh
  ERLANG_MODE_DIR="/home/luke/elisp"
  DISTEL_DIR="/home/luke/hacking/distel/elisp"
  if [ $# -lt 2 ]; then
      echo "Usage: $0 <node> <expr>..."
      exit 1
  fi
  node=$1; shift
  expr="$@"
  emacs --batch \
        -L ${ERLANG_MODE_DIR} \
        -L ${DISTEL_DIR} \
        --eval "
  (progn
    (require 'distel)
    (setq erl-nodeup-hook nil)  ; suppress 'nodeup' message
    (let ((pid (erl-eval-expression '${node} \"${expr}\")))
      (while (erl-local-pid-alive-p pid)
        (accept-process-output))))"

So you can just say:

  $ ./tellerl x@REDACTED "{code_path_size, length(code:get_path())}."
  {code_path_size,44}

But then, "C-c C-d :" is marginally less keystrokes than "tellerl" ;-)

-Luke




More information about the erlang-questions mailing list