This commit is contained in:
parent
4c4e01ddb7
commit
fd729eef89
@ -53,4 +53,4 @@ OPTIONS:
|
||||
|
||||
### Recompile proto-files
|
||||
|
||||
`protoc --go_out=. --go-grpc_out=. --go_opt=module=gitea.benny.dog/torjus/ezshare --go-grpc_opt=module=gitea.benny.dog/torjus/ezshare protos/ezshare.proto`
|
||||
`protoc --go_out=. --go-grpc_out=. --go_opt=module=git.t-juice.club/torjus/ezshare --go-grpc_opt=module=git.t-juice.club/torjus/ezshare protos/ezshare.proto`
|
||||
|
@ -7,7 +7,7 @@ import (
|
||||
"path/filepath"
|
||||
"regexp"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/pb"
|
||||
"git.t-juice.club/torjus/ezshare/pb"
|
||||
"github.com/urfave/cli/v2"
|
||||
"google.golang.org/grpc"
|
||||
)
|
||||
|
@ -16,11 +16,11 @@ import (
|
||||
"syscall"
|
||||
"time"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/certs"
|
||||
"gitea.benny.dog/torjus/ezshare/config"
|
||||
"gitea.benny.dog/torjus/ezshare/ezshare"
|
||||
"gitea.benny.dog/torjus/ezshare/pb"
|
||||
"gitea.benny.dog/torjus/ezshare/server"
|
||||
"git.t-juice.club/torjus/ezshare/certs"
|
||||
"git.t-juice.club/torjus/ezshare/config"
|
||||
"git.t-juice.club/torjus/ezshare/ezshare"
|
||||
"git.t-juice.club/torjus/ezshare/pb"
|
||||
"git.t-juice.club/torjus/ezshare/server"
|
||||
"github.com/urfave/cli/v2"
|
||||
"golang.org/x/term"
|
||||
"google.golang.org/grpc"
|
||||
|
@ -4,8 +4,8 @@ import (
|
||||
"fmt"
|
||||
"os"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/certs"
|
||||
"gitea.benny.dog/torjus/ezshare/config"
|
||||
"git.t-juice.club/torjus/ezshare/certs"
|
||||
"git.t-juice.club/torjus/ezshare/config"
|
||||
"github.com/urfave/cli/v2"
|
||||
)
|
||||
|
||||
|
@ -15,11 +15,11 @@ import (
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/certs"
|
||||
"gitea.benny.dog/torjus/ezshare/pb"
|
||||
"gitea.benny.dog/torjus/ezshare/server"
|
||||
"gitea.benny.dog/torjus/ezshare/server/interceptors"
|
||||
"gitea.benny.dog/torjus/ezshare/store"
|
||||
"git.t-juice.club/torjus/ezshare/certs"
|
||||
"git.t-juice.club/torjus/ezshare/pb"
|
||||
"git.t-juice.club/torjus/ezshare/server"
|
||||
"git.t-juice.club/torjus/ezshare/server/interceptors"
|
||||
"git.t-juice.club/torjus/ezshare/store"
|
||||
"github.com/google/uuid"
|
||||
"github.com/urfave/cli/v2"
|
||||
"go.uber.org/zap"
|
||||
|
@ -13,7 +13,7 @@ import (
|
||||
"math/big"
|
||||
"time"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/store"
|
||||
"git.t-juice.club/torjus/ezshare/store"
|
||||
)
|
||||
|
||||
type CertService struct {
|
||||
|
@ -3,10 +3,11 @@ package certs_test
|
||||
import (
|
||||
"crypto/x509"
|
||||
"encoding/pem"
|
||||
"gitea.benny.dog/torjus/ezshare/certs"
|
||||
"gitea.benny.dog/torjus/ezshare/store"
|
||||
"github.com/google/uuid"
|
||||
"testing"
|
||||
|
||||
"git.t-juice.club/torjus/ezshare/certs"
|
||||
"git.t-juice.club/torjus/ezshare/store"
|
||||
"github.com/google/uuid"
|
||||
)
|
||||
|
||||
func TestCertService(t *testing.T) {
|
||||
|
@ -12,7 +12,7 @@ import (
|
||||
"path/filepath"
|
||||
"strings"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/store"
|
||||
"git.t-juice.club/torjus/ezshare/store"
|
||||
"github.com/pelletier/go-toml"
|
||||
"go.uber.org/zap"
|
||||
"go.uber.org/zap/zapcore"
|
||||
|
@ -5,7 +5,7 @@ import (
|
||||
"strings"
|
||||
"testing"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/config"
|
||||
"git.t-juice.club/torjus/ezshare/config"
|
||||
)
|
||||
|
||||
var configStrExample = `
|
||||
|
@ -1,4 +1,4 @@
|
||||
package ezshare
|
||||
|
||||
// TODO: Maybe put this somewhere more sensible
|
||||
const Version = "v0.1.10"
|
||||
const Version = "v0.1.11"
|
||||
|
2
go.mod
2
go.mod
@ -1,4 +1,4 @@
|
||||
module gitea.benny.dog/torjus/ezshare
|
||||
module git.t-juice.club/torjus/ezshare
|
||||
|
||||
go 1.17
|
||||
|
||||
|
4
main.go
4
main.go
@ -4,8 +4,8 @@ import (
|
||||
"log"
|
||||
"os"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/actions"
|
||||
"gitea.benny.dog/torjus/ezshare/ezshare"
|
||||
"git.t-juice.club/torjus/ezshare/actions"
|
||||
"git.t-juice.club/torjus/ezshare/ezshare"
|
||||
"github.com/urfave/cli/v2"
|
||||
)
|
||||
|
||||
|
@ -1845,10 +1845,10 @@ var file_protos_ezshare_proto_rawDesc = []byte{
|
||||
0x74, 0x65, 0x73, 0x74, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x2e, 0x65, 0x7a,
|
||||
0x73, 0x68, 0x61, 0x72, 0x65, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x1a, 0x1e, 0x2e, 0x65, 0x7a,
|
||||
0x73, 0x68, 0x61, 0x72, 0x65, 0x2e, 0x4c, 0x61, 0x74, 0x65, 0x73, 0x74, 0x56, 0x65, 0x72, 0x73,
|
||||
0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x23, 0x5a,
|
||||
0x21, 0x67, 0x69, 0x74, 0x65, 0x61, 0x2e, 0x62, 0x65, 0x6e, 0x6e, 0x79, 0x2e, 0x64, 0x6f, 0x67,
|
||||
0x2f, 0x74, 0x6f, 0x72, 0x6a, 0x75, 0x73, 0x2f, 0x65, 0x7a, 0x73, 0x68, 0x61, 0x72, 0x65, 0x2f,
|
||||
0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
0x69, 0x6f, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x24, 0x5a,
|
||||
0x22, 0x67, 0x69, 0x74, 0x2e, 0x74, 0x2d, 0x6a, 0x75, 0x69, 0x63, 0x65, 0x2e, 0x63, 0x6c, 0x75,
|
||||
0x62, 0x2f, 0x74, 0x6f, 0x72, 0x6a, 0x75, 0x73, 0x2f, 0x65, 0x7a, 0x73, 0x68, 0x61, 0x72, 0x65,
|
||||
0x2f, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
|
@ -3,7 +3,7 @@ package ezshare;
|
||||
|
||||
import "google/protobuf/timestamp.proto";
|
||||
|
||||
option go_package = "gitea.benny.dog/torjus/ezshare/pb";
|
||||
option go_package = "git.t-juice.club/torjus/ezshare/pb";
|
||||
|
||||
/////////////////////
|
||||
// Common messages //
|
||||
|
@ -3,10 +3,10 @@ package server
|
||||
import (
|
||||
"context"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/ezshare"
|
||||
"gitea.benny.dog/torjus/ezshare/pb"
|
||||
"gitea.benny.dog/torjus/ezshare/server/interceptors"
|
||||
"gitea.benny.dog/torjus/ezshare/store"
|
||||
"git.t-juice.club/torjus/ezshare/ezshare"
|
||||
"git.t-juice.club/torjus/ezshare/pb"
|
||||
"git.t-juice.club/torjus/ezshare/server/interceptors"
|
||||
"git.t-juice.club/torjus/ezshare/store"
|
||||
"go.uber.org/zap"
|
||||
"google.golang.org/grpc/codes"
|
||||
"google.golang.org/grpc/status"
|
||||
|
@ -3,10 +3,10 @@ package server
|
||||
import (
|
||||
"context"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/certs"
|
||||
"gitea.benny.dog/torjus/ezshare/pb"
|
||||
"gitea.benny.dog/torjus/ezshare/server/interceptors"
|
||||
"gitea.benny.dog/torjus/ezshare/store"
|
||||
"git.t-juice.club/torjus/ezshare/certs"
|
||||
"git.t-juice.club/torjus/ezshare/pb"
|
||||
"git.t-juice.club/torjus/ezshare/server/interceptors"
|
||||
"git.t-juice.club/torjus/ezshare/store"
|
||||
"go.uber.org/zap"
|
||||
"google.golang.org/grpc/codes"
|
||||
"google.golang.org/grpc/status"
|
||||
|
@ -5,9 +5,9 @@ import (
|
||||
"fmt"
|
||||
"time"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/pb"
|
||||
"gitea.benny.dog/torjus/ezshare/server/interceptors"
|
||||
"gitea.benny.dog/torjus/ezshare/store"
|
||||
"git.t-juice.club/torjus/ezshare/pb"
|
||||
"git.t-juice.club/torjus/ezshare/server/interceptors"
|
||||
"git.t-juice.club/torjus/ezshare/store"
|
||||
"github.com/dustin/go-humanize"
|
||||
"github.com/google/uuid"
|
||||
"go.uber.org/zap"
|
||||
|
@ -7,7 +7,7 @@ import (
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/store"
|
||||
"git.t-juice.club/torjus/ezshare/store"
|
||||
"github.com/go-chi/chi/v5"
|
||||
"go.uber.org/zap"
|
||||
)
|
||||
|
@ -3,9 +3,9 @@ package interceptors
|
||||
import (
|
||||
"context"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/certs"
|
||||
"gitea.benny.dog/torjus/ezshare/pb"
|
||||
"gitea.benny.dog/torjus/ezshare/store"
|
||||
"git.t-juice.club/torjus/ezshare/certs"
|
||||
"git.t-juice.club/torjus/ezshare/pb"
|
||||
"git.t-juice.club/torjus/ezshare/store"
|
||||
"go.uber.org/zap"
|
||||
"google.golang.org/grpc"
|
||||
"google.golang.org/grpc/codes"
|
||||
|
@ -4,10 +4,10 @@ import (
|
||||
"context"
|
||||
"fmt"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/certs"
|
||||
"gitea.benny.dog/torjus/ezshare/pb"
|
||||
"gitea.benny.dog/torjus/ezshare/server/interceptors"
|
||||
"gitea.benny.dog/torjus/ezshare/store"
|
||||
"git.t-juice.club/torjus/ezshare/certs"
|
||||
"git.t-juice.club/torjus/ezshare/pb"
|
||||
"git.t-juice.club/torjus/ezshare/server/interceptors"
|
||||
"git.t-juice.club/torjus/ezshare/store"
|
||||
"github.com/google/uuid"
|
||||
"go.uber.org/zap"
|
||||
"golang.org/x/crypto/bcrypt"
|
||||
|
@ -6,7 +6,7 @@ import (
|
||||
"fmt"
|
||||
"strings"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/pb"
|
||||
"git.t-juice.club/torjus/ezshare/pb"
|
||||
"github.com/google/uuid"
|
||||
bolt "go.etcd.io/bbolt"
|
||||
"google.golang.org/protobuf/proto"
|
||||
|
@ -5,7 +5,7 @@ import (
|
||||
"path/filepath"
|
||||
"testing"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/store"
|
||||
"git.t-juice.club/torjus/ezshare/store"
|
||||
)
|
||||
|
||||
func TestBoltStore(t *testing.T) {
|
||||
|
@ -8,7 +8,7 @@ import (
|
||||
"os"
|
||||
"path/filepath"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/pb"
|
||||
"git.t-juice.club/torjus/ezshare/pb"
|
||||
"github.com/google/uuid"
|
||||
)
|
||||
|
||||
|
@ -3,7 +3,7 @@ package store_test
|
||||
import (
|
||||
"testing"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/store"
|
||||
"git.t-juice.club/torjus/ezshare/store"
|
||||
)
|
||||
|
||||
func TestFileStore(t *testing.T) {
|
||||
|
@ -8,7 +8,7 @@ import (
|
||||
"strings"
|
||||
"sync"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/pb"
|
||||
"git.t-juice.club/torjus/ezshare/pb"
|
||||
"github.com/google/uuid"
|
||||
)
|
||||
|
||||
|
@ -3,7 +3,7 @@ package store_test
|
||||
import (
|
||||
"testing"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/store"
|
||||
"git.t-juice.club/torjus/ezshare/store"
|
||||
)
|
||||
|
||||
func TestMemoryFileStore(t *testing.T) {
|
||||
|
@ -5,7 +5,7 @@ import (
|
||||
"crypto/x509"
|
||||
"fmt"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/pb"
|
||||
"git.t-juice.club/torjus/ezshare/pb"
|
||||
)
|
||||
|
||||
var ErrNoSuchItem = fmt.Errorf("no such item")
|
||||
|
@ -14,8 +14,8 @@ import (
|
||||
"github.com/google/uuid"
|
||||
"google.golang.org/protobuf/testing/protocmp"
|
||||
|
||||
"gitea.benny.dog/torjus/ezshare/pb"
|
||||
"gitea.benny.dog/torjus/ezshare/store"
|
||||
"git.t-juice.club/torjus/ezshare/pb"
|
||||
"git.t-juice.club/torjus/ezshare/store"
|
||||
"google.golang.org/protobuf/types/known/timestamppb"
|
||||
)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user