let main () =
  Arg.parse options (fun _ -> ())
    (Printf.sprintf "Usage %s [options]\nwhere options are:" Sys.argv.(0));
  let log =
    match !exec with
      Some params -> get_cvslog params
    | None -> string_of_in_channel Pervasives.stdin
  in
  let items = rss_items_of_log log in
  let items =
    match !max_items with
      None -> items
    | Some n -> List.rev (list_n_first n (List.rev items))
  in
  let channel = Rss.channel
      ~title: !title
      ~link: !link
      ~desc: !desc
      ~pubdate: (Rss.float_to_date (Unix.time()))
      items
  in
  Rss.print_channel Format.std_formatter channel