You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This PR standardizes the naming convention for task configuration fields
by renaming plural forms to singular forms across the codebase.
## Summary
Renamed configuration field names from plural to singular to improve
consistency and clarity:
- `inputs` → `input` (for file input patterns in cache configuration)
- `envs` → `env` (for environment variables in cache configuration)
## Key Changes
**Configuration Schema Updates:**
- Updated `EnabledCacheConfig` struct fields: `envs: Option<Box<[Str]>>`
→ `env: Option<Box<[Str]>>`
- Updated `EnabledCacheConfig` struct fields: `inputs:
Option<UserInputsConfig>` → `input: Option<UserInputsConfig>`
- Updated TypeScript type definitions in `run-config.ts` to reflect the
new field names
- Updated documentation comment for `UserInputEntry` to reference
`input` array instead of `inputs`
**Code Updates:**
- Updated all references throughout the codebase to use the new field
names
- Updated test cases and test fixtures to use `input` and `env` instead
of `inputs` and `envs`
- Updated configuration deserialization and serialization logic
- Updated default values in `UserTaskOptions::default()`
- Updated synthetic task creation in `lib.rs` and `main.rs`
**Documentation Updates:**
- Updated `task-cache.md` documentation to reference `input` and `env`
fields
- Updated `wildcard-env-patterns.md` to use `env` terminology
- Updated `CLAUDE.md` reference documentation
- Updated test snapshot descriptions and comments
**Test Fixtures:**
- Updated all `vite-task.json` fixture files to use `input` instead of
`inputs`
- Updated all `vite-task.json` fixture files to use `env` instead of
`envs`
- Updated test snapshot files and descriptions
- Updated e2e test configuration files
## Implementation Details
- The change is applied consistently across all configuration layers
(user config, resolved config, cache metadata)
- All serde deserialization/serialization updated to handle the new
field names
- Comments and documentation updated to reflect singular naming
convention
- Test names updated to match the new terminology (e.g., `test_inputs_*`
→ `test_input_*`)
https://claude.ai/code/session_01565Vu5goEjTJjXVVpvaQnb
Co-authored-by: Claude <noreply@anthropic.com>
@@ -131,15 +131,15 @@ This ensures cache invalidation when:
131
131
132
132
The `fingerprinted_envs` field is crucial for cache correctness:
133
133
134
-
- Only includes envs explicitly declared in the task's `envs` array
134
+
- Only includes env vars explicitly declared in the task's `env` array
135
135
- Does NOT include pass-through envs (PATH, CI, etc.)
136
-
- These envs become part of the cache key
136
+
- These env vars become part of the cache key
137
137
138
138
When a task runs:
139
139
140
-
1. All envs (including pass-through) are available to the process
141
-
2. Only declared envs affect the cache key
142
-
3. If a declared env changes value, cache will miss
140
+
1. All env vars (including pass-through) are available to the process
141
+
2. Only declared env vars affect the cache key
142
+
3. If a declared env var changes value, cache will miss
143
143
4. If a pass-through env changes, cache will still hit
144
144
145
145
The `pass_through_envs` field stores env names (not values) — if the set of pass-through env names changes, the cache invalidates, but value changes don't.
@@ -220,13 +220,13 @@ Vite Task uses `fspy` to monitor file system access during task execution:
220
220
221
221
### 7. Inputs Configuration
222
222
223
-
The `inputs` field in `vite-task.json` controls which files are tracked for cache fingerprinting:
223
+
The `input` field in `vite-task.json` controls which files are tracked for cache fingerprinting:
0 commit comments