Rename app->internal

This commit is contained in:
Maximilian 2024-07-10 17:45:04 -05:00
parent ce85d6b77b
commit ce03926ce6
21 changed files with 22 additions and 22 deletions

View File

@ -1,7 +1,7 @@
package database
import (
"GoWeb/app"
"GoWeb/internal"
"database/sql"
"fmt"
_ "github.com/lib/pq"

View File

@ -1,7 +1,7 @@
package database
import (
"GoWeb/app"
"GoWeb/internal"
"errors"
"fmt"
"github.com/lib/pq"

View File

@ -12,7 +12,7 @@
"HttpPort": "8090"
},
"Template": {
"BaseTemplateName": "app/frontend/templates/base.html",
"ContentPath": "app/frontend/templates"
"BaseTemplateName": "internal/frontend/templates/base.html",
"ContentPath": "internal/frontend/templates"
}
}

View File

@ -1,8 +1,8 @@
package controllers
import (
"GoWeb/app"
"GoWeb/app/models"
"GoWeb/internal"
"GoWeb/internal/models"
"GoWeb/security"
"GoWeb/templating"
"net/http"

View File

@ -1,8 +1,8 @@
package controllers
import (
"GoWeb/app"
"GoWeb/app/models"
"GoWeb/internal"
"GoWeb/internal/models"
"log/slog"
"net/http"
"time"

View File

@ -1,8 +1,8 @@
package models
import (
"GoWeb/app"
"GoWeb/database"
"GoWeb/internal"
"time"
)

View File

@ -1,7 +1,7 @@
package models
import (
"GoWeb/app"
"GoWeb/internal"
"crypto/rand"
"encoding/hex"
"log/slog"

View File

@ -1,7 +1,7 @@
package models
import (
"GoWeb/app"
"GoWeb/internal"
"crypto/sha256"
"encoding/hex"
"log/slog"

View File

@ -1,8 +1,8 @@
package routes
import (
"GoWeb/app"
"GoWeb/app/controllers"
"GoWeb/internal"
"GoWeb/internal/controllers"
"io/fs"
"log/slog"
"net/http"

View File

@ -1,9 +1,9 @@
package routes
import (
"GoWeb/app"
"GoWeb/app/controllers"
"GoWeb/app/middleware"
"GoWeb/internal"
"GoWeb/internal/controllers"
"GoWeb/internal/middleware"
"net/http"
)

View File

@ -1,11 +1,11 @@
package main
import (
"GoWeb/app"
"GoWeb/app/models"
"GoWeb/app/routes"
"GoWeb/config"
"GoWeb/database"
"GoWeb/internal"
"GoWeb/internal/models"
"GoWeb/internal/routes"
"GoWeb/templating"
"context"
"embed"
@ -18,7 +18,7 @@ import (
"time"
)
//go:embed app/frontend/templates app/frontend/static
//go:embed internal/frontend/templates internal/frontend/static
var res embed.FS
func main() {

View File

@ -1,7 +1,7 @@
package templating
import (
"GoWeb/app"
"GoWeb/internal"
"fmt"
"html/template"
"io/fs"
@ -9,7 +9,7 @@ import (
"net/http"
)
var templates = make(map[string]*template.Template) // This is only used here, does not need to be in app.Deps
var templates = make(map[string]*template.Template) // This is only used here, does not need to be in internal.Deps
func BuildPages(app *app.Deps) error {
basePath := app.Config.Template.BaseName