Add custom aircraft encyclopedia feature#707
Merged
Merged
Conversation
Add a --aircraft-file option (YAML, and JSON since YAML is a superset) that extends or overrides SkyEye's built-in aircraft encyclopedia at startup, so community aircraft mods that SkyEye does not recognize can be categorized, threat-assessed, named on the radio, and matched to tankers. Modeled on the existing custom locations feature. Custom entries parse directly into encyclopedia.Aircraft via an unexported serializedAircraft schema; entries are validated (required ACMI short name, at least one reporting-name field, exactly one wing tag, recognized tags/fuel methods) and registered into the lookup table before the radar is constructed. An entry reusing a built-in ACMI short name overrides it, logged at INFO. Documented in docs/AIRCRAFT.md with the A-4 Skyhawk as the example. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
dharmab
marked this pull request as ready for review
July 10, 2026 22:49
dharmab
enabled auto-merge (squash)
July 10, 2026 22:49
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a
--aircraft-fileoption (aircraft-fileconfig key) that lets server admins extend or override SkyEye's built-in aircraft encyclopedia with a user-supplied YAML file. This makes community aircraft mods that SkyEye does not recognize work correctly — they can be categorized, threat-assessed, named on the radio, and matched to compatible tankers.Modeled on the existing custom locations feature.
How it works
pkg/encyclopedia/custom.go: an unexportedserializedAircraftschema parses directly intoencyclopedia.Aircraft.LoadCustomAircraftreads YAML (a superset of JSON, so.jsonfiles also work), andAddCustomAircraftregisters entries into the lookup table.acmi_short_name, at least one reporting-name field (nato_reporting_name/nickname/official_name/platform_designation), exactly one wing tag, and recognized tag/fuel values.--aircraft-fileflag incmd/skyeye,CustomAircraftfield inconf.Configuration, and registration inapplication.NewApplicationjust before the radar (its first consumer) is built.Docs
docs/AIRCRAFT.mddocuments the schema, tags, threat radius, refueling, and how to find the ACMI short name, using the A-4 Skyhawk as a worked example. Cross-linked fromdocs/ADMIN.md.Testing
make test— passes, including newpkg/encyclopedia/custom_test.go(YAML/JSON parsing, validation errors, tag/fuel mapping, override behavior).make lint vet fix format— clean.make skyeye— builds.🤖 Generated with Claude Code