Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unstable #1

Merged
merged 4 commits into from
Nov 12, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Deploy to GitHub Packages

on:
push:
branches:
- unstable

jobs:
deploy:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Set up JDK
uses: actions/setup-java@v2
with:
distribution: 'adopt'
java-version: '17'

- name: Build and deploy to GitHub Packages
run: |
mvn -B deploy --file pom.xml \
-Dmaven.repo.local=$HOME/.m2/repository \
-DaltDeploymentRepository=github::default::https://maven.pkg.github.com/Strafbefehl/Vinyl-Core

env:
GITHUB_TOKEN: ${{ secrets.TOKEN }}
4 changes: 2 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
<modelVersion>4.0.0</modelVersion>

<groupId>rystudio.strafbefehl.vinyl</groupId>
<artifactId>core</artifactId>
<version>1.0.39-RELEASE</version>
<artifactId>coreunstable</artifactId>
<version>1.0.40-UNSTABLE-R6</version>
<packaging>jar</packaging>
<name>Vinyl-Core</name>

Expand Down
5 changes: 3 additions & 2 deletions src/main/java/rystudio/strafbefehl/vinyl/Core.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import net.dv8tion.jda.api.interactions.commands.build.CommandData;
import net.dv8tion.jda.api.interactions.commands.build.Commands;
import net.dv8tion.jda.api.requests.GatewayIntent;
import net.dv8tion.jda.api.sharding.DefaultShardManager;
import net.dv8tion.jda.api.sharding.DefaultShardManagerBuilder;
import net.dv8tion.jda.api.sharding.ShardManager;
import net.dv8tion.jda.api.utils.cache.CacheFlag;
Expand Down Expand Up @@ -44,7 +45,7 @@ public class Core extends ListenerAdapter {

public JDA jda;
private boolean running;
private ShardManager shardManager;
private DefaultShardManager shardManager;

private DefaultShardManagerBuilder builder;

Expand Down Expand Up @@ -433,7 +434,7 @@ public Core registerListeners(ListenerAdapter... listeners) {
return this;
} else {
if (this.shardManager == null) {
this.shardManager = DefaultShardManagerBuilder.createDefault(this.config.getToken()).build();
this.shardManager = (DefaultShardManager) DefaultShardManagerBuilder.createDefault(this.config.getToken()).build();
// Configure any other settings for the shardManager if needed
}

Expand Down
Loading