Repository navigation
Add writ deployment infrastructure and rename clifactory to cli - #2
Merged
Merged
Conversation
added 2 commits
January 21, 2026 21:27
Core packages: - internal/cli: Renamed from clifactory for cleaner imports - Added help.go (git-style man page help) - Added viper.go (shared configuration initialization) Writ subpackages: - internal/writ/segment: Platform segmentation matching - internal/writ/tree: Deployment tree builder - internal/writ/exec: File operation execution - internal/writ/state: Deployment state tracking - internal/writ/status: Status checking - internal/writ/receipt: Checksum and receipt handling Commands implemented: - writ add: Deploy projects with symlinks/templates/secrets - writ remove: Remove deployed files with drift detection - writ upgrade: Regenerate copied files from sources - writ status: Show deployment status with drift detection - writ adopt: Move files into repo and create symlinks - writ repo: Manage layered repositories (init/add/list/remove) Schema: - Consolidated to single devlore-config schema
Man pages and shell completions are generated at runtime via `lore man --generate` and `lore completion`. Added to .gitignore.
David-Noble-at-work
pushed a commit
that referenced
this pull request
Mar 8, 2026
…n (Phase 6) Phase 6 — E2E tests + two correctness fixes + phase documents: Immediate bridge callable support: - callNonVariadic detects starlark.Callable values targeting func-typed Go params and adapts them via buildCallableFunc (full-signature Go↔Starlark marshaling). Thread passed through from builtinFunc closure. - Blank import of mem package in test runner for callable extractor registration (needed by planned mode ExtractCallable). Full-signature callable matching (Issue #1): - Removed Actor convenience function and +devlore:callable swallow=stack annotation. The callable must match the full Go Reducer signature (initial, resource, relativePath, stack). - Removed arity truncation from buildCallableFunc — all Go args passed to Starlark. - Updated starcode/provider.go Actor usage to full Reducer signature. - All test callables updated from 3-param to 4-param. Full-fidelity struct serialization (Issue #2): - FormatLiteral now handles *starlarkstruct.Struct values by serializing as dict literals with sorted keys. Enables Resources captured in closures to be serialized with full fidelity. - 3 new tests: Struct, NestedStruct, EmptyStruct. E2E test scripts: - test_walk_tree.star: immediate mode — walk temp dir, collect+sort paths - test_walk_tree_planned.star: planned mode — plan.file.walk_tree - test_walk_tree_gitignore.star: .gitignore filtering - test_walk_tree_closure.star: def capturing closure variable (ext=".py") Phase documents: - Created docs/plans/mem-resource/phase-0.md through phase-7.md - Updated master plan: removed stale arity truncation/swallow references, updated current state, Phase 6 marked done
David-Noble-at-work
pushed a commit
that referenced
this pull request
Mar 8, 2026
…n (Phase 6) Phase 6 — E2E tests + two correctness fixes + phase documents: Immediate bridge callable support: - callNonVariadic detects starlark.Callable values targeting func-typed Go params and adapts them via buildCallableFunc (full-signature Go↔Starlark marshaling). Thread passed through from builtinFunc closure. - Blank import of mem package in test runner for callable extractor registration (needed by planned mode ExtractCallable). Full-signature callable matching (Issue #1): - Removed Actor convenience function and +devlore:callable swallow=stack annotation. The callable must match the full Go Reducer signature (initial, resource, relativePath, stack). - Removed arity truncation from buildCallableFunc — all Go args passed to Starlark. - Updated starcode/provider.go Actor usage to full Reducer signature. - All test callables updated from 3-param to 4-param. Full-fidelity struct serialization (Issue #2): - FormatLiteral now handles *starlarkstruct.Struct values by serializing as dict literals with sorted keys. Enables Resources captured in closures to be serialized with full fidelity. - 3 new tests: Struct, NestedStruct, EmptyStruct. E2E test scripts: - test_walk_tree.star: immediate mode — walk temp dir, collect+sort paths - test_walk_tree_planned.star: planned mode — plan.file.walk_tree - test_walk_tree_gitignore.star: .gitignore filtering - test_walk_tree_closure.star: def capturing closure variable (ext=".py") Phase documents: - Created docs/plans/mem-resource/phase-0.md through phase-7.md - Updated master plan: removed stale arity truncation/swallow references, updated current state, Phase 6 marked done
David-Noble-at-work
added a commit
that referenced
this pull request
Mar 8, 2026
…n (Phase 6) (#202) * feature(op): E2E tests, full-signature callables, struct serialization (Phase 6) Phase 6 — E2E tests + two correctness fixes + phase documents: Immediate bridge callable support: - callNonVariadic detects starlark.Callable values targeting func-typed Go params and adapts them via buildCallableFunc (full-signature Go↔Starlark marshaling). Thread passed through from builtinFunc closure. - Blank import of mem package in test runner for callable extractor registration (needed by planned mode ExtractCallable). Full-signature callable matching (Issue #1): - Removed Actor convenience function and +devlore:callable swallow=stack annotation. The callable must match the full Go Reducer signature (initial, resource, relativePath, stack). - Removed arity truncation from buildCallableFunc — all Go args passed to Starlark. - Updated starcode/provider.go Actor usage to full Reducer signature. - All test callables updated from 3-param to 4-param. Full-fidelity struct serialization (Issue #2): - FormatLiteral now handles *starlarkstruct.Struct values by serializing as dict literals with sorted keys. Enables Resources captured in closures to be serialized with full fidelity. - 3 new tests: Struct, NestedStruct, EmptyStruct. E2E test scripts: - test_walk_tree.star: immediate mode — walk temp dir, collect+sort paths - test_walk_tree_planned.star: planned mode — plan.file.walk_tree - test_walk_tree_gitignore.star: .gitignore filtering - test_walk_tree_closure.star: def capturing closure variable (ext=".py") Phase documents: - Created docs/plans/mem-resource/phase-0.md through phase-7.md - Updated master plan: removed stale arity truncation/swallow references, updated current state, Phase 6 marked done * feature(op): E2E tests, full-signature callables, struct serialization (Phase 6) Phase 6 — E2E tests + two correctness fixes + phase documents: Immediate bridge callable support: - callNonVariadic detects starlark.Callable values targeting func-typed Go params and adapts them via buildCallableFunc (full-signature Go↔Starlark marshaling). Thread passed through from builtinFunc closure. - Blank import of mem package in test runner for callable extractor registration (needed by planned mode ExtractCallable). Full-signature callable matching (Issue #1): - Removed Actor convenience function and +devlore:callable swallow=stack annotation. The callable must match the full Go Reducer signature (initial, resource, relativePath, stack). - Removed arity truncation from buildCallableFunc — all Go args passed to Starlark. - Updated starcode/provider.go Actor usage to full Reducer signature. - All test callables updated from 3-param to 4-param. Full-fidelity struct serialization (Issue #2): - FormatLiteral now handles *starlarkstruct.Struct values by serializing as dict literals with sorted keys. Enables Resources captured in closures to be serialized with full fidelity. - 3 new tests: Struct, NestedStruct, EmptyStruct. E2E test scripts: - test_walk_tree.star: immediate mode — walk temp dir, collect+sort paths - test_walk_tree_planned.star: planned mode — plan.file.walk_tree - test_walk_tree_gitignore.star: .gitignore filtering - test_walk_tree_closure.star: def capturing closure variable (ext=".py") Phase documents: - Created docs/plans/mem-resource/phase-0.md through phase-7.md - Updated master plan: removed stale arity truncation/swallow references, updated current state, Phase 6 marked done --------- Co-authored-by: David Noble <[email protected]>
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.
Summary
internal/clifactorytointernal/clifor consistencyChanges
internal/writ/— Full command implementations (add, remove, upgrade, status, adopt, repo subcommands)internal/writ/segment/— Platform detection and directory matchinginternal/writ/tree/— Deployment tree construction (OpLink, OpExpand, OpDecrypt, OpCopy)internal/writ/exec/— File operation execution with conflict resolutioninternal/writ/state/— State file with age-based signaturesinternal/writ/status/— Status checking utilitiesinternal/writ/receipt/— Checksums and receipt managementinternal/cli/— Renamed from clifactory, added viper and output utilitiesTest plan
go build ./cmd/writcompilesgo test ./internal/writ/...passeswrit add --dry-run all noblefactorshows correct deployment tree