change name to go-ssb-room

It has been brought to my attention that "gossb" reads like "gossip..?"
to the untrained eye. That's just confusing.

Also the project hosts a single room so the plural was just wrong.
This commit is contained in:
Henry 2021-02-09 17:38:51 +01:00
parent 9d7584d87b
commit fec92d428c
45 changed files with 78 additions and 92 deletions

View File

@ -1,14 +0,0 @@
image: alpine/latest
packages:
- go
- nodejs
- npm
sources:
- https://git.sr.ht/~cryptix/go-ssb-rooms
tasks:
- test: |
cd go-ssb-rooms
go build -i ./...
cd test/nodejs && npm i && cd ../..
go test ./...
go test -race -failfast -count 25 ./test/go

View File

@ -1,4 +1,4 @@
# Go-SSB Rooms
# Go-SSB Room
This repository contains code for a [Secure-Scuttlebutt Room v2](github.com/ssb-ngi-pointer/rooms2/) server writen in Go.

View File

@ -4,7 +4,7 @@ package mockdb
import (
"sync"
"github.com/ssb-ngi-pointer/gossb-rooms/admindb"
"github.com/ssb-ngi-pointer/go-ssb-room/admindb"
)
type FakeAliasService struct {

View File

@ -4,7 +4,7 @@ package mockdb
import (
"sync"
"github.com/ssb-ngi-pointer/gossb-rooms/admindb"
"github.com/ssb-ngi-pointer/go-ssb-room/admindb"
)
type FakeAuthWithSSBService struct {

View File

@ -5,7 +5,7 @@ import (
"context"
"sync"
"github.com/ssb-ngi-pointer/gossb-rooms/admindb"
"github.com/ssb-ngi-pointer/go-ssb-room/admindb"
)
type FakeAuthFallbackService struct {

View File

@ -4,7 +4,7 @@ package mockdb
import (
"sync"
"github.com/ssb-ngi-pointer/gossb-rooms/admindb"
"github.com/ssb-ngi-pointer/go-ssb-room/admindb"
)
type FakeRoomService struct {

View File

@ -5,7 +5,7 @@ package sqlite
import (
"database/sql"
"github.com/ssb-ngi-pointer/gossb-rooms/admindb"
"github.com/ssb-ngi-pointer/go-ssb-room/admindb"
)
// make sure to implement interfaces correctly

View File

@ -11,10 +11,10 @@ import (
"golang.org/x/crypto/bcrypt"
"github.com/ssb-ngi-pointer/gossb-rooms/admindb/sqlite/models"
"github.com/ssb-ngi-pointer/go-ssb-room/admindb/sqlite/models"
"github.com/volatiletech/sqlboiler/v4/queries/qm"
"github.com/ssb-ngi-pointer/gossb-rooms/admindb"
"github.com/ssb-ngi-pointer/go-ssb-room/admindb"
)
// make sure to implement interfaces correctly

View File

@ -5,7 +5,7 @@ package sqlite
import (
"database/sql"
"github.com/ssb-ngi-pointer/gossb-rooms/admindb"
"github.com/ssb-ngi-pointer/go-ssb-room/admindb"
)
// make sure to implement interfaces correctly

View File

@ -18,6 +18,6 @@ import (
)
// absolute path of where this package is located
var pkgDir = goutils.MustLocatePackage("github.com/ssb-ngi-pointer/gossb-rooms/admindb/sqlite")
var pkgDir = goutils.MustLocatePackage("github.com/ssb-ngi-pointer/go-ssb-room/admindb/sqlite")
var Migrations http.FileSystem = http.Dir(filepath.Join(pkgDir, "migrations"))

View File

@ -9,7 +9,7 @@ import (
"github.com/shurcooL/vfsgen"
"github.com/ssb-ngi-pointer/gossb-rooms/admindb/sqlite"
"github.com/ssb-ngi-pointer/go-ssb-room/admindb/sqlite"
)
func main() {

View File

@ -11,8 +11,8 @@ import (
migrate "github.com/rubenv/sql-migrate"
"github.com/ssb-ngi-pointer/gossb-rooms/admindb"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/repo"
"github.com/ssb-ngi-pointer/go-ssb-room/admindb"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/repo"
)
type Database struct {

View File

@ -7,7 +7,7 @@ import (
"testing"
_ "github.com/mattn/go-sqlite3"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/repo"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/repo"
"github.com/stretchr/testify/require"
)

View File

@ -5,7 +5,7 @@ package sqlite
import (
"database/sql"
"github.com/ssb-ngi-pointer/gossb-rooms/admindb"
"github.com/ssb-ngi-pointer/go-ssb-room/admindb"
)
// make sure to implement interfaces correctly

View File

@ -9,12 +9,12 @@ import (
"os"
"syscall"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/repo"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/repo"
_ "github.com/mattn/go-sqlite3"
"golang.org/x/crypto/ssh/terminal"
"github.com/ssb-ngi-pointer/gossb-rooms/admindb/sqlite"
"github.com/ssb-ngi-pointer/go-ssb-room/admindb/sqlite"
)
func main() {

View File

@ -28,11 +28,11 @@ import (
_ "github.com/mattn/go-sqlite3"
"go.cryptoscope.co/muxrpc/v2/debug"
"github.com/ssb-ngi-pointer/gossb-rooms/admindb/sqlite"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/repo"
"github.com/ssb-ngi-pointer/gossb-rooms/roomsrv"
mksrv "github.com/ssb-ngi-pointer/gossb-rooms/roomsrv"
"github.com/ssb-ngi-pointer/gossb-rooms/web/handlers"
"github.com/ssb-ngi-pointer/go-ssb-room/admindb/sqlite"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/repo"
"github.com/ssb-ngi-pointer/go-ssb-room/roomsrv"
mksrv "github.com/ssb-ngi-pointer/go-ssb-room/roomsrv"
"github.com/ssb-ngi-pointer/go-ssb-room/web/handlers"
)
var (

2
go.mod
View File

@ -1,4 +1,4 @@
module github.com/ssb-ngi-pointer/gossb-rooms
module github.com/ssb-ngi-pointer/go-ssb-room
go 1.15

View File

@ -11,8 +11,8 @@ import (
"go.cryptoscope.co/muxrpc/v2/typemux"
refs "go.mindeco.de/ssb-refs"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/broadcasts"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/maybemuxrpc"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/broadcasts"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/maybemuxrpc"
)
const name = "tunnel"

View File

@ -9,12 +9,12 @@ import (
"time"
refs "go.mindeco.de/ssb-refs"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/network"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/network"
kitlog "github.com/go-kit/kit/log"
"github.com/go-kit/kit/log/level"
"go.cryptoscope.co/muxrpc/v2"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/broadcasts"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/broadcasts"
)
type roomState struct {

View File

@ -12,7 +12,7 @@ import (
"go.cryptoscope.co/muxrpc/v2"
refs "go.mindeco.de/ssb-refs"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/maybemuxrpc"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/maybemuxrpc"
)
var (

View File

@ -6,7 +6,7 @@ import (
"io"
"sync"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/maybemod/multierror"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/maybemod/multierror"
)
type RoomChangeSink interface {

View File

@ -7,7 +7,7 @@ import (
"io"
"sync"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/maybemod/multierror"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/maybemod/multierror"
)
type Closer struct {

View File

@ -10,8 +10,8 @@ import (
"testing"
"github.com/go-kit/kit/log"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/maybemod/keys"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/network"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/maybemod/keys"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/network"
"go.cryptoscope.co/muxrpc/v2"

View File

@ -19,7 +19,7 @@ import (
"go.cryptoscope.co/secretstream"
refs "go.mindeco.de/ssb-refs"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/maybemod/keys"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/maybemod/keys"
)
// DefaultPort is the default listening port for ScuttleButt.

View File

@ -7,8 +7,8 @@ import (
"testing"
"github.com/stretchr/testify/require"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/maybemod/keys"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/network"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/maybemod/keys"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/network"
)
func TestSpoof(t *testing.T) {

View File

@ -10,7 +10,7 @@ import (
"path/filepath"
refs "go.mindeco.de/ssb-refs"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/maybemod/keys"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/maybemod/keys"
)
func DefaultKeyPair(r Interface) (*keys.KeyPair, error) {

View File

@ -15,10 +15,10 @@ import (
"go.cryptoscope.co/muxrpc/v2"
refs "go.mindeco.de/ssb-refs"
"github.com/ssb-ngi-pointer/gossb-rooms/handlers/tunnel/server"
"github.com/ssb-ngi-pointer/gossb-rooms/handlers/whoami"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/maybemuxrpc"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/network"
"github.com/ssb-ngi-pointer/go-ssb-room/handlers/tunnel/server"
"github.com/ssb-ngi-pointer/go-ssb-room/handlers/whoami"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/maybemuxrpc"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/network"
)
func (s *Server) initNetwork() error {

View File

@ -12,8 +12,8 @@ import (
"github.com/go-kit/kit/log/level"
"go.cryptoscope.co/muxrpc/v2"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/netwraputil"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/repo"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/netwraputil"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/repo"
)
// WithUNIXSocket enables listening for muxrpc connections on a unix socket files ($repo/socket).

View File

@ -10,9 +10,9 @@ import (
kitlog "github.com/go-kit/kit/log"
"go.cryptoscope.co/netwrap"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/maybemod/keys"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/network"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/repo"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/maybemod/keys"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/network"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/repo"
)
type Option func(srv *Server) error

View File

@ -17,11 +17,11 @@ import (
"go.cryptoscope.co/netwrap"
refs "go.mindeco.de/ssb-refs"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/maybemod/keys"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/maybemod/multicloser"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/maybemuxrpc"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/network"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/repo"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/maybemod/keys"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/maybemod/multicloser"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/maybemuxrpc"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/network"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/repo"
)
type Server struct {

View File

@ -15,7 +15,7 @@ import (
"golang.org/x/sync/errgroup"
refs "go.mindeco.de/ssb-refs"
"github.com/ssb-ngi-pointer/gossb-rooms/roomsrv"
"github.com/ssb-ngi-pointer/go-ssb-room/roomsrv"
)
func createServerAndBots(t *testing.T, ctx context.Context, count uint) []*roomsrv.Server {

View File

@ -17,9 +17,9 @@ import (
"github.com/stretchr/testify/require"
"go.cryptoscope.co/muxrpc/v2/debug"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/maybemod/testutils"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/network"
"github.com/ssb-ngi-pointer/gossb-rooms/roomsrv"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/maybemod/testutils"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/network"
"github.com/ssb-ngi-pointer/go-ssb-room/roomsrv"
)
var (

View File

@ -26,8 +26,8 @@ import (
"go.cryptoscope.co/netwrap"
refs "go.mindeco.de/ssb-refs"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/maybemod/testutils"
"github.com/ssb-ngi-pointer/gossb-rooms/roomsrv"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/maybemod/testutils"
"github.com/ssb-ngi-pointer/go-ssb-room/roomsrv"
)
func init() {

View File

@ -20,7 +20,7 @@ import (
const Production = false
// absolute path of where this package is located
var pkgDir = goutils.MustLocatePackage("github.com/ssb-ngi-pointer/gossb-rooms/web")
var pkgDir = goutils.MustLocatePackage("github.com/ssb-ngi-pointer/go-ssb-room/web")
var Templates http.FileSystem = http.Dir(filepath.Join(pkgDir, "templates"))

View File

@ -10,7 +10,7 @@ import (
"github.com/shurcooL/vfsgen"
"github.com/ssb-ngi-pointer/gossb-rooms/web"
"github.com/ssb-ngi-pointer/go-ssb-room/web"
)
func main() {

View File

@ -8,7 +8,7 @@ import (
"github.com/gorilla/mux"
"go.mindeco.de/http/render"
"github.com/ssb-ngi-pointer/gossb-rooms/web/router"
"github.com/ssb-ngi-pointer/go-ssb-room/web/router"
)
var HTMLTemplates = []string{

View File

@ -9,7 +9,7 @@ import (
"go.mindeco.de/http/auth"
"go.mindeco.de/http/render"
"github.com/ssb-ngi-pointer/gossb-rooms/web/router"
"github.com/ssb-ngi-pointer/go-ssb-room/web/router"
)
var HTMLTemplates = []string{

View File

@ -12,14 +12,14 @@ import (
"go.mindeco.de/http/auth"
"go.mindeco.de/http/render"
"github.com/ssb-ngi-pointer/gossb-rooms/admindb"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/repo"
"github.com/ssb-ngi-pointer/gossb-rooms/web"
"github.com/ssb-ngi-pointer/gossb-rooms/web/handlers/admin"
roomsAuth "github.com/ssb-ngi-pointer/gossb-rooms/web/handlers/auth"
"github.com/ssb-ngi-pointer/gossb-rooms/web/handlers/news"
"github.com/ssb-ngi-pointer/gossb-rooms/web/i18n"
"github.com/ssb-ngi-pointer/gossb-rooms/web/router"
"github.com/ssb-ngi-pointer/go-ssb-room/admindb"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/repo"
"github.com/ssb-ngi-pointer/go-ssb-room/web"
"github.com/ssb-ngi-pointer/go-ssb-room/web/handlers/admin"
roomsAuth "github.com/ssb-ngi-pointer/go-ssb-room/web/handlers/auth"
"github.com/ssb-ngi-pointer/go-ssb-room/web/handlers/news"
"github.com/ssb-ngi-pointer/go-ssb-room/web/i18n"
"github.com/ssb-ngi-pointer/go-ssb-room/web/router"
)
// New initializes the whole web stack for rooms, with all the sub-modules and routing.

View File

@ -9,7 +9,7 @@ import (
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
"github.com/ssb-ngi-pointer/gossb-rooms/web/router"
"github.com/ssb-ngi-pointer/go-ssb-room/web/router"
)
func TestIndex(t *testing.T) {

View File

@ -6,7 +6,7 @@ import (
"net/http"
"github.com/gorilla/mux"
"github.com/ssb-ngi-pointer/gossb-rooms/web/router"
"github.com/ssb-ngi-pointer/go-ssb-room/web/router"
"go.mindeco.de/http/render"
)

View File

@ -11,8 +11,8 @@ import (
"go.mindeco.de/http/tester"
"go.mindeco.de/logging/logtest"
"github.com/ssb-ngi-pointer/gossb-rooms/web"
"github.com/ssb-ngi-pointer/gossb-rooms/web/router"
"github.com/ssb-ngi-pointer/go-ssb-room/web"
"github.com/ssb-ngi-pointer/go-ssb-room/web/router"
)
var (

View File

@ -8,7 +8,7 @@ import (
"github.com/stretchr/testify/assert"
"github.com/ssb-ngi-pointer/gossb-rooms/web/router"
"github.com/ssb-ngi-pointer/go-ssb-room/web/router"
)
func TestOverview(t *testing.T) {

View File

@ -11,9 +11,9 @@ import (
"github.com/pkg/errors"
"go.mindeco.de/http/tester"
"github.com/ssb-ngi-pointer/gossb-rooms/admindb/mockdb"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/repo"
"github.com/ssb-ngi-pointer/gossb-rooms/web/router"
"github.com/ssb-ngi-pointer/go-ssb-room/admindb/mockdb"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/repo"
"github.com/ssb-ngi-pointer/go-ssb-room/web/router"
)
var (

View File

@ -11,7 +11,7 @@ import (
"github.com/BurntSushi/toml"
"github.com/nicksnyder/go-i18n/v2/i18n"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/repo"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/repo"
"golang.org/x/text/language"
)

View File

@ -16,7 +16,7 @@ import (
"github.com/go-kit/kit/log/level"
"github.com/gorilla/mux"
"github.com/ssb-ngi-pointer/gossb-rooms/internal/repo"
"github.com/ssb-ngi-pointer/go-ssb-room/internal/repo"
"go.mindeco.de/logging"
)