Skip to content

Examples: one folder per form, under the file names the commands read by default #35

Closed

Description

@tudor-pop

Problem

render and check read Proxyfile, proxyfile.conf, proxyfile.yaml or proxyfile.yml when given no file (internal/cli/cli.go, defaultNames), and the README's Quick start saves the file under those names, but every example is examples/<name>/gateway.yaml with its HOCON twin gateway.conf. A reader who copies an example gets a name the commands do not read by default, and the two conventions sit side by side in the same README.

What changes

The layout the owner chose on 2026-11-12: one folder per form, because proxyfile refuses a folder that holds two default-named files ("more than one default file here").

  • Every example becomes examples/<name>/yaml/proxyfile.yaml and examples/<name>/hocon/Proxyfile (moved with git mv from gateway.yaml and gateway.conf), each folder with its own committed outputs (envoy.yaml, and rpc-table.json where the example has one), the same bytes in both. proxyfile render -o envoy.yaml and proxyfile check -o envoy.yaml then work in every example folder with no file argument.
  • Files an example shares between its forms (examples/partial's proto/, methods.json, rpc-methods.conf) stay at the example's top and are named by relative path; examples/partial's third form (today's Proxyfile, the methods read from .proto files) gets its own folder, examples/partial/proto-methods/.
  • Every mention follows: README.md, the pages under docs/, the tests that read the examples (under internal/), scripts/validate-envoy.sh, and each include inside an example.
  • No format or behaviour change.

Acceptance

  • git grep -n -E 'gateway\.(yaml|conf)' prints nothing (control at master: 97 mentions in 18 files).
  • In every examples/*/*/ folder that holds a proxyfile, proxyfile check -o envoy.yaml with no file argument exits 0 (a loop quoted in the PR), and each output equals the bytes master has for that example (git diff -M --stat master shows the outputs as renames or copies with no content change).
  • go test ./... green and scripts/validate-envoy.sh validates every example.

Consumers

  • internal/render/render_test.go, internal/format/schema_test.go, internal/format/docs_test.go, scripts/validate-envoy.sh, docs/*.md, README.md: each names the example files; the sweep above is the list. Checked: git grep -l -E 'gateway\.(yaml|conf)', the files the PR renames the mentions in.
  • Users who copied an example by its old name: nothing changes for them, the format and the tool read any name the rule allows.
  • Open tickets checked: gh search issues 'examples gateway.yaml rename' --repo kitecorp/proxyfile --state open, none.

Lane

LIGHT - file renames and the mentions that follow; no code behaviour or format change.

Activity

  1. added
    documentation
    on Nov 12, 2026
  2. tudor-pop commented on Nov 12, 2026

    @tudor-pop
    ContributorAuthor

    Merged as #36, master 360c083: every example is one folder per form (yaml/proxyfile.yaml, hocon/Proxyfile) with its own committed output, so render and check work in each with no file argument.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentation

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions