refactor: migrate to new configuration system and model definitions

This commit is contained in:
Prad Nukala
2024-12-11 12:21:52 -05:00
parent 40f50bf37a
commit 0502f52ec0
54 changed files with 154 additions and 443 deletions
@@ -1,4 +1,4 @@
// Code generated from Pkl module `sonr.motr.ATN`. DO NOT EDIT.
// Code generated from Pkl module `sonr.orm.UCAN`. DO NOT EDIT.
package attns
import (
@@ -7,11 +7,11 @@ import (
"github.com/apple/pkl-go/pkl"
)
type ATN struct {
type UCAN struct {
}
// LoadFromPath loads the pkl module at the given path and evaluates it into a ATN
func LoadFromPath(ctx context.Context, path string) (ret *ATN, err error) {
// LoadFromPath loads the pkl module at the given path and evaluates it into a UCAN
func LoadFromPath(ctx context.Context, path string) (ret *UCAN, err error) {
evaluator, err := pkl.NewEvaluator(ctx, pkl.PreconfiguredOptions)
if err != nil {
return nil, err
@@ -26,9 +26,9 @@ func LoadFromPath(ctx context.Context, path string) (ret *ATN, err error) {
return ret, err
}
// Load loads the pkl module at the given source and evaluates it with the given evaluator into a ATN
func Load(ctx context.Context, evaluator pkl.Evaluator, source *pkl.ModuleSource) (*ATN, error) {
var ret ATN
// Load loads the pkl module at the given source and evaluates it with the given evaluator into a UCAN
func Load(ctx context.Context, evaluator pkl.Evaluator, source *pkl.ModuleSource) (*UCAN, error) {
var ret UCAN
if err := evaluator.EvaluateModule(ctx, source, &ret); err != nil {
return nil, err
}
@@ -1,4 +1,4 @@
// Code generated from Pkl module `sonr.motr.ATN`. DO NOT EDIT.
// Code generated from Pkl module `sonr.orm.UCAN`. DO NOT EDIT.
package capability
import (
+2 -2
View File
@@ -1,8 +1,8 @@
// Code generated from Pkl module `sonr.motr.ATN`. DO NOT EDIT.
// Code generated from Pkl module `sonr.orm.UCAN`. DO NOT EDIT.
package attns
import "github.com/apple/pkl-go/pkl"
func init() {
pkl.RegisterMapping("sonr.motr.ATN", ATN{})
pkl.RegisterMapping("sonr.orm.UCAN", UCAN{})
}
@@ -1,4 +1,4 @@
// Code generated from Pkl module `sonr.motr.ATN`. DO NOT EDIT.
// Code generated from Pkl module `sonr.orm.UCAN`. DO NOT EDIT.
package policytype
import (
@@ -1,4 +1,4 @@
// Code generated from Pkl module `sonr.motr.ATN`. DO NOT EDIT.
// Code generated from Pkl module `sonr.orm.UCAN`. DO NOT EDIT.
package resourcetype
import (