-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f54e443
commit 3e6de38
Showing
1,489 changed files
with
39,141 additions
and
3,372 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,3 +5,4 @@ node_modules | |
**/node_modules | ||
**/**/node_modules | ||
**/dist | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -70,4 +70,5 @@ Thumbs.db | |
|
||
dist/ | ||
|
||
docker-compose.local.yml | ||
docker-compose.local.yml | ||
|
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
{ | ||
"season": 1, | ||
"from": "2024-01-01", | ||
"to": "2024-03-31", | ||
"shiny": [ | ||
{ | ||
"name": "Shiny", | ||
"iNatId": 1012082, | ||
"image": "1012082.png" | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
CREATE TABLE IF NOT EXISTS "achievements" ( | ||
"id" serial PRIMARY KEY NOT NULL, | ||
"username" text NOT NULL, | ||
"type" text NOT NULL, | ||
"points" integer NOT NULL, | ||
"created_at" timestamp DEFAULT now() NOT NULL, | ||
"revoked" boolean DEFAULT false NOT NULL | ||
); | ||
--> statement-breakpoint | ||
CREATE TABLE IF NOT EXISTS "events" ( | ||
"id" serial PRIMARY KEY NOT NULL, | ||
"username" text NOT NULL, | ||
"type" text NOT NULL, | ||
"created_at" timestamp DEFAULT now() NOT NULL, | ||
"payload" json NOT NULL | ||
); | ||
--> statement-breakpoint | ||
CREATE TABLE IF NOT EXISTS "notifications" ( | ||
"id" serial PRIMARY KEY NOT NULL, | ||
"username" text NOT NULL, | ||
"type" text NOT NULL, | ||
"read" boolean DEFAULT false NOT NULL, | ||
"created_at" timestamp DEFAULT now() NOT NULL, | ||
"payload" json NOT NULL | ||
); | ||
--> statement-breakpoint | ||
ALTER TABLE "roles" RENAME TO "users";--> statement-breakpoint | ||
ALTER TABLE "captures" DROP CONSTRAINT "clip_url_unique_idx";--> statement-breakpoint | ||
ALTER TABLE "identifications" DROP CONSTRAINT "identifications_suggested_by_roles_username_fk"; | ||
--> statement-breakpoint | ||
ALTER TABLE "identifications" DROP CONSTRAINT "identifications_confirmed_by_roles_username_fk"; | ||
--> statement-breakpoint | ||
ALTER TABLE "captures" ADD COLUMN "clip_id" text NOT NULL;--> statement-breakpoint | ||
ALTER TABLE "captures" ADD COLUMN "clip_metadata" json NOT NULL;--> statement-breakpoint | ||
ALTER TABLE "identifications" ADD COLUMN "accessory_for" integer;--> statement-breakpoint | ||
ALTER TABLE "users" ADD COLUMN "points" integer DEFAULT 0 NOT NULL;--> statement-breakpoint | ||
DO $$ BEGIN | ||
ALTER TABLE "achievements" ADD CONSTRAINT "achievements_username_users_username_fk" FOREIGN KEY ("username") REFERENCES "public"."users"("username") ON DELETE no action ON UPDATE no action; | ||
EXCEPTION | ||
WHEN duplicate_object THEN null; | ||
END $$; | ||
--> statement-breakpoint | ||
DO $$ BEGIN | ||
ALTER TABLE "events" ADD CONSTRAINT "events_username_users_username_fk" FOREIGN KEY ("username") REFERENCES "public"."users"("username") ON DELETE no action ON UPDATE no action; | ||
EXCEPTION | ||
WHEN duplicate_object THEN null; | ||
END $$; | ||
--> statement-breakpoint | ||
DO $$ BEGIN | ||
ALTER TABLE "notifications" ADD CONSTRAINT "notifications_username_users_username_fk" FOREIGN KEY ("username") REFERENCES "public"."users"("username") ON DELETE no action ON UPDATE no action; | ||
EXCEPTION | ||
WHEN duplicate_object THEN null; | ||
END $$; | ||
--> statement-breakpoint | ||
CREATE INDEX IF NOT EXISTS "username_achievements_idx" ON "achievements" USING btree ("username");--> statement-breakpoint | ||
CREATE INDEX IF NOT EXISTS "type_achievements_idx" ON "achievements" USING btree ("type");--> statement-breakpoint | ||
CREATE INDEX IF NOT EXISTS "points_achievements_idx" ON "achievements" USING btree ("points");--> statement-breakpoint | ||
CREATE INDEX IF NOT EXISTS "username_events_idx" ON "events" USING btree ("username");--> statement-breakpoint | ||
CREATE INDEX IF NOT EXISTS "type_events_idx" ON "events" USING btree ("type");--> statement-breakpoint | ||
CREATE INDEX IF NOT EXISTS "username_notifications_idx" ON "notifications" USING btree ("username");--> statement-breakpoint | ||
DO $$ BEGIN | ||
ALTER TABLE "identifications" ADD CONSTRAINT "identifications_suggested_by_users_username_fk" FOREIGN KEY ("suggested_by") REFERENCES "public"."users"("username") ON DELETE no action ON UPDATE no action; | ||
EXCEPTION | ||
WHEN duplicate_object THEN null; | ||
END $$; | ||
--> statement-breakpoint | ||
DO $$ BEGIN | ||
ALTER TABLE "identifications" ADD CONSTRAINT "identifications_confirmed_by_users_username_fk" FOREIGN KEY ("confirmed_by") REFERENCES "public"."users"("username") ON DELETE no action ON UPDATE no action; | ||
EXCEPTION | ||
WHEN duplicate_object THEN null; | ||
END $$; | ||
--> statement-breakpoint | ||
CREATE INDEX IF NOT EXISTS "clip_id_idx" ON "captures" USING btree ("clip_id");--> statement-breakpoint | ||
ALTER TABLE "captures" DROP COLUMN IF EXISTS "clip_url";--> statement-breakpoint | ||
ALTER TABLE "captures" ADD CONSTRAINT "captures_clip_id_unique" UNIQUE("clip_id"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
ALTER TYPE "capture_status" ADD VALUE 'draft';--> statement-breakpoint | ||
ALTER TABLE "images" RENAME COLUMN "bounding_boxes" TO "bounding_box";--> statement-breakpoint | ||
ALTER TABLE "images" ALTER COLUMN "bounding_box" DROP DEFAULT;--> statement-breakpoint | ||
ALTER TABLE "observations" ALTER COLUMN "nickname" DROP NOT NULL;--> statement-breakpoint | ||
ALTER TABLE "observations" ADD COLUMN "removed" boolean DEFAULT false NOT NULL;--> statement-breakpoint | ||
ALTER TABLE "observations" ADD COLUMN "moderated" json DEFAULT '[]'::json NOT NULL; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ALTER TABLE "observations" DROP CONSTRAINT "discord_thread_id_unique_idx"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
ALTER TABLE "images" ADD COLUMN "width" integer NOT NULL;--> statement-breakpoint | ||
ALTER TABLE "images" ADD COLUMN "height" integer NOT NULL; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ALTER TABLE "images" RENAME COLUMN "frame" TO "timestamp"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ALTER TABLE "images" ALTER COLUMN "timestamp" SET DATA TYPE numeric; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ALTER TABLE "achievements" ADD COLUMN "redeemed" boolean DEFAULT false NOT NULL; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
ALTER TABLE "achievements" ADD COLUMN "identification_id" integer;--> statement-breakpoint | ||
ALTER TABLE "achievements" ADD COLUMN "observation_id" integer;--> statement-breakpoint | ||
DO $$ BEGIN | ||
ALTER TABLE "achievements" ADD CONSTRAINT "achievements_identification_id_identifications_id_fk" FOREIGN KEY ("identification_id") REFERENCES "public"."identifications"("id") ON DELETE no action ON UPDATE no action; | ||
EXCEPTION | ||
WHEN duplicate_object THEN null; | ||
END $$; | ||
--> statement-breakpoint | ||
DO $$ BEGIN | ||
ALTER TABLE "achievements" ADD CONSTRAINT "achievements_observation_id_observations_id_fk" FOREIGN KEY ("observation_id") REFERENCES "public"."observations"("id") ON DELETE no action ON UPDATE no action; | ||
EXCEPTION | ||
WHEN duplicate_object THEN null; | ||
END $$; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
ALTER TABLE "observations" ADD COLUMN "observed_at" timestamp NOT NULL;--> statement-breakpoint | ||
ALTER TABLE "observations" ADD COLUMN "observed_by" text NOT NULL;--> statement-breakpoint | ||
DO $$ BEGIN | ||
ALTER TABLE "observations" ADD CONSTRAINT "observations_observed_by_users_username_fk" FOREIGN KEY ("observed_by") REFERENCES "public"."users"("username") ON DELETE no action ON UPDATE no action; | ||
EXCEPTION | ||
WHEN duplicate_object THEN null; | ||
END $$; |
Oops, something went wrong.