Repository navigation
Conversation
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.
Goal
Make
modea first-class build axis that drives behavior, not just build/install paths — so the make layer can do different things indevvs deployment builds (release,conda,macports,ubuntu).modealready existed in the driver as the deployment-intent axis (orthogonal totarget, which governs compiler flags). This branch adds a localreleasemode, plumbs the mode through to make, builds a small framework for mode-dependent recipes, and lands the first consumers.Driver
releasebuild mode: validator + both bldroot/prefix dispatch tables, withdevleft byte-for-byte unchanged.releasemirrorsdevbut injects arelease/discriminator above suite/tag so its artifacts never mix withdev. The construction-time firewall keeps the user-facingmodechoices in sync with what's implemented.project.modeis exported to the make subsystem (alongsideproject.home,project.prefix, …), riding the make command line so$(project.mode)is live from startup._devBldroot/_devPrefixand the new_releaseBldroot/_releasePrefixshare_localBldroot/_localPrefixhelpers.make/modes/frameworkdefaultwhose settings every mode inherits.modes/init.mmhard-includesdefault.mmthen$(project.mode).mm— selecting a mode with no file is a fatal error (the make-layer echo of the driver firewall). Unset knobs default to the baseline (deliberate, distinct from silently failing).mode.npm.locked), never the mode name.devis the one special mode (resolves fresh), and every deployment mode inherits the reproducible defaults — so new modes are usually near-empty and forgetting a knob fails safe.mode.info/mode.helppages, withmode.infoadvertised in the usage index.First consumers:
webpack+viteThe npm dependency-install policy keyed on
mode.npm.locked:package.json, resolve fresh (npm i); the committed package lock file is ignored.package.jsonand the committedpackage-lock.json, install exactly (npm ci).<pack>.lock.seed— seed a cleannpm cifrom the committed lock regardless of mode; this is a recovery mechanism duringnpminstability and fails if the package lock lock file doesn't exist.<pack>.lock.harvest— harvest the package lock file as resolved by a successful build back to the source tree for committing, serving as a last-known-good resolution of the package dependencies.The install prerequisite now is the
node_modules/directory, not the staged configuration file, so a failednpmrun always triggers a new attempt.Verified against real assets (
qed.uxfor webpack;examples/vite-relay,examples/vite-houdinifor vite) via the rule database and real builds: correct prerequisites andnpm ivsnpm ciper mode, thenode_moduleskeying, and the seed/harvest targets all work; no undefined-variable warnings.