Moved everything to internal

This commit is contained in:
OLUWADAMILOLA OKUSANYA 2023-11-24 21:17:09 -05:00
parent cb52ddab05
commit f3dede1e33
17 changed files with 26 additions and 23 deletions

2
.gitignore vendored
View File

@ -1 +1,3 @@
**/userdata/*
examples
tests

View File

@ -2,7 +2,7 @@ package gosimplenpm
import (
"fmt"
"gosimplenpm/config"
"gosimplenpm/internal/config"
"os"
"github.com/spf13/cobra"

View File

@ -2,8 +2,8 @@ package gosimplenpm
import (
"fmt"
"gosimplenpm/config"
"gosimplenpm/handler"
"gosimplenpm/internal/config"
"gosimplenpm/internal/handler"
"os"
"github.com/sirupsen/logrus"

View File

@ -1,8 +1,8 @@
package handler
import (
"gosimplenpm/config"
"gosimplenpm/middlewares"
"gosimplenpm/internal/config"
"gosimplenpm/internal/middlewares"
"net/http"
"time"

View File

@ -8,8 +8,8 @@ import (
"github.com/gorilla/mux"
"github.com/sirupsen/logrus"
"gosimplenpm/config"
"gosimplenpm/storage"
"gosimplenpm/internal/config"
"gosimplenpm/internal/storage"
)
func GetPackage(lg *logrus.Logger, cfg config.Config) http.HandlerFunc {

View File

@ -0,0 +1 @@
package handler

View File

@ -3,9 +3,9 @@ package handler
import (
"encoding/json"
"fmt"
"gosimplenpm/config"
"gosimplenpm/serviceidos"
"gosimplenpm/storage"
"gosimplenpm/internal/config"
"gosimplenpm/internal/serviceidos"
"gosimplenpm/internal/storage"
"net/http"
"net/url"
"path"

View File

@ -3,9 +3,9 @@ package handler
import (
"encoding/json"
"fmt"
"gosimplenpm/config"
"gosimplenpm/serviceidos"
"gosimplenpm/storage"
"gosimplenpm/internal/config"
"gosimplenpm/internal/serviceidos"
"gosimplenpm/internal/storage"
"net/http"
"net/url"
"strconv"

View File

@ -3,9 +3,9 @@ package handler
import (
"encoding/json"
"fmt"
"gosimplenpm/config"
"gosimplenpm/serviceidos"
"gosimplenpm/storage"
"gosimplenpm/internal/config"
"gosimplenpm/internal/serviceidos"
"gosimplenpm/internal/storage"
"net/http"
"net/url"
"strconv"

View File

@ -3,9 +3,9 @@ package handler
import (
"encoding/json"
"fmt"
"gosimplenpm/config"
"gosimplenpm/serviceidos"
"gosimplenpm/storage"
"gosimplenpm/internal/config"
"gosimplenpm/internal/serviceidos"
"gosimplenpm/internal/storage"
"io"
"net/http"
"net/url"

View File

@ -2,8 +2,8 @@ package handler
import (
"bytes"
"gosimplenpm/config"
"gosimplenpm/storage"
"gosimplenpm/internal/config"
"gosimplenpm/internal/storage"
"io"
"net/http"
"net/url"

View File

@ -1,7 +1,7 @@
package middlewares
import (
"gosimplenpm/config"
"gosimplenpm/internal/config"
"net/http"
"strings"
)

View File

@ -12,7 +12,7 @@ import (
"path"
"strings"
"gosimplenpm/serviceidos"
"gosimplenpm/internal/serviceidos"
"path/filepath"
"github.com/sirupsen/logrus"