This repository has been archived by the owner on Apr 21, 2024. It is now read-only.
-
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.
release: 1.0.0-alpha.1 (Merge pull request #5 from erha134/main)
chore(Workflows): 更新 Workflows
- Loading branch information
Showing
48 changed files
with
819 additions
and
164 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 |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: PR Check | ||
|
||
on: | ||
pull_request: | ||
|
||
jobs: | ||
test: | ||
permissions: | ||
contents: write | ||
discussions: write | ||
|
||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
submodules: true | ||
|
||
- name: Setup jdk 17 | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: 'zulu' | ||
java-version: '17' | ||
|
||
- uses: gradle/wrapper-validation-action@v2 | ||
|
||
- name: Fix Gradle permission | ||
run: chmod +x gradlew | ||
|
||
- name: Test with Gradle | ||
run: ./gradlew buildArtifacts test --stacktrace --no-daemon |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
name: Push Build | ||
|
||
on: | ||
push: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
build: | ||
if: ${{ !startsWith(github.ref.name, 'refs/tags/') && contains(github.event.head_commit.message, '[build skip]') == false }} | ||
permissions: | ||
contents: write | ||
|
||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
submodules: true | ||
|
||
- name: Setup jdk 17 | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: 'zulu' | ||
java-version: '17' | ||
|
||
- uses: gradle/wrapper-validation-action@v2 | ||
|
||
- name: Fix Gradle permission | ||
run: chmod +x gradlew | ||
|
||
- name: Build with Gradle | ||
run: ./gradlew buildArtifacts --stacktrace --no-daemon | ||
|
||
- name: Get short SHA | ||
run: echo "SHORT_SHA=${GITHUB_SHA::7}" >> $GITHUB_ENV | ||
|
||
- name: Read Properties info | ||
id: prop_info | ||
uses: christian-draeger/[email protected] | ||
with: | ||
path: gradle.properties | ||
properties: "release_version" | ||
|
||
- name: Upload Artifacts | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: TubeNekoPlugin-${{ env.SHORT_SHA }} | ||
path: | | ||
build/libs/*.jar | ||
- name: Create GitHub Release | ||
if: ${{ contains(github.event.head_commit.message, '[publish skip]') == false && contains(github.event.head_commit.message, 'release:') }} | ||
uses: softprops/action-gh-release@v2 | ||
with: | ||
files: | | ||
build/libs/*.jar | ||
!build/libs/*-dev.jar | ||
!build/libs/*-dev-source.jar | ||
name: ${{ steps.prop_info.outputs.release_version }} | ||
tag_name: ${{ steps.prop_info.outputs.release_version }}-${{ env.SHORT_SHA }} | ||
make_latest: "true" | ||
target_commitish: ${{ github.event.ref }} | ||
generate_release_notes: true | ||
token: ${{ secrets.RELEASE_TOKEN }} |
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
30 changes: 0 additions & 30 deletions
30
bukkit/src/main/java/xyz/tcbuildmc/minecraft/hnp/HorizontalNekoPlugin.java
This file was deleted.
Oops, something went wrong.
41 changes: 41 additions & 0 deletions
41
bukkit/src/main/java/xyz/tcbuildmc/minecraft/hnp/bukkit/HorizontalNekoPlugin.java
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,41 @@ | ||
package xyz.tcbuildmc.minecraft.hnp.bukkit; | ||
|
||
import dev.jorel.commandapi.CommandAPI; | ||
import dev.jorel.commandapi.CommandAPIBukkitConfig; | ||
import lombok.Getter; | ||
import org.bukkit.plugin.java.JavaPlugin; | ||
import xyz.tcbuildmc.minecraft.hnp.bukkit.command.HorizontalNekoCommands; | ||
import xyz.tcbuildmc.minecraft.hnp.common.HorizontalNekoPluginConfigHelper; | ||
|
||
@Getter | ||
public final class HorizontalNekoPlugin extends JavaPlugin { | ||
private static HorizontalNekoPlugin instance; | ||
private static HorizontalNekoPluginConfigHelper config; | ||
|
||
public HorizontalNekoPlugin() { | ||
HorizontalNekoPlugin.instance = this; | ||
HorizontalNekoPlugin.config = new HorizontalNekoPluginConfigHelper(HorizontalNekoPlugin.class); | ||
} | ||
|
||
@Override | ||
public void onLoad() { | ||
// CommandAPI Initialize | ||
CommandAPI.onLoad(new CommandAPIBukkitConfig(this).verboseOutput(true)); | ||
|
||
HorizontalNekoCommands.register(); | ||
} | ||
|
||
@Override | ||
public void onEnable() { | ||
CommandAPI.onEnable(); | ||
|
||
config.load(); | ||
} | ||
|
||
@Override | ||
public void onDisable() { | ||
config.close(); | ||
|
||
CommandAPI.onDisable(); | ||
} | ||
} |
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
4 changes: 4 additions & 0 deletions
4
bukkit/src/main/java/xyz/tcbuildmc/minecraft/hnp/bukkit/command/LuckyCommand.java
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,4 @@ | ||
package xyz.tcbuildmc.minecraft.hnp.bukkit.command; | ||
|
||
public final class LuckyCommand { | ||
} |
4 changes: 4 additions & 0 deletions
4
bukkit/src/main/java/xyz/tcbuildmc/minecraft/hnp/bukkit/hook/papi/PlaceholderAPIHook.java
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,4 @@ | ||
package xyz.tcbuildmc.minecraft.hnp.bukkit.hook.papi; | ||
|
||
public class PlaceholderAPIHook { | ||
} |
18 changes: 18 additions & 0 deletions
18
bukkit/src/main/java/xyz/tcbuildmc/minecraft/hnp/bukkit/util/BukkitHolderString.java
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,18 @@ | ||
package xyz.tcbuildmc.minecraft.hnp.bukkit.util; | ||
|
||
import org.bukkit.ChatColor; | ||
import xyz.tcbuildmc.common.util.HolderString; | ||
|
||
public class BukkitHolderString extends HolderString { | ||
public BukkitHolderString(String string) { | ||
super(string); | ||
} | ||
|
||
public BukkitHolderString() { | ||
} | ||
|
||
public BukkitHolderString appendColor(ChatColor color) { | ||
this.setString(color + this.getString()); | ||
return this; | ||
} | ||
} |
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
4 changes: 2 additions & 2 deletions
4
.../minecraft/hnp/util/ExecutorSupplier.java → ...aft/hnp/bukkit/util/ExecutorSupplier.java
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
4 changes: 0 additions & 4 deletions
4
bukkit/src/main/java/xyz/tcbuildmc/minecraft/hnp/command/LuckyCommand.java
This file was deleted.
Oops, something went wrong.
4 changes: 0 additions & 4 deletions
4
bukkit/src/main/java/xyz/tcbuildmc/minecraft/hnp/hook/papi/PlaceholderAPIHook.java
This file was deleted.
Oops, something went wrong.
4 changes: 0 additions & 4 deletions
4
bukkit/src/main/java/xyz/tcbuildmc/minecraft/hnp/throwable/HorizontalNekoException.java
This file was deleted.
Oops, something went wrong.
4 changes: 0 additions & 4 deletions
4
bukkit/src/main/java/xyz/tcbuildmc/minecraft/hnp/util/Constants.java
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.