Skip to content

Commit 4ad683b

Browse files
authored
Add Workflows (#17)
* Create pullrequest.yml * Create build.yml * fix the import lmao * fine, have your content write permission
1 parent 3ee017a commit 4ad683b

File tree

3 files changed

+88
-1
lines changed

3 files changed

+88
-1
lines changed

.github/workflows/build.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: "Build"
2+
3+
on:
4+
push:
5+
branches: [ "master" ]
6+
7+
jobs:
8+
build:
9+
name: Build
10+
runs-on: ubuntu-latest
11+
permissions:
12+
actions: read
13+
contents: read
14+
security-events: write
15+
16+
strategy:
17+
fail-fast: false
18+
matrix:
19+
language: [ 'java' ]
20+
21+
steps:
22+
- name: Checkout repository
23+
uses: actions/checkout@v3
24+
25+
- name: Initialize CodeQL
26+
uses: github/codeql-action/init@v2
27+
with:
28+
languages: ${{ matrix.language }}
29+
30+
- name: Setup Java and Maven
31+
uses: actions/setup-java@v3
32+
with:
33+
java-version: '17'
34+
distribution: 'temurin'
35+
cache: maven
36+
37+
- name: Build with Maven
38+
run: mvn -B package --file pom.xml
39+
40+
- name: Perform CodeQL Analysis
41+
uses: github/codeql-action/analyze@v2

.github/workflows/pullrequest.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: "Build Pull Request"
2+
3+
on:
4+
pull_request:
5+
# The branches below must be a subset of the branches above
6+
branches: [ "master" ]
7+
8+
jobs:
9+
build:
10+
name: Build
11+
runs-on: ubuntu-latest
12+
permissions:
13+
actions: read
14+
contents: write
15+
security-events: write
16+
17+
strategy:
18+
fail-fast: false
19+
matrix:
20+
language: [ 'java' ]
21+
22+
steps:
23+
- name: Checkout repository
24+
uses: actions/checkout@v3
25+
26+
- name: Initialize CodeQL
27+
uses: github/codeql-action/init@v2
28+
with:
29+
languages: ${{ matrix.language }}
30+
31+
- name: Setup Java and Maven
32+
uses: actions/setup-java@v3
33+
with:
34+
java-version: '17'
35+
distribution: 'temurin'
36+
cache: maven
37+
38+
- name: Build with Maven
39+
run: mvn -B package --file pom.xml
40+
41+
- name: Perform CodeQL Analysis
42+
uses: github/codeql-action/analyze@v2
43+
44+
45+
- name: Update dependency graph
46+
uses: advanced-security/maven-dependency-submission-action@571e99aab1055c2e71a1e2309b9691de18d6b7d6

src/main/java/com/cssbham/minecraftcore/discord/DiscordBridge.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
import net.dv8tion.jda.api.JDABuilder;
1010
import net.dv8tion.jda.api.entities.Guild;
1111
import net.dv8tion.jda.api.entities.Member;
12-
import net.dv8tion.jda.api.events.message.guild.GuildMessageReceivedEvent;
12+
import net.dv8tion.jda.api.events.message.MessageReceivedEvent;
1313
import net.dv8tion.jda.api.hooks.ListenerAdapter;
1414
import net.dv8tion.jda.api.requests.GatewayIntent;
1515
import net.dv8tion.jda.api.utils.ChunkingFilter;

0 commit comments

Comments
 (0)