Documentation
¶
Overview ¶
Package template4datatug holds a reviewed, immutable DataTug demo template. The provider adapter supplies the selected repository and branch; this package only returns bounded regular-file bytes for one project folder.
Code generated by generate_shipping_component.py; DO NOT EDIT.
Code generated by generate_demo_template.py; DO NOT EDIT.
Index ¶
- Constants
- Variables
- func CloneDemoProject(folder, projectID, title string, created time.Time) (map[string][]byte, error)
- func DemoProjectFiles(folder string) (map[string][]byte, error)
- func ShippingComponentFiles() (map[string][]byte, error)
- func StampClonedQueryCreation(files map[string][]byte, at time.Time) error
- func ValidateFolder(folder string) error
Constants ¶
const ( DemoProjectID = "demo-project-1" DemoProjectSource = "datatug/datatug-demo-project" )
const ( DemoProjectCommit = "436350d41371103be11144ffa346c605f85e1342" // DemoProjectFileCount is the exact number of regular files in this pinned template. DemoProjectFileCount = 637 )
const ShippingComponentCommit = "cb841345e88d01229857b2bdb51cc07f4ef4bec7"
const ShippingComponentDigest = "58d3bf62b78c7f43a1d905ffd8a9ff056f418ea4b8a6efd5fb921b635da01d2e"
const ShippingComponentID = "shipping-investigation"
const ShippingComponentVersion = 1
Variables ¶
var ( ErrInvalidTemplate = errors.New("invalid DataTug demo template") ErrInvalidFolder = errors.New("invalid project folder") )
Functions ¶
func CloneDemoProject ¶
func CloneDemoProject(folder, projectID, title string, created time.Time) (map[string][]byte, error)
CloneDemoProject assigns destination identity and saved-query creation metadata. The manifest's other JSON members and all other template files survive.
func DemoProjectFiles ¶
DemoProjectFiles verifies the embedded archive against its independently recorded manifest, then returns a clone beneath folder. Every non-manifest file keeps its source bytes. Callers may replace datatug-project.json with a new identity/title/access/created object before a single Git commit.
func ShippingComponentFiles ¶ added in v0.45.0
ShippingComponentFiles returns fresh, hash-verified definition bytes. It never changes DemoProjectCommit or admits an execution source.
func StampClonedQueryCreation ¶ added in v0.47.0
StampClonedQueryCreation assigns creation metadata to the new destination's saved queries without narrowing or discarding rich source metadata.
func ValidateFolder ¶
ValidateFolder rejects path traversal and ambiguous external-key delimiters. Nested folders are supported only as clean, bounded relative paths.
Types ¶
This section is empty.