Skip to content

feat(res-to-affine): tree-sitter AST walker for side-effect-import (P… #389

feat(res-to-affine): tree-sitter AST walker for side-effect-import (P…

feat(res-to-affine): tree-sitter AST walker for side-effect-import (P… #389

Workflow file for this run

# SPDX-License-Identifier: MPL-2.0
# Stdlib naming convention check
#
# Enforces: stdlib/*.affine filenames are lowercase.
#
# Why: a 2026-04 transition introduced lowercase versions alongside
# pre-existing PascalCase ones (Math.affine + math.affine etc.).
# This caused a permanent case-collision on case-insensitive
# filesystems (Windows NTFS, default macOS). Pinning the convention
# at lowercase prevents the duplicate-file regression.
name: Stdlib Naming Convention
on:
push:
branches: [main]
pull_request:
branches: [main]
permissions:
contents: read
jobs:
enforce-lowercase-stdlib:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Enforce lowercase .affine filenames in stdlib/
run: |
BAD=$(find stdlib -maxdepth 1 -type f -name '*.affine' | grep -E '/stdlib/[A-Z]' || true)
if [ -n "$BAD" ]; then
echo "❌ stdlib/ requires lowercase .affine filenames. Found:"
echo "$BAD"
echo ""
echo "Convention: stdlib/foo.affine, not stdlib/Foo.affine."
echo "PascalCase files cause case-collision on case-insensitive"
echo "filesystems (Windows NTFS, default macOS HFS+/APFS) when a"
echo "lowercase counterpart also exists in the tree."
exit 1
fi
echo "✅ stdlib/ filenames lowercase OK"