refactor: Restructure project files for better organization, readability, and maintainability

This commit is contained in:
2024-11-04 08:48:38 +01:00
parent 096290bcb8
commit 4e49102433
22 changed files with 17 additions and 17 deletions

View File

@@ -17,7 +17,7 @@ limitations under the License.
package config package config
import ( import (
"github.com/jkaninda/goma-gateway/internal/logger" "github.com/jkaninda/goma-gateway/pkg/logger"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )

View File

@@ -16,8 +16,8 @@ See the License for the specific language governing permissions and
limitations under the License. limitations under the License.
*/ */
import ( import (
"github.com/jkaninda/goma-gateway/internal/logger" "github.com/jkaninda/goma-gateway/internal"
"github.com/jkaninda/goma-gateway/pkg" "github.com/jkaninda/goma-gateway/pkg/logger"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )

View File

@@ -18,7 +18,7 @@ package cmd
import ( import (
"github.com/jkaninda/goma-gateway/cmd/config" "github.com/jkaninda/goma-gateway/cmd/config"
"github.com/jkaninda/goma-gateway/internal/logger" "github.com/jkaninda/goma-gateway/pkg/logger"
"github.com/jkaninda/goma-gateway/util" "github.com/jkaninda/goma-gateway/util"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )

View File

@@ -20,8 +20,8 @@ import (
"context" "context"
"fmt" "fmt"
"github.com/common-nighthawk/go-figure" "github.com/common-nighthawk/go-figure"
"github.com/jkaninda/goma-gateway/internal/logger" "github.com/jkaninda/goma-gateway/internal"
"github.com/jkaninda/goma-gateway/pkg" "github.com/jkaninda/goma-gateway/pkg/logger"
"github.com/jkaninda/goma-gateway/util" "github.com/jkaninda/goma-gateway/util"
"github.com/spf13/cobra" "github.com/spf13/cobra"
) )

View File

@@ -17,7 +17,7 @@ limitations under the License.
*/ */
import ( import (
"fmt" "fmt"
"github.com/jkaninda/goma-gateway/internal/logger" "github.com/jkaninda/goma-gateway/pkg/logger"
"github.com/jkaninda/goma-gateway/util" "github.com/jkaninda/goma-gateway/util"
"github.com/spf13/cobra" "github.com/spf13/cobra"
"gopkg.in/yaml.v3" "gopkg.in/yaml.v3"

View File

@@ -18,7 +18,7 @@ limitations under the License.
import ( import (
"encoding/json" "encoding/json"
"github.com/gorilla/mux" "github.com/gorilla/mux"
"github.com/jkaninda/goma-gateway/internal/logger" "github.com/jkaninda/goma-gateway/pkg/logger"
"net/http" "net/http"
"sync" "sync"
) )

View File

@@ -17,7 +17,7 @@ limitations under the License.
*/ */
import ( import (
"fmt" "fmt"
"github.com/jkaninda/goma-gateway/internal/logger" "github.com/jkaninda/goma-gateway/pkg/logger"
"io" "io"
"net/http" "net/http"
"net/url" "net/url"

View File

@@ -18,7 +18,7 @@ limitations under the License.
import ( import (
"encoding/json" "encoding/json"
"fmt" "fmt"
"github.com/jkaninda/goma-gateway/internal/logger" "github.com/jkaninda/goma-gateway/pkg/logger"
"github.com/jkaninda/goma-gateway/util" "github.com/jkaninda/goma-gateway/util"
"net/http" "net/http"
"strings" "strings"

View File

@@ -19,7 +19,7 @@ package middleware
import ( import (
"bytes" "bytes"
"encoding/json" "encoding/json"
"github.com/jkaninda/goma-gateway/internal/logger" "github.com/jkaninda/goma-gateway/pkg/logger"
"io" "io"
"net/http" "net/http"
) )

View File

@@ -18,7 +18,7 @@ limitations under the License.
import ( import (
"encoding/base64" "encoding/base64"
"encoding/json" "encoding/json"
"github.com/jkaninda/goma-gateway/internal/logger" "github.com/jkaninda/goma-gateway/pkg/logger"
"io" "io"
"net/http" "net/http"
"net/url" "net/url"

View File

@@ -18,7 +18,7 @@ limitations under the License.
import ( import (
"encoding/json" "encoding/json"
"github.com/gorilla/mux" "github.com/gorilla/mux"
"github.com/jkaninda/goma-gateway/internal/logger" "github.com/jkaninda/goma-gateway/pkg/logger"
"net/http" "net/http"
"time" "time"
) )

View File

@@ -18,7 +18,7 @@ limitations under the License.
import ( import (
"encoding/json" "encoding/json"
"fmt" "fmt"
"github.com/jkaninda/goma-gateway/internal/logger" "github.com/jkaninda/goma-gateway/pkg/logger"
"net/http" "net/http"
"net/http/httputil" "net/http/httputil"
"net/url" "net/url"

View File

@@ -17,8 +17,8 @@ limitations under the License.
*/ */
import ( import (
"github.com/gorilla/mux" "github.com/gorilla/mux"
"github.com/jkaninda/goma-gateway/internal/logger" "github.com/jkaninda/goma-gateway/internal/middleware"
"github.com/jkaninda/goma-gateway/pkg/middleware" "github.com/jkaninda/goma-gateway/pkg/logger"
"github.com/jkaninda/goma-gateway/util" "github.com/jkaninda/goma-gateway/util"
"time" "time"
) )

View File

@@ -18,7 +18,7 @@ limitations under the License.
import ( import (
"context" "context"
"fmt" "fmt"
"github.com/jkaninda/goma-gateway/internal/logger" "github.com/jkaninda/goma-gateway/pkg/logger"
"net/http" "net/http"
"os" "os"
"sync" "sync"