Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions .github/scripts/ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,14 @@ ls "$PLUGIN_DIR"
# Confirm plugin is installed and in config
"$PRIVATEER_BIN" list -b "$PLUGIN_DIR" -c "$CONFIG_FILE"

# Run pvtr with the plugin
"$PRIVATEER_BIN" run -b "$PLUGIN_DIR" -c "$CONFIG_FILE" || STATUS=1
# Run pvtr with the plugin.
# Exit 0 (all checks passed) and exit 1 (some checks failed) both indicate the
# plugin ran to completion. Any other exit code means pvtr/the plugin crashed,
# which should fail CI.
"$PRIVATEER_BIN" run -b "$PLUGIN_DIR" -c "$CONFIG_FILE"
RUN_STATUS=$?
if [ "$RUN_STATUS" -ne 0 ] && [ "$RUN_STATUS" -ne 1 ]; then
STATUS=$RUN_STATUS
fi

exit $STATUS
Binary file added github-repo-dev
Binary file not shown.
6 changes: 3 additions & 3 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@ go 1.26.2

require (
github.com/gabriel-vasile/mimetype v1.4.13
github.com/gemaraproj/go-gemara v0.3.0
github.com/gemaraproj/go-gemara v0.4.0
github.com/goccy/go-yaml v1.19.2
github.com/google/go-github/v74 v74.0.0
github.com/migueleliasweb/go-github-mock v1.5.0
github.com/ossf/si-tooling/v2 v2.2.0
github.com/privateerproj/privateer-sdk v1.23.3
github.com/privateerproj/privateer-sdk v1.24.0
github.com/rhysd/actionlint v1.7.12
github.com/shurcooL/githubv4 v0.0.0-20240727222349-48295856cce7
golang.org/x/oauth2 v0.36.0
Expand Down Expand Up @@ -88,7 +88,7 @@ require (
)

// Uncomment if you're working on a dependency locally
// replace github.com/privateerproj/privateer-sdk => ../privateer-sdk
// replace github.com/privateerproj/privateer-sdk => ../../privateer-sdk

// replace github.com/gemaraproj/go-gemara => ../../gemaraproj/go-gemara

Expand Down
8 changes: 4 additions & 4 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ github.com/fsnotify/fsnotify v1.9.0 h1:2Ml+OJNzbYCTzsxtv8vKSFD9PbJjmhYF14k/jKC7S
github.com/fsnotify/fsnotify v1.9.0/go.mod h1:8jBTzvmWwFyi3Pb8djgCCO5IBqzKJ/Jwo8TRcHyHii0=
github.com/gabriel-vasile/mimetype v1.4.13 h1:46nXokslUBsAJE/wMsp5gtO500a4F3Nkz9Ufpk2AcUM=
github.com/gabriel-vasile/mimetype v1.4.13/go.mod h1:d+9Oxyo1wTzWdyVUPMmXFvp4F9tea18J8ufA774AB3s=
github.com/gemaraproj/go-gemara v0.3.0 h1:azCDwI7kR1tDF9+KIIV+EQYbb1uNNZhA++RoU63ImZk=
github.com/gemaraproj/go-gemara v0.3.0/go.mod h1:soDwOy6Xhhi6evU7viVZ1WPYnGLHWFEbnL0AMha+/v4=
github.com/gemaraproj/go-gemara v0.4.0 h1:zyn7bJiqAitrRBCDlMYVLb8C1XhDWG2wI0j+pHad3HA=
github.com/gemaraproj/go-gemara v0.4.0/go.mod h1:knXQmQ4f7vB18eb6TcUCP2A3dqQpn+oZdyz74Qe1+ac=
github.com/gliderlabs/ssh v0.3.8 h1:a4YXD1V7xMF9g5nTkdfnja3Sxy1PVDCj1Zg4Wb8vY6c=
github.com/gliderlabs/ssh v0.3.8/go.mod h1:xYoytBv1sV0aL3CavoDuJIQNURXkkfPA/wxQ1pL1fAU=
github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376 h1:+zs/tPmkDkHx3U66DAb0lQFJrpS6731Oaa12ikc+DiI=
Expand Down Expand Up @@ -134,8 +134,8 @@ github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINE
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 h1:Jamvg5psRIccs7FGNTlIRMkT8wgtp5eCXdBlqhYGL6U=
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/privateerproj/privateer-sdk v1.23.3 h1:izf8YKLprCMNkxoi9tNdlx71nquAvqe88kLw46IWY8Q=
github.com/privateerproj/privateer-sdk v1.23.3/go.mod h1:VjTI+mwc80cxn5QWlJAnJvheGtglMwrS4SVQA/9jO0Y=
github.com/privateerproj/privateer-sdk v1.24.0 h1:4LrKa/L6gTwYGDTBNw/6wd7Vpz7a7EfKOCHgYYhZS7E=
github.com/privateerproj/privateer-sdk v1.24.0/go.mod h1:cpPG0pIxK3JBmup0pythXw7havFewR/GkoRbg0ufwgc=
github.com/rhysd/actionlint v1.7.12 h1:vQ4GeJN86C0QH+gTUQcs8McmK62OLT3kmakPMtEWYnY=
github.com/rhysd/actionlint v1.7.12/go.mod h1:krOUhujIsJusovkaYzQ/VNH8PFexjNKqU0q5XI/4w+g=
github.com/robfig/cron/v3 v3.0.1 h1:WdRxkvbJztn8LMz/QEvLN5sBU+xKpSqwwUO1Pjr4qDs=
Expand Down
7 changes: 4 additions & 3 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import (

"github.com/privateerproj/privateer-sdk/command"
"github.com/privateerproj/privateer-sdk/pluginkit"
"github.com/privateerproj/privateer-sdk/shared"
)

var (
Expand Down Expand Up @@ -50,15 +51,15 @@ func main() {
err := orchestrator.AddReferenceCatalogs(dataDir, files)
if err != nil {
fmt.Printf("Error loading catalog: %v\n", err)
os.Exit(1)
os.Exit(shared.InternalError)
}

orchestrator.AddRequiredVars(RequiredVars)

err = orchestrator.AddEvaluationSuiteForAllCatalogs(nil, evaluation_plans.AllSteps())
if err != nil {
fmt.Printf("Error adding evaluation suites: %v\n", err)
os.Exit(1)
os.Exit(shared.InternalError)
}

runCmd := command.NewPluginCommands(
Expand All @@ -71,6 +72,6 @@ func main() {

err = runCmd.Execute()
if err != nil {
os.Exit(1)
os.Exit(shared.InternalError)
}
}
Binary file added pvtr-github-repo-dev
Binary file not shown.
Loading