main.go 345 B

123456789101112131415161718192021
  1. package main
  2. import (
  3. "log"
  4. "os"
  5. "github.com/kujtimiihoxha/termai/cmd"
  6. )
  7. func main() {
  8. // Create a log file and make that the log output DEBUG
  9. // TODO: remove this on release
  10. logfile, err := os.OpenFile("debug.log", os.O_CREATE|os.O_WRONLY|os.O_APPEND, 0o666)
  11. if err != nil {
  12. panic(err)
  13. }
  14. log.SetOutput(logfile)
  15. cmd.Execute()
  16. }