mirror of
https://github.com/OpenFactorioServerManager/factorio-server-manager.git
synced 2025-01-14 04:35:58 +02:00
Merge pull request #243 from OpenFactorioServerManager/update-imports
Renamed go package
This commit is contained in:
commit
9acf80ab6d
@ -2,13 +2,14 @@ package api
|
||||
|
||||
import (
|
||||
"encoding/base64"
|
||||
"log"
|
||||
"net/http"
|
||||
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/bootstrap"
|
||||
"github.com/gorilla/sessions"
|
||||
"github.com/mroote/factorio-server-manager/bootstrap"
|
||||
"golang.org/x/crypto/bcrypt"
|
||||
"gorm.io/driver/sqlite"
|
||||
"gorm.io/gorm"
|
||||
"log"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
type User bootstrap.User
|
||||
|
@ -4,9 +4,6 @@ import (
|
||||
"encoding/json"
|
||||
"errors"
|
||||
"fmt"
|
||||
"github.com/gorilla/sessions"
|
||||
"github.com/mroote/factorio-server-manager/bootstrap"
|
||||
"github.com/mroote/factorio-server-manager/factorio"
|
||||
"io"
|
||||
"io/ioutil"
|
||||
"log"
|
||||
@ -17,6 +14,10 @@ import (
|
||||
"sync"
|
||||
"time"
|
||||
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/bootstrap"
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/factorio"
|
||||
"github.com/gorilla/sessions"
|
||||
|
||||
"github.com/gorilla/mux"
|
||||
)
|
||||
|
||||
|
@ -4,14 +4,15 @@ import (
|
||||
"archive/zip"
|
||||
"errors"
|
||||
"fmt"
|
||||
"github.com/gorilla/mux"
|
||||
"github.com/mroote/factorio-server-manager/bootstrap"
|
||||
"github.com/mroote/factorio-server-manager/factorio"
|
||||
"io"
|
||||
"log"
|
||||
"net/http"
|
||||
"os"
|
||||
"path/filepath"
|
||||
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/bootstrap"
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/factorio"
|
||||
"github.com/gorilla/mux"
|
||||
)
|
||||
|
||||
func CheckModPackExists(modPackMap factorio.ModPackMap, modPackName string, w http.ResponseWriter) (resp interface{}, err error) {
|
||||
|
@ -3,10 +3,6 @@ package api
|
||||
import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
"github.com/gorilla/mux"
|
||||
"github.com/mroote/factorio-server-manager/bootstrap"
|
||||
"github.com/mroote/factorio-server-manager/factorio"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"io"
|
||||
"mime/multipart"
|
||||
"net/http"
|
||||
@ -15,6 +11,11 @@ import (
|
||||
"path/filepath"
|
||||
"strings"
|
||||
"testing"
|
||||
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/bootstrap"
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/factorio"
|
||||
"github.com/gorilla/mux"
|
||||
"github.com/stretchr/testify/assert"
|
||||
)
|
||||
|
||||
func SetupModPacks(t *testing.T, empty bool, emptyMods bool) {
|
||||
|
@ -2,10 +2,11 @@ package api
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"github.com/gorilla/mux"
|
||||
"github.com/mroote/factorio-server-manager/factorio"
|
||||
"log"
|
||||
"net/http"
|
||||
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/factorio"
|
||||
"github.com/gorilla/mux"
|
||||
)
|
||||
|
||||
func ModPortalListModsHandler(w http.ResponseWriter, r *http.Request) {
|
||||
|
@ -4,14 +4,15 @@ import (
|
||||
"archive/zip"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"github.com/mroote/factorio-server-manager/bootstrap"
|
||||
"github.com/mroote/factorio-server-manager/factorio"
|
||||
"github.com/mroote/factorio-server-manager/lockfile"
|
||||
"io"
|
||||
"log"
|
||||
"net/http"
|
||||
"os"
|
||||
"path/filepath"
|
||||
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/bootstrap"
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/factorio"
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/lockfile"
|
||||
)
|
||||
|
||||
func CreateNewMods(w http.ResponseWriter) (modList factorio.Mods, resp interface{}, err error) {
|
||||
|
@ -2,12 +2,6 @@ package api
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"github.com/gorilla/mux"
|
||||
"github.com/joho/godotenv"
|
||||
"github.com/mroote/factorio-server-manager/bootstrap"
|
||||
"github.com/mroote/factorio-server-manager/factorio"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
"io"
|
||||
"log"
|
||||
"mime/multipart"
|
||||
@ -17,6 +11,13 @@ import (
|
||||
"path/filepath"
|
||||
"strings"
|
||||
"testing"
|
||||
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/bootstrap"
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/factorio"
|
||||
"github.com/gorilla/mux"
|
||||
"github.com/joho/godotenv"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
)
|
||||
|
||||
func TestMain(m *testing.M) {
|
||||
|
@ -1,9 +1,10 @@
|
||||
package api
|
||||
|
||||
import (
|
||||
"github.com/mroote/factorio-server-manager/api/websocket"
|
||||
"net/http"
|
||||
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/api/websocket"
|
||||
|
||||
"github.com/gorilla/mux"
|
||||
)
|
||||
|
||||
|
@ -1,8 +1,9 @@
|
||||
package websocket
|
||||
|
||||
import (
|
||||
"github.com/mroote/factorio-server-manager/bootstrap"
|
||||
"reflect"
|
||||
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/bootstrap"
|
||||
)
|
||||
|
||||
// the hub, that is exported and can be used anywhere to work with the websocket
|
||||
|
@ -3,10 +3,11 @@ package factorio
|
||||
import (
|
||||
"encoding/json"
|
||||
"errors"
|
||||
"github.com/mroote/factorio-server-manager/bootstrap"
|
||||
"io/ioutil"
|
||||
"log"
|
||||
"os"
|
||||
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/bootstrap"
|
||||
)
|
||||
|
||||
type Credentials struct {
|
||||
|
@ -1,9 +1,10 @@
|
||||
package factorio
|
||||
|
||||
import (
|
||||
"github.com/hpcloud/tail"
|
||||
"github.com/mroote/factorio-server-manager/bootstrap"
|
||||
"log"
|
||||
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/bootstrap"
|
||||
"github.com/hpcloud/tail"
|
||||
)
|
||||
|
||||
func TailLog() ([]string, error) {
|
||||
|
@ -5,13 +5,14 @@ import (
|
||||
"bytes"
|
||||
"errors"
|
||||
"fmt"
|
||||
"github.com/mroote/factorio-server-manager/lockfile"
|
||||
"io"
|
||||
"io/ioutil"
|
||||
"log"
|
||||
"mime/multipart"
|
||||
"net/http"
|
||||
"path/filepath"
|
||||
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/lockfile"
|
||||
)
|
||||
|
||||
type Mods struct {
|
||||
|
@ -4,13 +4,14 @@ import (
|
||||
"archive/zip"
|
||||
"encoding/json"
|
||||
"errors"
|
||||
"github.com/mroote/factorio-server-manager/lockfile"
|
||||
"io"
|
||||
"io/ioutil"
|
||||
"log"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"strings"
|
||||
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/lockfile"
|
||||
)
|
||||
|
||||
type ModInfoList struct {
|
||||
|
@ -2,12 +2,13 @@ package factorio
|
||||
|
||||
import (
|
||||
"errors"
|
||||
"github.com/mroote/factorio-server-manager/bootstrap"
|
||||
"io"
|
||||
"io/ioutil"
|
||||
"log"
|
||||
"os"
|
||||
"path/filepath"
|
||||
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/bootstrap"
|
||||
)
|
||||
|
||||
type ModPackMap map[string]*ModPack
|
||||
|
@ -5,12 +5,13 @@ import (
|
||||
"bytes"
|
||||
"encoding/json"
|
||||
"errors"
|
||||
"github.com/mroote/factorio-server-manager/bootstrap"
|
||||
"io/ioutil"
|
||||
"log"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"strings"
|
||||
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/bootstrap"
|
||||
)
|
||||
|
||||
type LoginErrorResponse struct {
|
||||
|
@ -1,11 +1,12 @@
|
||||
package factorio
|
||||
|
||||
import (
|
||||
"github.com/mroote/factorio-server-manager/bootstrap"
|
||||
"log"
|
||||
"strconv"
|
||||
|
||||
"github.com/majormjr/rcon"
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/bootstrap"
|
||||
|
||||
"github.com/OpenFactorioServerManager/rcon"
|
||||
)
|
||||
|
||||
func connectRC() error {
|
||||
|
@ -3,12 +3,13 @@ package factorio
|
||||
import (
|
||||
"errors"
|
||||
"fmt"
|
||||
"github.com/mroote/factorio-server-manager/bootstrap"
|
||||
"log"
|
||||
"os"
|
||||
"os/exec"
|
||||
"path/filepath"
|
||||
"time"
|
||||
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/bootstrap"
|
||||
)
|
||||
|
||||
type Save struct {
|
||||
|
@ -14,10 +14,9 @@ import (
|
||||
"strings"
|
||||
"sync"
|
||||
|
||||
"github.com/mroote/factorio-server-manager/api/websocket"
|
||||
"github.com/mroote/factorio-server-manager/bootstrap"
|
||||
|
||||
"github.com/majormjr/rcon"
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/api/websocket"
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/bootstrap"
|
||||
"github.com/OpenFactorioServerManager/rcon"
|
||||
)
|
||||
|
||||
type Server struct {
|
||||
|
@ -1,8 +1,9 @@
|
||||
module github.com/mroote/factorio-server-manager
|
||||
module github.com/OpenFactorioServerManager/factorio-server-manager
|
||||
|
||||
go 1.13
|
||||
|
||||
require (
|
||||
github.com/OpenFactorioServerManager/rcon v0.0.0-20120923215419-8fbb8268b60a
|
||||
github.com/go-ini/ini v1.49.0
|
||||
github.com/golang/protobuf v1.3.1 // indirect
|
||||
github.com/gorilla/mux v1.7.3
|
||||
@ -12,7 +13,6 @@ require (
|
||||
github.com/hpcloud/tail v1.0.0
|
||||
github.com/jessevdk/go-flags v1.4.0
|
||||
github.com/joho/godotenv v1.3.0
|
||||
github.com/majormjr/rcon v0.0.0-20120923215419-8fbb8268b60a
|
||||
github.com/smartystreets/goconvey v0.0.0-20190731233626-505e41936337 // indirect
|
||||
github.com/stretchr/testify v1.6.1
|
||||
github.com/syndtr/goleveldb v1.0.0
|
||||
|
@ -1,3 +1,5 @@
|
||||
github.com/OpenFactorioServerManager/rcon v0.0.0-20120923215419-8fbb8268b60a h1:BExxUM1IlQh7ba2D7ZTQ/aHe65YLI0GHgoPe1c3IIdA=
|
||||
github.com/OpenFactorioServerManager/rcon v0.0.0-20120923215419-8fbb8268b60a/go.mod h1:ttMDbVLzmIWHIVGL6Wa+QG+hCzURs5gZDT12l5spIlg=
|
||||
github.com/davecgh/go-spew v1.1.0 h1:ZDRjVQ15GmhC3fiQ8ni8+OwkZQO4DARzQgrnXU1Liz8=
|
||||
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||
github.com/fsnotify/fsnotify v1.4.7 h1:IXs+QLmnXW2CcXuY+8Mzv/fWEsPGWxqefPtCP5CnV9I=
|
||||
@ -32,8 +34,6 @@ github.com/joho/godotenv v1.3.0 h1:Zjp+RcGpHhGlrMbJzXTrZZPrWj+1vfm90La1wgB6Bhc=
|
||||
github.com/joho/godotenv v1.3.0/go.mod h1:7hK45KPybAkOC6peb+G5yklZfMxEjkZhHbwpqxOKXbg=
|
||||
github.com/jtolds/gls v4.20.0+incompatible h1:xdiiI2gbIgH/gLH7ADydsJ1uDOEzR8yvV7C0MuV77Wo=
|
||||
github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU=
|
||||
github.com/majormjr/rcon v0.0.0-20120923215419-8fbb8268b60a h1:rXEd7/SA5sJvgl2zxM/nNblGa9kkpnx2phQATclw9Xk=
|
||||
github.com/majormjr/rcon v0.0.0-20120923215419-8fbb8268b60a/go.mod h1:RNVV4T548mxgb643odZHF+pWh/YmGLxiKvtkbI1vRYE=
|
||||
github.com/mattn/go-sqlite3 v1.14.5 h1:1IdxlwTNazvbKJQSxoJ5/9ECbEeaTTyeU7sEAZ5KKTQ=
|
||||
github.com/mattn/go-sqlite3 v1.14.5/go.mod h1:WVKg1VTActs4Qso6iwGbiFih2UIHo0ENGwNd0Lj+XmI=
|
||||
github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE=
|
||||
|
@ -5,9 +5,9 @@ import (
|
||||
"net/http"
|
||||
"os"
|
||||
|
||||
"github.com/mroote/factorio-server-manager/api"
|
||||
"github.com/mroote/factorio-server-manager/bootstrap"
|
||||
"github.com/mroote/factorio-server-manager/factorio"
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/api"
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/bootstrap"
|
||||
"github.com/OpenFactorioServerManager/factorio-server-manager/factorio"
|
||||
)
|
||||
|
||||
func main() {
|
||||
|
Loading…
Reference in New Issue
Block a user