(setq fmt "{%s}") (setq pat "\\{([^}]*)\\}") (setq src (open (main-args 2) "read")) (println "
")

(while (read-line src)
  (setq line (current-line))
  (if (= (length (find-all pat line)) 5)
    (replace pat line (format fmt $1 $1) 0x8000))
  (println line))

(println "
") (close src) (exit)