Skip to content

Restrict organization names to underscores and hyphenate docs subdomains#1623

Merged
ericmj merged 1 commit into
mainfrom
org-subdomain-hyphens
Jun 4, 2026
Merged

Restrict organization names to underscores and hyphenate docs subdomains#1623
ericmj merged 1 commit into
mainfrom
org-subdomain-hyphens

Conversation

@ericmj

@ericmj ericmj commented Jun 3, 2026

Copy link
Copy Markdown
Member

Organization docs move to per-org subdomains under hexorgs.pm, where the subdomain label maps _ -> - (RFC 1123 / strict SAN matching). Tighten the org name charset from ^[a-z0-9_\-\.]+$ to ^[a-z0-9_]+$ so the _ <-> - mapping is an exact bijection, mirroring package names.

docs_html_url/3 now hyphenates the org repository name when building the subdomain (reusing the renamed name_to_subdomain/1 helper), so the generated documentation links point at the canonical host.

See hexpm/hexdocs#121.

@github-actions

github-actions Bot commented Jun 3, 2026

Copy link
Copy Markdown

Dependency Review

The following issues were found:
  • ✅ 0 vulnerable package(s)
  • ✅ 0 package(s) with incompatible licenses
  • ✅ 0 package(s) with invalid SPDX license definitions
  • ⚠️ 4 package(s) with unknown licenses.
See the Details below.

License Issues

mix.exs

PackageVersionLicenseIssue Type
decimal3.1.1NullUnknown License
ex_aws2.7.0NullUnknown License
floki0.38.3NullUnknown License
req0.5.18NullUnknown License

OpenSSF Scorecard

PackageVersionScoreDetails
unknown/decimal 3.1.1 UnknownUnknown
unknown/ex_aws 2.7.0 UnknownUnknown
unknown/floki 0.38.3 UnknownUnknown
unknown/req 0.5.18 UnknownUnknown

Scanned Files

  • mix.exs

@ericmj ericmj force-pushed the org-subdomain-hyphens branch from 72e810f to e7c44db Compare June 3, 2026 20:10
Organization docs move to per-org subdomains under hexorgs.pm, where the
subdomain label maps `_` -> `-` (RFC 1123 / strict SAN matching). Tighten
the org name charset from `^[a-z0-9_\-\.]+$` to `^[a-z0-9_]+$` so the
`_` <-> `-` mapping is an exact bijection, mirroring package names.

docs_html_url/3 now hyphenates the org repository name when building the
subdomain (reusing the renamed name_to_subdomain/1 helper), so the
generated documentation links point at the canonical host.

The /api/repo test is updated to use an underscore org name, since
hyphens are no longer valid.
@ericmj ericmj force-pushed the org-subdomain-hyphens branch from e7c44db to fba1488 Compare June 4, 2026 08:30
@ericmj ericmj marked this pull request as ready for review June 4, 2026 08:36
@ericmj ericmj merged commit b6f5e19 into main Jun 4, 2026
26 checks passed
@ericmj ericmj deleted the org-subdomain-hyphens branch June 4, 2026 20:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant