{"id":20092355,"url":"https://github.com/rubixdev/carpet-database","last_synced_at":"2025-03-02T15:53:03.237Z","repository":{"id":64185553,"uuid":"528060511","full_name":"RubixDev/carpet-database","owner":"RubixDev","description":"A database of carpet rules provided by Carpet Mod and many of its extensions","archived":false,"fork":false,"pushed_at":"2024-03-20T03:51:27.000Z","size":1967,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-13T03:12:25.610Z","etag":null,"topics":["carpet-mod","database","docker","python-script"],"latest_commit_sha":null,"homepage":"https://carpet.rubixdev.de","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/RubixDev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"ko_fi":"rubixdev"}},"created_at":"2022-08-23T15:49:18.000Z","updated_at":"2023-08-18T05:03:58.000Z","dependencies_parsed_at":"2024-03-20T04:46:26.363Z","dependency_job_id":null,"html_url":"https://github.com/RubixDev/carpet-database","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RubixDev%2Fcarpet-database","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RubixDev%2Fcarpet-database/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RubixDev%2Fcarpet-database/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RubixDev%2Fcarpet-database/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/RubixDev","download_url":"https://codeload.github.com/RubixDev/carpet-database/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241533650,"owners_count":19977826,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["carpet-mod","database","docker","python-script"],"created_at":"2024-11-13T16:36:45.189Z","updated_at":"2025-03-02T15:53:03.215Z","avatar_url":"https://github.com/RubixDev.png","language":"Rust","readme":"# Carpet Rules Database\n\n![Logo](assets/logo.png)\n\nA database of carpet rules provided by\n[Carpet Mod](https://github.com/gnembon/fabric-carpet) and many of its\n[extensions](https://github.com/gnembon/fabric-carpet/wiki/List-of-Carpet-extensions).\n\n## Usage\n\nThe site \u003chttps://carpet.rubixdev.de/\u003e provides a friendly user interface.\n\nAll data is stored in the [`data`](data) directory.\n[`data/combined.json`](data/combined.json) is a combined JSON file with all\nrules, which should be the only thing you need. The data can be accessed under\n\u003chttps://data.carpet.rubixdev.de/data/combined.json\u003e.\n\n## A bit of history\n\nTo my knowledge, the idea of gathering all carpet rules in one place started\nwith\n[my first attempt at a Carpet config creator](https://github.com/RubixDev/CarpetConfigCreator)\nin June 2021. It relied on the Markdown lists most extensions provide, but\nproved to be very fragile to upstream changes and just not very reliable and\naccurate. For curious minds I have re-published it under\n\u003chttps://old.carpet.rubixdev.de/\u003e.\n\nIn January/February 2022 Crec0 then began work on his\n[carpet-rules-database](https://github.com/Crec0/carpet-rules-database) with a\nwebsite at \u003chttps://carpet-rules.crec.dev/\u003e. He uses a Python script to parse\nthe rules from the source files of the mod's GitHub/GitLab sources across\nbranches. This was already much better and more reliable than the Markdown based\napproach, but still doesn't always deliver correct results. His site became\nrelatively widely known in the Carpet community and is currently the standard\nfor searching Carpet rules. It is even pinned in the Carpet Discord.\n\nHis website doesn't provide an interface for creating a Carpet config file\nhowever, and so in August that same year I created a new\n[Carpet config creator](https://github.com/RubixDev/carpet-config-creator) based\non Crec0's database. This can now be accessed under\n\u003chttps://crec.carpet.rubixdev.de/\u003e.\n\nAround the same time I started creating\n[my own database](https://github.com/RubixDev/carpet-database/tree/old), based\non the concept of automating running Minecraft instances to get the rule data\nfrom in-game. This should be the most accurate source of information. My\napproach used Python scripts to clone the repo sources and run them in Docker\ncontainers with the appropriate Java versions installed. It worked, but there\nwere a lot more edge cases and difficulties than I expected. Because of this, I\nnever ended up adding more than ten repos and the config creator never switched\nto using this database.\n\nThat brings us to now, August 2023, where Crec0's database parser has been\nbroken for a couple of months, and I was willing to give my database attempt\nanother chance. At first,\n[I used the same Git-based approach](https://github.com/RubixDev/carpet-database/commit/aa35a5a5e8e6894ab27cfa2a8e67544e89c65204)\njust without Docker and in Rust instead of Python (but we will just pretend like\nthat never happened). This of course just surfaced the same issues again, but\nnow I had another idea: using the mod's released jar binaries. This way we don't\nhave to worry too much about each mod's specific development setup. So far, this\nproved to be mostly straight-forward and accurate, but we'll see what happens in\nthe long term. My config creator now also uses this new database and is\naccessible under \u003chttps://carpet.rubixdev.de/\u003e.\n\n## Contributing\n\nTo add or update mods or versions of mods, edit the [`mods.toml`](mods.toml)\nfile. Below is an explanation of the schema. When adding a mod, you probably\nwant to copy this example and delete everything that isn't needed.\n\n```toml\n[[mods]]\n# The name of the mod.\n# Use the name from the `fabric.mod.json` file or the mod page.\nname = \"\"\n# The mod's slug.\n# If any source below uses Modrinth, this must be the Modrinth slug.\n# Otherwise, use the CurseForge slug or mod id.\nslug = \"\"\n# (Optional) If any source below uses CurseForge, set the project id here.\nproject_id = 0\n# (Optional) If any source below uses GitHub, set the repo here `\u003cuser\u003e/\u003crepo\u003e`.\nrepo = \"\"\n# (Optional) A mod-global default for the entrypoint.\n# Should be up-to-date with the latest version.\nentrypoint = \"\"\n# (Optional) A mod-global default for the settings manager.\n# Should be up-to-date with the latest version.\nsettings_manager = \"\"\n# (Optional) A mod-global default for the settings manager class.\n# Should be up-to-date with the latest version.\nsettings_manager_class = \"\"\n# (Optional) A mod-global default for the rule annotation class.\n# Should be up-to-date with the latest version.\nrule_annotation_class = \"\"\n# (Optional) A mod-global default for the settings classes.\n# Should be up-to-date with the latest version.\nsettings_classes = [\"\"]\n# (Optional) A mod-global default for the `run_client` setting.\n# Should be up-to-date with the latest version.\n# Defaults to `false`.\nrun_client = false\n# (Optional) Dependencies that are the same for all versions.\n# Usually used for libraries like MixinExtras or conditional-mixin.\n# Cannot be overwritten per version.\n# See the version-specific dependencies for more information.\ncommon_dependencies = []\n\n# You can define one version for every major Minecraft version.\n# See the latest one for more information on the available settings.\n\n[mods.versions.\"1.14\"]\nminecraft_version = \"1.14.4\"\nprinter_version = \"v1\"\ndependencies = [\"maven.modrinth:carpet:1.3.7\"]\nsource = { host = \"Modrinth\", version = \"\" }\n# source = { host = \"CurseForge\", file_id = 0 }\n# source = { host = \"GitHub\", tag = \"\", asset = \"\" }\n\n[mods.versions.\"1.15\"]\nminecraft_version = \"1.15.2\"\nprinter_version = \"v1\"\ndependencies = [\"maven.modrinth:carpet:1.4.8\"]\nsource = { host = \"Modrinth\", version = \"\" }\n# source = { host = \"CurseForge\", file_id = 0 }\n# source = { host = \"GitHub\", tag = \"\", asset = \"\" }\n\n[mods.versions.\"1.16\"]\nminecraft_version = \"1.16.5\"\nprinter_version = \"v1\"\ndependencies = [\"maven.modrinth:carpet:1.4.44\"]\nsource = { host = \"Modrinth\", version = \"\" }\n# source = { host = \"CurseForge\", file_id = 0 }\n# source = { host = \"GitHub\", tag = \"\", asset = \"\" }\n\n[mods.versions.\"1.17\"]\nminecraft_version = \"1.17.1\"\nprinter_version = \"v1\"\ndependencies = [\"maven.modrinth:carpet:1.4.57\"]\nsource = { host = \"Modrinth\", version = \"\" }\n# source = { host = \"CurseForge\", file_id = 0 }\n# source = { host = \"GitHub\", tag = \"\", asset = \"\" }\n\n[mods.versions.\"1.18\"]\nminecraft_version = \"1.18.2\"\nprinter_version = \"v1\"\ndependencies = [\"maven.modrinth:carpet:1.4.69\"]\nsource = { host = \"Modrinth\", version = \"\" }\n# source = { host = \"CurseForge\", file_id = 0 }\n# source = { host = \"GitHub\", tag = \"\", asset = \"\" }\n\n[mods.versions.\"1.19\"]\nminecraft_version = \"1.19.4\"\nprinter_version = \"v3\"\ndependencies = [\"maven.modrinth:carpet:1.4.101\"]\nsource = { host = \"Modrinth\", version = \"\" }\n# source = { host = \"CurseForge\", file_id = 0 }\n# source = { host = \"GitHub\", tag = \"\", asset = \"\" }\n\n[mods.versions.\"1.20\"]\n# The exact Minecraft to use. This should be the latest for this major MC\n# version that the mod supports.\nminecraft_version = \"1.20.4\"\n# The printer version. Available printers are `v1`, `v2`, `v3`,\n# `magiclib-v1`, and `magiclib-v2.\n# Usually, `v1` is used for pre-1.19 mods and `v3` for \u003e=1.19.\n# `v2` is for scenarios where the Carpet version already uses the new\n# settings manager API, but the mod still uses the old one.\n# `magiclib-v1` is the `v1` equivalent for mods that use the\n# `WrappedSettingManager` type from MagicLib.\n# `magiclib-v2` is the `v3` equivalent for mods that use the\n# `WrappedSettingManager` type from MagicLib.\nprinter_version = \"v3\"\n# (Optional) A version-specific override for the entrypoint.\n# Use `\"\"` to unset the mod default.\n# The entrypoint should have the value of the main entrypoint in the mod's\n# `fabric.mod.json` file, if there is one.\nentrypoint = \"\"\n# (Optional) A version-specific override for the settings manager.\n# Use `\"\"` to unset the mod default.\n# If the mod has a custom settings manager, set this to the full path of the\n# field where it is stored.\nsettings_manager = \"\"\n# (Optional) A version-specific override for the settings manager class.\n# Use `\"\"` to unset the mod default.\n# If the mod uses a custom type for the settings manager, set it here.\n# This is mainly for users of MagicLib, like TCTC.\nsettings_manager_class = \"\"\n# (Optional) A version-specific override for the rule annotation class.\n# Use `\"\"` to unset the mod default.\n# This is the class of the `@Rule` annotations used in the settings classes.\n# Do not set this unless the mod define its own annotation.\nrule_annotation_class = \"\"\n# (Optional) A version-specific override for the settings classes.\n# A value must be set either here or for the entire mod.\n# This specifies the list of classes that define carpet rules.\n# Usually this is just one.\nsettings_classes = [\"\"]\n# (Optional) A version-specific override for the `run_client` setting.\n# Usually the mods are run in a server environment.\n# However, some mods require a client environment, which can be specified here.\nrun_client = false\n# Additional dependencies this mod needs.\n# This always includes the appropriate Carpet version.\n# To add mods from Modrinth use `maven.modrinth:\u003cslug\u003e:\u003cversion\u003e`.\n# To add mods from CurseForge use `curse.maven:\u003cslug\u003e-\u003cproject_id\u003e:\u003cfile_id\u003e`.\ndependencies = [\"maven.modrinth:carpet:1.4.128\"]\n# Where to download the mod from.\n# Either Modrinth, CurseForge, or GitHub.\n# Modrinth sources can optionally define `filename` to specify a non-primary\n# file from the version.\nsource = { host = \"Modrinth\", version = \"\" }\n# source = { host = \"CurseForge\", file_id = 0 }\n# source = { host = \"GitHub\", tag = \"\", asset = \"\" }\n```\n","funding_links":["https://ko-fi.com/rubixdev"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frubixdev%2Fcarpet-database","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frubixdev%2Fcarpet-database","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frubixdev%2Fcarpet-database/lists"}