Skip to content

Commit 86168f0

Browse files
committed
init
0 parents  commit 86168f0

File tree

20 files changed

+823
-0
lines changed

20 files changed

+823
-0
lines changed

.gitignore

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
.gradle
2+
.idea
3+
build/
4+
!gradle/wrapper/gradle-wrapper.jar
5+
!**/src/main/**/build/
6+
!**/src/test/**/build/
7+
8+
### IntelliJ IDEA ###
9+
.idea/modules.xml
10+
.idea/jarRepositories.xml
11+
.idea/compiler.xml
12+
.idea/libraries/
13+
*.iws
14+
*.iml
15+
*.ipr
16+
out/
17+
!**/src/main/**/out/
18+
!**/src/test/**/out/
19+
20+
### Eclipse ###
21+
.apt_generated
22+
.classpath
23+
.factorypath
24+
.project
25+
.settings
26+
.springBeans
27+
.sts4-cache
28+
bin/
29+
!**/src/main/**/bin/
30+
!**/src/test/**/bin/
31+
32+
### NetBeans ###
33+
/nbproject/private/
34+
/nbbuild/
35+
/dist/
36+
/nbdist/
37+
/.nb-gradle/
38+
39+
### VS Code ###
40+
.vscode/
41+
42+
### Mac OS ###
43+
.DS_Store

build.gradle

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
plugins {
2+
id("java")
3+
}
4+
5+
group = "dev.discordnet.gatekeeper"
6+
version = "1.0-SNAPSHOT"
7+
8+
repositories {
9+
mavenCentral()
10+
maven { url 'https://oss.sonatype.org/content/repositories/snapshots' }
11+
maven { url 'https://hub.spigotmc.org/nexus/content/repositories/snapshots/' }
12+
maven { url 'https://s01.oss.sonatype.org/content/repositories/snapshots/' }
13+
}
14+
15+
dependencies {
16+
testImplementation platform("org.junit:junit-bom:5.9.1")
17+
testImplementation "org.junit.jupiter:junit-jupiter"
18+
19+
compileOnly 'org.spigotmc:spigot-api:1.20.2-R0.1-SNAPSHOT'
20+
implementation 'com.edgedb:driver:0.2.3-SNAPSHOT'
21+
implementation 'net.dv8tion:JDA:5.0.0-beta.15'
22+
}
23+
24+
25+
tasks.test {
26+
useJUnitPlatform()
27+
}
28+
29+
jar {
30+
duplicatesStrategy = DuplicatesStrategy.EXCLUDE
31+
32+
manifest {
33+
attributes "Main-Class": "dev.discordnet.gatekeeper.GateKeeper"
34+
}
35+
36+
from {
37+
configurations.runtimeClasspath.collect { it.isDirectory() ? it : zipTree(it) }
38+
}
39+
}

dbschema/default.esdl

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
module default {
2+
type Player {
3+
required minecraft_id: uuid {
4+
constraint exclusive;
5+
}
6+
7+
discord_id: str {
8+
constraint exclusive;
9+
}
10+
11+
verified: bool {
12+
default := false;
13+
}
14+
15+
index on (.minecraft_id)
16+
}
17+
18+
type VerifyCode {
19+
link player: Player {
20+
constraint exclusive;
21+
}
22+
code: str;
23+
created_at: datetime {
24+
default := datetime_current();
25+
}
26+
}
27+
}

dbschema/migrations/00001.edgeql

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
CREATE MIGRATION m1gbjcextns54tq4w4dizaarwuaoeg2gqgr6dr5pl3ogzzjdlmuora
2+
ONTO initial
3+
{
4+
CREATE TYPE default::Player {
5+
CREATE PROPERTY minecraft_id: std::uuid;
6+
CREATE INDEX ON (.minecraft_id);
7+
CREATE PROPERTY discord_id: std::str;
8+
CREATE PROPERTY verified: std::bool;
9+
};
10+
CREATE TYPE default::VerifyCode {
11+
CREATE LINK player: default::Player;
12+
CREATE PROPERTY code: std::str;
13+
};
14+
};

dbschema/migrations/00002.edgeql

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
CREATE MIGRATION m1nv3qgmctomgf7gb6kgwglyd4wwree4nkyiw442qwvr4ukuqk3lpa
2+
ONTO m1gbjcextns54tq4w4dizaarwuaoeg2gqgr6dr5pl3ogzzjdlmuora
3+
{
4+
ALTER TYPE default::Player {
5+
ALTER PROPERTY discord_id {
6+
CREATE CONSTRAINT std::exclusive;
7+
};
8+
ALTER PROPERTY minecraft_id {
9+
CREATE CONSTRAINT std::exclusive;
10+
};
11+
};
12+
ALTER TYPE default::VerifyCode {
13+
ALTER LINK player {
14+
CREATE CONSTRAINT std::exclusive;
15+
};
16+
};
17+
};

dbschema/migrations/00003.edgeql

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
CREATE MIGRATION m14uyw5vofnitbxvgcvgpiycou56bw4iguhtva4pfntx6kx5us6l2q
2+
ONTO m1nv3qgmctomgf7gb6kgwglyd4wwree4nkyiw442qwvr4ukuqk3lpa
3+
{
4+
ALTER TYPE default::Player {
5+
ALTER PROPERTY minecraft_id {
6+
SET REQUIRED USING (<std::uuid>{});
7+
};
8+
};
9+
};

dbschema/migrations/00004.edgeql

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
CREATE MIGRATION m1de64fyb7ycfc75qigq4ulg6rwguucykzmogyd2dko5asfunr4cba
2+
ONTO m14uyw5vofnitbxvgcvgpiycou56bw4iguhtva4pfntx6kx5us6l2q
3+
{
4+
ALTER TYPE default::Player {
5+
ALTER PROPERTY verified {
6+
SET default := false;
7+
};
8+
};
9+
ALTER TYPE default::VerifyCode {
10+
CREATE PROPERTY created_at: std::datetime {
11+
SET default := (std::datetime_current());
12+
};
13+
};
14+
};

edgedb.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[edgedb]
2+
server-version = "3.4"

gradle/wrapper/gradle-wrapper.jar

59.3 KB
Binary file not shown.
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
#Sat Oct 14 14:00:25 ADT 2023
2+
distributionBase=GRADLE_USER_HOME
3+
distributionPath=wrapper/dists
4+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.2-bin.zip
5+
zipStoreBase=GRADLE_USER_HOME
6+
zipStorePath=wrapper/dists

0 commit comments

Comments
 (0)