Bastian / bstats-metrics

The different bStats Metrics classes
https://bStats.org
MIT License
98 stars 113 forks source link
bstats bukkit bungeecord hacktoberfest metrics minecraft spigot sponge

bStats Java Metrics Classes

This repository contains the code for all Java-based Metrics classes.

Code Generation

The recommended way to include the Metrics classes is to use a build management tool like Gradle or Maven and shade + relocate the required classes.

However, to make bStats more accessible for beginners, a single file Metrics class is automatically generated on every release and pushed to the single-file branch. This file can simply be copy-and-pasted.

To generate a Metrics class locally, you can run the gradlew generateMetrics command. It will write the generated files into the <platform>/build/generated/ directory.

Publishing

Snapshots are automatically published on every push.

To publish a new release, one can simply remove the -SNAPSHOT suffix from the version in the gradle.properties file and in the MetricsBase class. This will automatically trigger a GitHub Action that

GitHub Action Secrets

For the GitHub Actions to properly work, one must configure the following encrypted secrets: