package main

import (
	"flag"
	"log"
)

func checkErr(err error) {
	if err != nil {
		log.Fatal(err)
	}
}

func main() {
	var (
		excel_file string
		get_top    bool
		month      int
	)

	flag.StringVar(&excel_file, "file", "", "The path to the excel file for processing")
	flag.BoolVar(&get_top, "get_top", false, "A command to get the top performers for the current month")
	flag.IntVar(&month, "month", 0, "Sets the month for the data to process")
	flag.Parse()

	run := NewRunner()
	if excel_file != "" {
		ProcessExcel(excel_file)
	} else if get_top {
		run.GetTop()
	} else {
		flag.PrintDefaults()
	}
}
