#lang scheme/base

(require "main.ss"
         (prefix-in log: (planet synx/log))
         scheme/vector)

(when (< (vector-length (current-command-line-arguments)) 1)
  (display "Entry-points:")(newline)
  (for-each
   (λ (point) (display #\tab) (display point)(newline))
   (entry-points))
  (error "Please provide root and entry point as command line arguments."))

(let ((root (vector-ref (current-command-line-arguments) 0))
      (points (if (= 1 (vector-length (current-command-line-arguments)))
                  '(main)
                  (map string->symbol (vector->list (vector-drop (current-command-line-arguments) 1))))))
  (for-each
   (λ (point)
     (enter root point))
   points))