Skip to content

Commit 4f823b4

Browse files
committed
chore: big yolo treewide change, let's break stuff
Signed-off-by: Xe Iaso <[email protected]>
1 parent dfb5de4 commit 4f823b4

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

50 files changed

+61
-12837
lines changed

cmd/hdrwtch/static/css/styles.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/*! tailwindcss v4.1.3 | MIT License | https://tailwindcss.com */
1+
/*! tailwindcss v4.1.8 | MIT License | https://tailwindcss.com */
22
@import url("https://cdn.xeiaso.net/static/pkg/iosevka/family.css");
33
@import url("https://cdn.xeiaso.net/static/pkg/podkova/family.css");
44
@layer properties;

cmd/mi/main.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,9 @@ import (
2121
"within.website/x/cmd/mi/services/posse"
2222
"within.website/x/cmd/mi/services/switchtracker"
2323
"within.website/x/cmd/mi/services/twitchevents"
24+
pb "within.website/x/gen/within/website/x/mi/v1"
25+
announcev1 "within.website/x/gen/within/website/x/mimi/announce/v1"
2426
"within.website/x/internal"
25-
pb "within.website/x/proto/mi"
26-
"within.website/x/proto/mimi/announce"
2727
)
2828

2929
var (
@@ -104,11 +104,11 @@ func main() {
104104

105105
gs := grpc.NewServer()
106106

107-
announce.RegisterAnnounceServer(gs, ann)
107+
announcev1.RegisterAnnounceServer(gs, ann)
108108
pb.RegisterSwitchTrackerServer(gs, st)
109109
pb.RegisterEventsServer(gs, es)
110110

111-
mux.Handle(announce.AnnouncePathPrefix, announce.NewAnnounceServer(ann))
111+
mux.Handle(announcev1.AnnouncePathPrefix, announcev1.NewAnnounceServer(ann))
112112
mux.Handle(pb.SwitchTrackerPathPrefix, pb.NewSwitchTrackerServer(st))
113113
mux.Handle(pb.EventsPathPrefix, pb.NewEventsServer(es))
114114
mux.Handle("/front", homefrontshim.New(dao))

cmd/mi/models/blogpost.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import (
55
"time"
66

77
"gorm.io/gorm"
8-
"within.website/x/proto/external/jsonfeed"
8+
jsonfeedv1 "within.website/x/gen/within/website/x/external/jsonfeed/v1"
99
)
1010

1111
// Blogpost is a single blogpost from a JSON Feed.
@@ -30,7 +30,7 @@ func (d *DAO) HasBlogpost(ctx context.Context, postURL string) (bool, error) {
3030
return count > 0, nil
3131
}
3232

33-
func (d *DAO) InsertBlogpost(ctx context.Context, post *jsonfeed.Item) (*Blogpost, error) {
33+
func (d *DAO) InsertBlogpost(ctx context.Context, post *jsonfeedv1.Item) (*Blogpost, error) {
3434
bp := &Blogpost{
3535
ID: post.GetId(),
3636
URL: post.GetUrl(),

cmd/mi/models/events.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import (
66

77
"google.golang.org/protobuf/types/known/timestamppb"
88
"gorm.io/gorm"
9-
pb "within.website/x/proto/mi"
9+
pb "within.website/x/gen/within/website/x/mi/v1"
1010
)
1111

1212
// Event represents an event that members of DevRel will be attending.
@@ -19,7 +19,6 @@ type Event struct {
1919
EndDate time.Time
2020
Location string `gorm:"index"`
2121
Description string
22-
Syndicate bool
2322
}
2423

2524
func (e *Event) AsProto() *pb.Event {
@@ -31,7 +30,6 @@ func (e *Event) AsProto() *pb.Event {
3130
EndDate: timestamppb.New(e.EndDate),
3231
Location: e.Location,
3332
Description: e.Description,
34-
Syndicate: e.Syndicate,
3533
}
3634
}
3735

cmd/mi/models/member.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package models
22

33
import (
4-
pb "within.website/x/proto/mi"
4+
pb "within.website/x/gen/within/website/x/mi/v1"
55
)
66

77
// Member is a member of the Within system.

cmd/mi/models/switch.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import (
44
"time"
55

66
"gorm.io/gorm"
7-
pb "within.website/x/proto/mi"
7+
pb "within.website/x/gen/within/website/x/mi/v1"
88
)
99

1010
// Switch is a record of the system switching front to a different member.

cmd/mi/services/events/events.go

Lines changed: 2 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,11 @@ import (
1010
"google.golang.org/protobuf/types/known/emptypb"
1111
"gorm.io/gorm"
1212
"within.website/x/cmd/mi/models"
13-
"within.website/x/cmd/mi/services/events/flyghttracker"
14-
pb "within.website/x/proto/mi"
13+
pb "within.website/x/gen/within/website/x/mi/v1"
1514
)
1615

1716
type Events struct {
18-
dao *models.DAO
19-
flyghtTracker *flyghttracker.Client
17+
dao *models.DAO
2018

2119
pb.UnimplementedEventsServer
2220
}
@@ -29,12 +27,6 @@ func New(dao *models.DAO, flyghtTrackerURL string) *Events {
2927
dao: dao,
3028
}
3129

32-
if flyghtTrackerURL != "" {
33-
result.flyghtTracker = flyghttracker.New(flyghtTrackerURL)
34-
} else {
35-
slog.Warn("no flyght tracker database URL provided, not syndicating events to flyght tracker")
36-
}
37-
3830
return result
3931
}
4032

@@ -72,7 +64,6 @@ func (e *Events) Add(ctx context.Context, ev *pb.Event) (*emptypb.Empty, error)
7264
EndDate: ev.EndDate.AsTime(),
7365
Location: ev.Location,
7466
Description: ev.Description,
75-
Syndicate: ev.Syndicate,
7667
}
7768

7869
_, err := e.dao.CreateEvent(ctx, event)
@@ -82,12 +73,6 @@ func (e *Events) Add(ctx context.Context, ev *pb.Event) (*emptypb.Empty, error)
8273

8374
slog.Info("tracking new event", "event", event)
8475

85-
if e.flyghtTracker != nil {
86-
if err := e.syndicateToFlyghtTracker(ctx, ev); err != nil {
87-
slog.Error("can't syndicate event to flyght tracker", "err", err)
88-
}
89-
}
90-
9176
return &emptypb.Empty{}, nil
9277
}
9378

cmd/mi/services/events/flyghttracker.go

Lines changed: 0 additions & 38 deletions
This file was deleted.

cmd/mi/services/events/flyghttracker/flyghttracker.go

Lines changed: 0 additions & 154 deletions
This file was deleted.

cmd/mi/services/importer/importer.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import (
1010

1111
"gorm.io/gorm"
1212
"within.website/x/cmd/mi/models"
13-
pb "within.website/x/proto/mi"
13+
pb "within.website/x/gen/within/website/x/mi/v1"
1414
)
1515

1616
const timeLayout = "2006-01-02 15:04:05"

0 commit comments

Comments
 (0)