From 2a3ccb71df70fe986c7995fd418a644dd0a9d18d Mon Sep 17 00:00:00 2001 From: Boming Zhang Date: Thu, 28 Nov 2024 10:31:33 -0500 Subject: [PATCH] refactor: move cmd/joj3/conf to internal/conf --- cmd/joj3/log.go | 2 +- cmd/joj3/main.go | 2 +- cmd/joj3/stage/run.go | 2 +- cmd/joj3/teapot/check.go | 2 +- cmd/joj3/teapot/run.go | 2 +- {cmd/joj3 => internal}/conf/conf.go | 0 {cmd/joj3 => internal}/conf/conf_test.go | 0 7 files changed, 5 insertions(+), 5 deletions(-) rename {cmd/joj3 => internal}/conf/conf.go (100%) rename {cmd/joj3 => internal}/conf/conf_test.go (100%) diff --git a/cmd/joj3/log.go b/cmd/joj3/log.go index 95c765e..9c685e4 100644 --- a/cmd/joj3/log.go +++ b/cmd/joj3/log.go @@ -7,8 +7,8 @@ import ( "log/slog" "os" - "github.com/joint-online-judge/JOJ3/cmd/joj3/conf" "github.com/joint-online-judge/JOJ3/cmd/joj3/env" + "github.com/joint-online-judge/JOJ3/internal/conf" ) var runningTest bool diff --git a/cmd/joj3/main.go b/cmd/joj3/main.go index 6cd0527..9842e25 100644 --- a/cmd/joj3/main.go +++ b/cmd/joj3/main.go @@ -6,10 +6,10 @@ import ( "log/slog" "os" - "github.com/joint-online-judge/JOJ3/cmd/joj3/conf" "github.com/joint-online-judge/JOJ3/cmd/joj3/env" "github.com/joint-online-judge/JOJ3/cmd/joj3/stage" "github.com/joint-online-judge/JOJ3/cmd/joj3/teapot" + "github.com/joint-online-judge/JOJ3/internal/conf" internalStage "github.com/joint-online-judge/JOJ3/internal/stage" ) diff --git a/cmd/joj3/stage/run.go b/cmd/joj3/stage/run.go index 78cd8f6..e89ee9c 100644 --- a/cmd/joj3/stage/run.go +++ b/cmd/joj3/stage/run.go @@ -5,8 +5,8 @@ import ( "log/slog" "strings" - "github.com/joint-online-judge/JOJ3/cmd/joj3/conf" "github.com/joint-online-judge/JOJ3/cmd/joj3/teapot" + "github.com/joint-online-judge/JOJ3/internal/conf" executors "github.com/joint-online-judge/JOJ3/internal/executor" _ "github.com/joint-online-judge/JOJ3/internal/parser" "github.com/joint-online-judge/JOJ3/internal/stage" diff --git a/cmd/joj3/teapot/check.go b/cmd/joj3/teapot/check.go index 3eb0bcd..7cf458d 100644 --- a/cmd/joj3/teapot/check.go +++ b/cmd/joj3/teapot/check.go @@ -7,8 +7,8 @@ import ( "os" "strings" - "github.com/joint-online-judge/JOJ3/cmd/joj3/conf" "github.com/joint-online-judge/JOJ3/cmd/joj3/env" + "github.com/joint-online-judge/JOJ3/internal/conf" ) type CheckResult struct { diff --git a/cmd/joj3/teapot/run.go b/cmd/joj3/teapot/run.go index 3b685b1..924ac92 100644 --- a/cmd/joj3/teapot/run.go +++ b/cmd/joj3/teapot/run.go @@ -8,8 +8,8 @@ import ( "strconv" "strings" - "github.com/joint-online-judge/JOJ3/cmd/joj3/conf" "github.com/joint-online-judge/JOJ3/cmd/joj3/env" + "github.com/joint-online-judge/JOJ3/internal/conf" ) type RunResult struct { diff --git a/cmd/joj3/conf/conf.go b/internal/conf/conf.go similarity index 100% rename from cmd/joj3/conf/conf.go rename to internal/conf/conf.go diff --git a/cmd/joj3/conf/conf_test.go b/internal/conf/conf_test.go similarity index 100% rename from cmd/joj3/conf/conf_test.go rename to internal/conf/conf_test.go