Skip to content

Commit

Permalink
feat(pkg/run): Add Run method which use config.Config struct as sourc…
Browse files Browse the repository at this point in the history
…e (instead of file)
  • Loading branch information
ondrejsika committed Apr 29, 2023
1 parent 92e5991 commit c683bb1
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions pkg/run/run.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,15 @@ func RunFromFile(
return err
}

return Run(c, dryRun, quietOutput, onlyTags)
}

func Run(
c config.Config,
dryRun bool,
quietOutput bool,
onlyTags []string,
) error {
if c.Meta.SchemaVersion != 3 {
return fmt.Errorf("unsupported schema version: %d", c.Meta.SchemaVersion)
}
Expand Down

0 comments on commit c683bb1

Please sign in to comment.