Skip to content
Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Repository files navigation

Resource Pack Validator

GitHub issuesLicenseDiscord

A commandline tool to validate a Minecraft Java Edition resource pack. It runs several validations, that normally run when loading the resource pack in the vanilla client as well as some extra validations to identify issues.

Commandline Arguments

  • -help Show all available commandline arguments
  • --resourcepack <directory or zip>, -rp <directory or zip> Specifies the path of the resource pack to validate. By default, it assumes the resource pack is located at ./resourcepack or ./resourcepack.zip (if ./resourcepack does not exist)
  • --verbose, -v Enables verbose log output
  • -config Specifies the path to the config file. By default, it assumes it is located at ./config.json
  • -report <file> Specifies the path the report file. By default, it does not generate a XML report

Using with GitHub Action

In order to use the GitHub action, you'll need to create a workflow file inside .github/workflows/ (e.g. .github/workflows/validate-resource-pack.yml) with the following content:

name: Validate Resource Packon: [push]jobs:
validate-resource-pack:
runs-on: ubuntu-lateststeps:
- name: Checkout repositoryuses: actions/checkout@v4
- name: Validate Resource Packuses: MrKinau/ResourcePackValidator@v2with:
resourcepack: resourcepackconfig: config.json

You can change resourcepack with the path to your resourcepack directory or zip inside the repository.

You can change config to the location of your config file inside the repo.

Using with Gitlab CI

In order to use the Gitlab CI, you'll need to create a file inside your repository with the name .gitlab-ci.yml (or change the file location/name in Gitlab CI/CD Settings » General Pipelines) with the following content:

stages:
- validatevalidate-resource-pack:
image:
name: ghcr.io/mrkinau/resourcepackvalidator:masterentrypoint: [""]stage: validatescript:
- resourcepackvalidator -rp resourcepack -config config.json

You can change resourcepack with the path to your resourcepack directory or zip inside the repository.

You can change config to the location of your config file inside the repo.

Additionally, you can add a JUnit like test report, which will be visible in Gitlab:

stages:
- validatevalidate-resource-pack:
image:
name: ghcr.io/mrkinau/resourcepackvalidator:masterentrypoint: [""]stage: validatescript:
- resourcepackvalidator -rp resourcepack -config config.json -report ./report.xmlartifacts:
when: alwaysuntracked: falsename: "${CI_PROJECT_NAME}_${CI_COMMIT_REF_NAME}"paths:
- "report.xml"expire_in: 7 dayreports:
junit:
- "report.xml"
ScreenshotGitlab CI Tests screenshot showing some validators failing

Validators

All currently implemented Validators can be found here.

Ideas / Future plans for Validators

Extend Unused Files Detection

Extend detection, to find models which do not have an override or override a vanilla item. Also check all textures if they are used by a model which already is unused?

Animated texture frames missing / too many sprite frames

Checks if an animated texture has too many / too few frames.

Version support

There is no way to enforce a specific minecraft version, vanilla resources from different 1.20 and 1.21 versions are merged to validate against.

Discord

To follow the project, get support or request features or bugs you can join my Discord: https://discord.gg/xHpCDYf

Contribution

You are free to create a fork, or a pull request to participate. You also can report bugs or request a new feature in the issues tab or on my Discord (I will answer them as soon as possible)

About

minecraft resource pack validator

Resources

Stars

12 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages