Skip to content

Commit

Permalink
refactor: Move log file name to cosntants
Browse files Browse the repository at this point in the history
  • Loading branch information
eslam-allam committed Apr 6, 2024
1 parent 4facb56 commit 68dccae
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion cmd/spring-initializer/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ var logger *log.Logger = log.Default()

func main() {
tmpDir := os.TempDir()
f, err := tea.LogToFile(path.Join(tmpDir, "spring-init.log"), "Main loop")
f, err := tea.LogToFile(path.Join(tmpDir, constants.LogFileName), "Main loop")
if err != nil {
fmt.Printf("Failed to start logger: %v", err)
os.Exit(1)
Expand Down
1 change: 1 addition & 0 deletions constants/constants.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,6 @@ const (
)

const (
LogFileName = "spring-init.log"
SpringUrl = "https://start.spring.io"
)

0 comments on commit 68dccae

Please sign in to comment.