summaryrefslogtreecommitdiff
path: root/cmd/planr
diff options
context:
space:
mode:
authorFlu0r1ne <flur01ne@flu0r1ne.net>2021-09-02 03:14:47 -0500
committerFlu0r1ne <flur01ne@flu0r1ne.net>2021-09-02 03:14:47 -0500
commitd078f6dc10eb265a5d88cd96adf86173d6d3ba2e (patch)
treeed8bc2405b60b2ae31405c3d8e27b24fda3ac003 /cmd/planr
parent96701f87a114557f1a013229e889b4b726aa7dc1 (diff)
downloaddeb-planr-d078f6dc10eb265a5d88cd96adf86173d6d3ba2e.tar.xz
deb-planr-d078f6dc10eb265a5d88cd96adf86173d6d3ba2e.zip
Make adapters and internals complient with new directory structure
Diffstat (limited to 'cmd/planr')
-rw-r--r--cmd/planr/sub/build.go12
-rw-r--r--cmd/planr/sub/evaluate.go4
2 files changed, 9 insertions, 7 deletions
diff --git a/cmd/planr/sub/build.go b/cmd/planr/sub/build.go
index 58c3a38..a8b19ec 100644
--- a/cmd/planr/sub/build.go
+++ b/cmd/planr/sub/build.go
@@ -3,17 +3,21 @@ package sub
import (
"golang.flu0r1ne.net/planr"
"golang.flu0r1ne.net/planr/adapters/gtest"
+ "os"
)
func Runner() planr.Runner {
r := planr.Runner {}
+
r.RegisterAdapter(&gtest.GtestAdapter{})
+
+ if wd, err := os.Getwd(); err != nil {
+ r.SetConfigDirFromTree(wd)
+ }
+
return r
}
func Build(params []string) {
-
- rd := planr.RubricDir()
-
- Runner().Build(rd)
+ Runner().Build()
}
diff --git a/cmd/planr/sub/evaluate.go b/cmd/planr/sub/evaluate.go
index 8ce4d81..d183b86 100644
--- a/cmd/planr/sub/evaluate.go
+++ b/cmd/planr/sub/evaluate.go
@@ -5,9 +5,7 @@ import (
)
func Evaluate(params []string) {
- rd := planr.RubricDir()
-
- tcs := Runner().Evaluate(rd)
+ tcs := Runner().Evaluate()
earned := 0.0
total := 0.0