diff --git a/cmd/stfs/cmd/operation_archive.go b/cmd/stfs/cmd/operation_archive.go index e427410..b28c57e 100644 --- a/cmd/stfs/cmd/operation_archive.go +++ b/cmd/stfs/cmd/operation_archive.go @@ -8,9 +8,10 @@ import ( "path/filepath" "github.com/pojntfx/stfs/internal/check" - "github.com/pojntfx/stfs/internal/keys" + "github.com/pojntfx/stfs/internal/keyext" "github.com/pojntfx/stfs/internal/logging" "github.com/pojntfx/stfs/pkg/config" + "github.com/pojntfx/stfs/pkg/keys" "github.com/pojntfx/stfs/pkg/operations" "github.com/pojntfx/stfs/pkg/persisters" "github.com/pojntfx/stfs/pkg/tape" @@ -48,7 +49,7 @@ var operationArchiveCmd = &cobra.Command{ return check.CheckKeyAccessible(viper.GetString(signatureFlag), viper.GetString(identityFlag)) }, RunE: func(cmd *cobra.Command, args []string) error { - pubkey, err := keys.ReadKey(viper.GetString(encryptionFlag), viper.GetString(recipientFlag)) + pubkey, err := keyext.ReadKey(viper.GetString(encryptionFlag), viper.GetString(recipientFlag)) if err != nil { return err } @@ -58,7 +59,7 @@ var operationArchiveCmd = &cobra.Command{ return err } - privkey, err := keys.ReadKey(viper.GetString(signatureFlag), viper.GetString(identityFlag)) + privkey, err := keyext.ReadKey(viper.GetString(signatureFlag), viper.GetString(identityFlag)) if err != nil { return err } diff --git a/cmd/stfs/cmd/operation_delete.go b/cmd/stfs/cmd/operation_delete.go index 5c0982f..5679f5e 100644 --- a/cmd/stfs/cmd/operation_delete.go +++ b/cmd/stfs/cmd/operation_delete.go @@ -2,9 +2,10 @@ package cmd import ( "github.com/pojntfx/stfs/internal/check" - "github.com/pojntfx/stfs/internal/keys" + "github.com/pojntfx/stfs/internal/keyext" "github.com/pojntfx/stfs/internal/logging" "github.com/pojntfx/stfs/pkg/config" + "github.com/pojntfx/stfs/pkg/keys" "github.com/pojntfx/stfs/pkg/operations" "github.com/pojntfx/stfs/pkg/persisters" "github.com/pojntfx/stfs/pkg/tape" @@ -32,7 +33,7 @@ var operationDeleteCmd = &cobra.Command{ return check.CheckKeyAccessible(viper.GetString(signatureFlag), viper.GetString(identityFlag)) }, RunE: func(cmd *cobra.Command, args []string) error { - pubkey, err := keys.ReadKey(viper.GetString(encryptionFlag), viper.GetString(recipientFlag)) + pubkey, err := keyext.ReadKey(viper.GetString(encryptionFlag), viper.GetString(recipientFlag)) if err != nil { return err } @@ -42,7 +43,7 @@ var operationDeleteCmd = &cobra.Command{ return err } - privkey, err := keys.ReadKey(viper.GetString(signatureFlag), viper.GetString(identityFlag)) + privkey, err := keyext.ReadKey(viper.GetString(signatureFlag), viper.GetString(identityFlag)) if err != nil { return err } diff --git a/cmd/stfs/cmd/operation_move.go b/cmd/stfs/cmd/operation_move.go index 33f2afa..c3dbc37 100644 --- a/cmd/stfs/cmd/operation_move.go +++ b/cmd/stfs/cmd/operation_move.go @@ -2,9 +2,10 @@ package cmd import ( "github.com/pojntfx/stfs/internal/check" - "github.com/pojntfx/stfs/internal/keys" + "github.com/pojntfx/stfs/internal/keyext" "github.com/pojntfx/stfs/internal/logging" "github.com/pojntfx/stfs/pkg/config" + "github.com/pojntfx/stfs/pkg/keys" "github.com/pojntfx/stfs/pkg/operations" "github.com/pojntfx/stfs/pkg/persisters" "github.com/pojntfx/stfs/pkg/tape" @@ -28,7 +29,7 @@ var operationMoveCmd = &cobra.Command{ return check.CheckKeyAccessible(viper.GetString(signatureFlag), viper.GetString(identityFlag)) }, RunE: func(cmd *cobra.Command, args []string) error { - pubkey, err := keys.ReadKey(viper.GetString(encryptionFlag), viper.GetString(recipientFlag)) + pubkey, err := keyext.ReadKey(viper.GetString(encryptionFlag), viper.GetString(recipientFlag)) if err != nil { return err } @@ -38,7 +39,7 @@ var operationMoveCmd = &cobra.Command{ return err } - privkey, err := keys.ReadKey(viper.GetString(signatureFlag), viper.GetString(identityFlag)) + privkey, err := keyext.ReadKey(viper.GetString(signatureFlag), viper.GetString(identityFlag)) if err != nil { return err } diff --git a/cmd/stfs/cmd/operation_restore.go b/cmd/stfs/cmd/operation_restore.go index 867459e..fe624f1 100644 --- a/cmd/stfs/cmd/operation_restore.go +++ b/cmd/stfs/cmd/operation_restore.go @@ -6,9 +6,10 @@ import ( "os" "github.com/pojntfx/stfs/internal/check" - "github.com/pojntfx/stfs/internal/keys" + "github.com/pojntfx/stfs/internal/keyext" "github.com/pojntfx/stfs/internal/logging" "github.com/pojntfx/stfs/pkg/config" + "github.com/pojntfx/stfs/pkg/keys" "github.com/pojntfx/stfs/pkg/operations" "github.com/pojntfx/stfs/pkg/persisters" "github.com/pojntfx/stfs/pkg/tape" @@ -36,7 +37,7 @@ var operationRestoreCmd = &cobra.Command{ return check.CheckKeyAccessible(viper.GetString(signatureFlag), viper.GetString(recipientFlag)) }, RunE: func(cmd *cobra.Command, args []string) error { - pubkey, err := keys.ReadKey(viper.GetString(signatureFlag), viper.GetString(recipientFlag)) + pubkey, err := keyext.ReadKey(viper.GetString(signatureFlag), viper.GetString(recipientFlag)) if err != nil { return err } @@ -46,7 +47,7 @@ var operationRestoreCmd = &cobra.Command{ return err } - privkey, err := keys.ReadKey(viper.GetString(encryptionFlag), viper.GetString(identityFlag)) + privkey, err := keyext.ReadKey(viper.GetString(encryptionFlag), viper.GetString(identityFlag)) if err != nil { return err } diff --git a/cmd/stfs/cmd/operation_update.go b/cmd/stfs/cmd/operation_update.go index 4aae6bc..31e0956 100644 --- a/cmd/stfs/cmd/operation_update.go +++ b/cmd/stfs/cmd/operation_update.go @@ -8,9 +8,10 @@ import ( "path/filepath" "github.com/pojntfx/stfs/internal/check" - "github.com/pojntfx/stfs/internal/keys" + "github.com/pojntfx/stfs/internal/keyext" "github.com/pojntfx/stfs/internal/logging" "github.com/pojntfx/stfs/pkg/config" + "github.com/pojntfx/stfs/pkg/keys" "github.com/pojntfx/stfs/pkg/operations" "github.com/pojntfx/stfs/pkg/persisters" "github.com/pojntfx/stfs/pkg/tape" @@ -38,7 +39,7 @@ var operationUpdateCmd = &cobra.Command{ return check.CheckKeyAccessible(viper.GetString(signatureFlag), viper.GetString(identityFlag)) }, RunE: func(cmd *cobra.Command, args []string) error { - pubkey, err := keys.ReadKey(viper.GetString(encryptionFlag), viper.GetString(recipientFlag)) + pubkey, err := keyext.ReadKey(viper.GetString(encryptionFlag), viper.GetString(recipientFlag)) if err != nil { return err } @@ -48,7 +49,7 @@ var operationUpdateCmd = &cobra.Command{ return err } - privkey, err := keys.ReadKey(viper.GetString(signatureFlag), viper.GetString(identityFlag)) + privkey, err := keyext.ReadKey(viper.GetString(signatureFlag), viper.GetString(identityFlag)) if err != nil { return err } diff --git a/cmd/stfs/cmd/recovery_fetch.go b/cmd/stfs/cmd/recovery_fetch.go index 03721ff..5eb6f78 100644 --- a/cmd/stfs/cmd/recovery_fetch.go +++ b/cmd/stfs/cmd/recovery_fetch.go @@ -6,9 +6,10 @@ import ( "os" "github.com/pojntfx/stfs/internal/check" - "github.com/pojntfx/stfs/internal/keys" + "github.com/pojntfx/stfs/internal/keyext" "github.com/pojntfx/stfs/internal/logging" "github.com/pojntfx/stfs/pkg/config" + "github.com/pojntfx/stfs/pkg/keys" "github.com/pojntfx/stfs/pkg/recovery" "github.com/pojntfx/stfs/pkg/tape" "github.com/spf13/cobra" @@ -37,7 +38,7 @@ var recoveryFetchCmd = &cobra.Command{ return check.CheckKeyAccessible(viper.GetString(signatureFlag), viper.GetString(recipientFlag)) }, RunE: func(cmd *cobra.Command, args []string) error { - pubkey, err := keys.ReadKey(viper.GetString(signatureFlag), viper.GetString(recipientFlag)) + pubkey, err := keyext.ReadKey(viper.GetString(signatureFlag), viper.GetString(recipientFlag)) if err != nil { return err } @@ -47,7 +48,7 @@ var recoveryFetchCmd = &cobra.Command{ return err } - privkey, err := keys.ReadKey(viper.GetString(encryptionFlag), viper.GetString(identityFlag)) + privkey, err := keyext.ReadKey(viper.GetString(encryptionFlag), viper.GetString(identityFlag)) if err != nil { return err } diff --git a/cmd/stfs/cmd/recovery_index.go b/cmd/stfs/cmd/recovery_index.go index 33152b3..dbaa793 100644 --- a/cmd/stfs/cmd/recovery_index.go +++ b/cmd/stfs/cmd/recovery_index.go @@ -4,13 +4,14 @@ import ( "archive/tar" "github.com/pojntfx/stfs/internal/check" - "github.com/pojntfx/stfs/internal/encryption" - "github.com/pojntfx/stfs/internal/keys" + "github.com/pojntfx/stfs/internal/keyext" "github.com/pojntfx/stfs/internal/logging" - "github.com/pojntfx/stfs/internal/signature" "github.com/pojntfx/stfs/pkg/config" + "github.com/pojntfx/stfs/pkg/encryption" + "github.com/pojntfx/stfs/pkg/keys" "github.com/pojntfx/stfs/pkg/persisters" "github.com/pojntfx/stfs/pkg/recovery" + "github.com/pojntfx/stfs/pkg/signature" "github.com/pojntfx/stfs/pkg/tape" "github.com/spf13/cobra" "github.com/spf13/viper" @@ -31,7 +32,7 @@ var recoveryIndexCmd = &cobra.Command{ return check.CheckKeyAccessible(viper.GetString(signatureFlag), viper.GetString(recipientFlag)) }, RunE: func(cmd *cobra.Command, args []string) error { - pubkey, err := keys.ReadKey(viper.GetString(signatureFlag), viper.GetString(recipientFlag)) + pubkey, err := keyext.ReadKey(viper.GetString(signatureFlag), viper.GetString(recipientFlag)) if err != nil { return err } @@ -41,7 +42,7 @@ var recoveryIndexCmd = &cobra.Command{ return err } - privkey, err := keys.ReadKey(viper.GetString(encryptionFlag), viper.GetString(identityFlag)) + privkey, err := keyext.ReadKey(viper.GetString(encryptionFlag), viper.GetString(identityFlag)) if err != nil { return err } diff --git a/cmd/stfs/cmd/recovery_query.go b/cmd/stfs/cmd/recovery_query.go index 3b2512e..bb6d869 100644 --- a/cmd/stfs/cmd/recovery_query.go +++ b/cmd/stfs/cmd/recovery_query.go @@ -2,9 +2,10 @@ package cmd import ( "github.com/pojntfx/stfs/internal/check" - "github.com/pojntfx/stfs/internal/keys" + "github.com/pojntfx/stfs/internal/keyext" "github.com/pojntfx/stfs/internal/logging" "github.com/pojntfx/stfs/pkg/config" + "github.com/pojntfx/stfs/pkg/keys" "github.com/pojntfx/stfs/pkg/recovery" "github.com/pojntfx/stfs/pkg/tape" "github.com/spf13/cobra" @@ -26,7 +27,7 @@ var recoveryQueryCmd = &cobra.Command{ return check.CheckKeyAccessible(viper.GetString(signatureFlag), viper.GetString(recipientFlag)) }, RunE: func(cmd *cobra.Command, args []string) error { - pubkey, err := keys.ReadKey(viper.GetString(signatureFlag), viper.GetString(recipientFlag)) + pubkey, err := keyext.ReadKey(viper.GetString(signatureFlag), viper.GetString(recipientFlag)) if err != nil { return err } @@ -36,7 +37,7 @@ var recoveryQueryCmd = &cobra.Command{ return err } - privkey, err := keys.ReadKey(viper.GetString(encryptionFlag), viper.GetString(identityFlag)) + privkey, err := keyext.ReadKey(viper.GetString(encryptionFlag), viper.GetString(identityFlag)) if err != nil { return err } diff --git a/cmd/stfs/cmd/serve_ftp.go b/cmd/stfs/cmd/serve_ftp.go index 5def0d4..e4d2d8c 100644 --- a/cmd/stfs/cmd/serve_ftp.go +++ b/cmd/stfs/cmd/serve_ftp.go @@ -10,17 +10,18 @@ import ( ftpserver "github.com/fclairamb/ftpserverlib" "github.com/pojntfx/stfs/internal/check" - "github.com/pojntfx/stfs/internal/encryption" "github.com/pojntfx/stfs/internal/ftp" - "github.com/pojntfx/stfs/internal/keys" + "github.com/pojntfx/stfs/internal/keyext" "github.com/pojntfx/stfs/internal/logging" - "github.com/pojntfx/stfs/internal/signature" "github.com/pojntfx/stfs/pkg/cache" "github.com/pojntfx/stfs/pkg/config" + "github.com/pojntfx/stfs/pkg/encryption" sfs "github.com/pojntfx/stfs/pkg/fs" + "github.com/pojntfx/stfs/pkg/keys" "github.com/pojntfx/stfs/pkg/operations" "github.com/pojntfx/stfs/pkg/persisters" "github.com/pojntfx/stfs/pkg/recovery" + "github.com/pojntfx/stfs/pkg/signature" "github.com/pojntfx/stfs/pkg/tape" "github.com/spf13/cobra" "github.com/spf13/viper" @@ -74,22 +75,22 @@ var serveFTPCmd = &cobra.Command{ return check.CheckKeyAccessible(viper.GetString(signatureFlag), viper.GetString(signatureRecipientFlag)) }, RunE: func(cmd *cobra.Command, args []string) error { - signaturePubkey, err := keys.ReadKey(viper.GetString(signatureFlag), viper.GetString(signatureRecipientFlag)) + signaturePubkey, err := keyext.ReadKey(viper.GetString(signatureFlag), viper.GetString(signatureRecipientFlag)) if err != nil { return err } - signaturePrivkey, err := keys.ReadKey(viper.GetString(signatureFlag), viper.GetString(signatureIdentityFlag)) + signaturePrivkey, err := keyext.ReadKey(viper.GetString(signatureFlag), viper.GetString(signatureIdentityFlag)) if err != nil { return err } - encryptionPubkey, err := keys.ReadKey(viper.GetString(encryptionFlag), viper.GetString(encryptionRecipientFlag)) + encryptionPubkey, err := keyext.ReadKey(viper.GetString(encryptionFlag), viper.GetString(encryptionRecipientFlag)) if err != nil { return err } - encryptionPrivkey, err := keys.ReadKey(viper.GetString(encryptionFlag), viper.GetString(encryptionIdentityFlag)) + encryptionPrivkey, err := keyext.ReadKey(viper.GetString(encryptionFlag), viper.GetString(encryptionIdentityFlag)) if err != nil { return err } diff --git a/cmd/stfs/cmd/serve_http.go b/cmd/stfs/cmd/serve_http.go index 3526ddc..410b51e 100644 --- a/cmd/stfs/cmd/serve_http.go +++ b/cmd/stfs/cmd/serve_http.go @@ -9,11 +9,12 @@ import ( "github.com/pojntfx/stfs/internal/check" "github.com/pojntfx/stfs/internal/handlers" - "github.com/pojntfx/stfs/internal/keys" + "github.com/pojntfx/stfs/internal/keyext" "github.com/pojntfx/stfs/internal/logging" "github.com/pojntfx/stfs/pkg/cache" "github.com/pojntfx/stfs/pkg/config" sfs "github.com/pojntfx/stfs/pkg/fs" + "github.com/pojntfx/stfs/pkg/keys" "github.com/pojntfx/stfs/pkg/operations" "github.com/pojntfx/stfs/pkg/persisters" "github.com/pojntfx/stfs/pkg/tape" @@ -49,7 +50,7 @@ var serveHTTPCmd = &cobra.Command{ return check.CheckKeyAccessible(viper.GetString(signatureFlag), viper.GetString(recipientFlag)) }, RunE: func(cmd *cobra.Command, args []string) error { - pubkey, err := keys.ReadKey(viper.GetString(signatureFlag), viper.GetString(recipientFlag)) + pubkey, err := keyext.ReadKey(viper.GetString(signatureFlag), viper.GetString(recipientFlag)) if err != nil { return err } @@ -59,7 +60,7 @@ var serveHTTPCmd = &cobra.Command{ return err } - privkey, err := keys.ReadKey(viper.GetString(encryptionFlag), viper.GetString(identityFlag)) + privkey, err := keyext.ReadKey(viper.GetString(encryptionFlag), viper.GetString(identityFlag)) if err != nil { return err } diff --git a/internal/db/sqlite/models/metadata/boil_main_test.go b/internal/db/sqlite/models/metadata/boil_main_test.go index 361c0f2..31dda3f 100644 --- a/internal/db/sqlite/models/metadata/boil_main_test.go +++ b/internal/db/sqlite/models/metadata/boil_main_test.go @@ -21,7 +21,7 @@ import ( var flagDebugMode = flag.Bool("test.sqldebug", false, "Turns on debug mode for SQL statements") var flagConfigFile = flag.String("test.config", "", "Overrides the default config") -const outputDirDepth = 5 +const outputDirDepth = 7 var ( dbMain tester diff --git a/internal/keys/read.go b/internal/keyext/read.go similarity index 94% rename from internal/keys/read.go rename to internal/keyext/read.go index acded85..3057580 100644 --- a/internal/keys/read.go +++ b/internal/keyext/read.go @@ -1,4 +1,4 @@ -package keys +package keyext import ( "io/ioutil" diff --git a/internal/compression/compress.go b/pkg/compression/compress.go similarity index 100% rename from internal/compression/compress.go rename to pkg/compression/compress.go diff --git a/internal/compression/decompress.go b/pkg/compression/decompress.go similarity index 100% rename from internal/compression/decompress.go rename to pkg/compression/decompress.go diff --git a/internal/encryption/decrypt.go b/pkg/encryption/decrypt.go similarity index 100% rename from internal/encryption/decrypt.go rename to pkg/encryption/decrypt.go diff --git a/internal/encryption/encrypt.go b/pkg/encryption/encrypt.go similarity index 100% rename from internal/encryption/encrypt.go rename to pkg/encryption/encrypt.go diff --git a/internal/keys/identity.go b/pkg/keys/identity.go similarity index 100% rename from internal/keys/identity.go rename to pkg/keys/identity.go diff --git a/internal/keys/recipient.go b/pkg/keys/recipient.go similarity index 100% rename from internal/keys/recipient.go rename to pkg/keys/recipient.go diff --git a/pkg/operations/archive.go b/pkg/operations/archive.go index 24cfef2..491dce5 100644 --- a/pkg/operations/archive.go +++ b/pkg/operations/archive.go @@ -8,17 +8,17 @@ import ( "strconv" "strings" - "github.com/pojntfx/stfs/internal/compression" "github.com/pojntfx/stfs/internal/converters" - "github.com/pojntfx/stfs/internal/encryption" "github.com/pojntfx/stfs/internal/ioext" "github.com/pojntfx/stfs/internal/mtio" "github.com/pojntfx/stfs/internal/records" - "github.com/pojntfx/stfs/internal/signature" "github.com/pojntfx/stfs/internal/suffix" "github.com/pojntfx/stfs/internal/tarext" + "github.com/pojntfx/stfs/pkg/compression" "github.com/pojntfx/stfs/pkg/config" + "github.com/pojntfx/stfs/pkg/encryption" "github.com/pojntfx/stfs/pkg/recovery" + "github.com/pojntfx/stfs/pkg/signature" ) var ( diff --git a/pkg/operations/delete.go b/pkg/operations/delete.go index d91ed24..864cc5b 100644 --- a/pkg/operations/delete.go +++ b/pkg/operations/delete.go @@ -6,12 +6,12 @@ import ( "path/filepath" "github.com/pojntfx/stfs/internal/converters" - "github.com/pojntfx/stfs/internal/encryption" "github.com/pojntfx/stfs/internal/records" - "github.com/pojntfx/stfs/internal/signature" "github.com/pojntfx/stfs/internal/tarext" "github.com/pojntfx/stfs/pkg/config" + "github.com/pojntfx/stfs/pkg/encryption" "github.com/pojntfx/stfs/pkg/recovery" + "github.com/pojntfx/stfs/pkg/signature" ) func (o *Operations) Delete(name string) error { diff --git a/pkg/operations/move.go b/pkg/operations/move.go index e850a6a..8fb7cf5 100644 --- a/pkg/operations/move.go +++ b/pkg/operations/move.go @@ -8,12 +8,12 @@ import ( "strings" "github.com/pojntfx/stfs/internal/converters" - "github.com/pojntfx/stfs/internal/encryption" "github.com/pojntfx/stfs/internal/records" - "github.com/pojntfx/stfs/internal/signature" "github.com/pojntfx/stfs/internal/tarext" "github.com/pojntfx/stfs/pkg/config" + "github.com/pojntfx/stfs/pkg/encryption" "github.com/pojntfx/stfs/pkg/recovery" + "github.com/pojntfx/stfs/pkg/signature" ) func (o *Operations) Move(from string, to string) error { diff --git a/pkg/operations/update.go b/pkg/operations/update.go index 5f8dece..49fe188 100644 --- a/pkg/operations/update.go +++ b/pkg/operations/update.go @@ -7,17 +7,17 @@ import ( "strconv" "strings" - "github.com/pojntfx/stfs/internal/compression" "github.com/pojntfx/stfs/internal/converters" - "github.com/pojntfx/stfs/internal/encryption" "github.com/pojntfx/stfs/internal/ioext" "github.com/pojntfx/stfs/internal/mtio" "github.com/pojntfx/stfs/internal/records" - "github.com/pojntfx/stfs/internal/signature" "github.com/pojntfx/stfs/internal/suffix" "github.com/pojntfx/stfs/internal/tarext" + "github.com/pojntfx/stfs/pkg/compression" "github.com/pojntfx/stfs/pkg/config" + "github.com/pojntfx/stfs/pkg/encryption" "github.com/pojntfx/stfs/pkg/recovery" + "github.com/pojntfx/stfs/pkg/signature" ) func (o *Operations) Update( diff --git a/pkg/persisters/metadata.go b/pkg/persisters/metadata.go index 6aaeb0a..3ec52f3 100644 --- a/pkg/persisters/metadata.go +++ b/pkg/persisters/metadata.go @@ -1,7 +1,7 @@ package persisters -//go:generate sqlboiler sqlite3 -o ../db/sqlite/models/metadata -c ../../configs/sqlboiler/metadata.yaml -//go:generate go-bindata -pkg metadata -o ../db/sqlite/migrations/metadata/migrations.go ../../db/sqlite/migrations/metadata +//go:generate sqlboiler sqlite3 -o ../../internal/db/sqlite/models/metadata -c ../../configs/sqlboiler/metadata.yaml +//go:generate go-bindata -pkg metadata -o ../../internal/db/sqlite/migrations/metadata/migrations.go ../../db/sqlite/migrations/metadata import ( "context" diff --git a/pkg/recovery/fetch.go b/pkg/recovery/fetch.go index 69fa29d..53e80ae 100644 --- a/pkg/recovery/fetch.go +++ b/pkg/recovery/fetch.go @@ -8,13 +8,13 @@ import ( "path" "path/filepath" - "github.com/pojntfx/stfs/internal/compression" "github.com/pojntfx/stfs/internal/converters" - "github.com/pojntfx/stfs/internal/encryption" "github.com/pojntfx/stfs/internal/mtio" "github.com/pojntfx/stfs/internal/records" - "github.com/pojntfx/stfs/internal/signature" + "github.com/pojntfx/stfs/pkg/compression" "github.com/pojntfx/stfs/pkg/config" + "github.com/pojntfx/stfs/pkg/encryption" + "github.com/pojntfx/stfs/pkg/signature" ) func Fetch( diff --git a/pkg/recovery/query.go b/pkg/recovery/query.go index 13588e9..191c7dc 100644 --- a/pkg/recovery/query.go +++ b/pkg/recovery/query.go @@ -8,11 +8,11 @@ import ( "math" "github.com/pojntfx/stfs/internal/converters" - "github.com/pojntfx/stfs/internal/encryption" "github.com/pojntfx/stfs/internal/ioext" "github.com/pojntfx/stfs/internal/mtio" - "github.com/pojntfx/stfs/internal/signature" "github.com/pojntfx/stfs/pkg/config" + "github.com/pojntfx/stfs/pkg/encryption" + "github.com/pojntfx/stfs/pkg/signature" ) func Query( diff --git a/internal/signature/sign.go b/pkg/signature/sign.go similarity index 100% rename from internal/signature/sign.go rename to pkg/signature/sign.go diff --git a/internal/signature/verify.go b/pkg/signature/verify.go similarity index 100% rename from internal/signature/verify.go rename to pkg/signature/verify.go