Browse Source

Rename package to bloat

master
r 2 years ago
parent
commit
e9bd72306e
  1. 2
      .gitignore
  2. 10
      Makefile
  3. 4
      README
  4. 3
      config/config.go
  5. 2
      go.mod
  6. 12
      main.go
  7. 1
      model/notification.go
  8. 1
      model/status.go
  9. 6
      renderer/model.go
  10. 5
      repository/appRepository.go
  11. 5
      repository/sessionRepository.go
  12. 5
      service/auth.go
  13. 3
      service/logging.go
  14. 8
      service/service.go
  15. 3
      service/transport.go
  16. 2
      templates/about.tmpl

2
.gitignore vendored

@ -1,2 +1,2 @@
web
bloat
database

10
Makefile

@ -2,12 +2,12 @@
GO=go
all: web
all: bloat
PHONY:
web: main.go PHONY
$(GO) build $(GOFLAGS) -o web main.go
bloat: main.go PHONY
$(GO) build $(GOFLAGS) -o bloat main.go
run: web
./web
run: bloat
./bloat

4
README

@ -1,4 +1,4 @@
Web - A web client for Mastodon Network[1]
bloat - A web client for Mastodon Network[1]
Features:
@ -28,7 +28,7 @@ Edit the provided config file. See the default.conf file for more details.
$ ed default.conf
Run the binary
$ ./web
$ ./bloat
You can now access the frontend at http://localhost:8080, which is the default
listen address. You can also setup a reverse HTTP proxy to serve the frontend over

3
config/config.go

@ -6,7 +6,8 @@ import (
"io"
"os"
"strings"
"web/model"
"bloat/model"
)
type config struct {

2
go.mod

@ -1,4 +1,4 @@
module web
module bloat
go 1.13

12
main.go

@ -9,12 +9,12 @@ import (
"strings"
"time"
"web/config"
"web/kv"
"web/renderer"
"web/repository"
"web/service"
"web/util"
"bloat/config"
"bloat/kv"
"bloat/renderer"
"bloat/repository"
"bloat/service"
"bloat/util"
)
var (

1
model/notification.go

@ -1 +0,0 @@
package model

1
model/status.go

@ -1 +0,0 @@
package model

6
renderer/model.go

@ -1,8 +1,8 @@
package renderer
import (
"bloat/model"
"mastodon"
"web/model"
)
type HeaderData struct {
@ -92,14 +92,14 @@ type RetweetedByData struct {
type FollowingData struct {
*CommonData
Users []*mastodon.Account
Users []*mastodon.Account
HasNext bool
NextLink string
}
type FollowersData struct {
*CommonData
Users []*mastodon.Account
Users []*mastodon.Account
HasNext bool
NextLink string
}

5
repository/appRepository.go

@ -2,8 +2,9 @@ package repository
import (
"encoding/json"
"web/kv"
"web/model"
"bloat/kv"
"bloat/model"
)
type appRepository struct {

5
repository/sessionRepository.go

@ -2,8 +2,9 @@ package repository
import (
"encoding/json"
"web/kv"
"web/model"
"bloat/kv"
"bloat/model"
)
type sessionRepository struct {

5
service/auth.go

@ -4,9 +4,10 @@ import (
"context"
"errors"
"io"
"mastodon"
"mime/multipart"
"web/model"
"bloat/model"
"mastodon"
)
var (

3
service/logging.go

@ -6,7 +6,8 @@ import (
"log"
"mime/multipart"
"time"
"web/model"
"bloat/model"
)
type loggingService struct {

8
service/service.go

@ -12,10 +12,10 @@ import (
"net/url"
"strings"
"bloat/model"
"bloat/renderer"
"bloat/util"
"mastodon"
"web/model"
"web/renderer"
"web/util"
)
var (
@ -93,7 +93,7 @@ func (svc *service) GetAuthUrl(ctx context.Context, instance string) (
session := model.Session{
ID: sessionID,
InstanceDomain: instance,
Settings: *model.NewSettings(),
Settings: *model.NewSettings(),
}
err = svc.sessionRepo.Add(session)
if err != nil {

3
service/transport.go

@ -7,7 +7,8 @@ import (
"path"
"strconv"
"time"
"web/model"
"bloat/model"
"github.com/gorilla/mux"
)

2
templates/about.tmpl

@ -10,7 +10,7 @@
The source code is released under
<a href="https://creativecommons.org/share-your-work/public-domain/cc0" target="_blank">CC0</a>
and is available on
<a href="https://git.freesoftwareextremist.com/web" target="_blank">git.freesoftwareextremist.com/web</a>.
<a href="https://git.freesoftwareextremist.com/bloat" target="_blank">git.freesoftwareextremist.com/bloat</a>.
</P>
</div>

Loading…
Cancel
Save