Domain alias support for Mailman
[hcoop/domtool2.git] / src / plugins / mailman.sml
index b8925a3..236909c 100644 (file)
@@ -27,15 +27,15 @@ val () = Env.action_one "mailmanWebHost"
                        ("hostname", Env.string)
                        (fn host =>
                            let
-                               val outf = Domain.domainFile {node = Config.Mailman.node,
-                                                             name = "mailman"}
+                               val {write, writeDom, close} = Domain.domainsFile {node = Config.Mailman.node,
+                                                                                  name = "mailman"}
                            in
-                               TextIO.output (outf, "\t'");
-                               TextIO.output (outf, host);
-                               TextIO.output (outf, "' : '");
-                               TextIO.output (outf, Domain.currentDomain ());
-                               TextIO.output (outf, "',\n");
-                               TextIO.closeOut outf
+                               write "\t'";
+                               write host;
+                               write "' : '";
+                               writeDom ();
+                               write "',\n";
+                               close ()
                            end)
 
 val mailmanChanged = ref false