Skip to content

Commit

Permalink
Merge pull request #218 from wlan0/master
Browse files Browse the repository at this point in the history
remove plugins and fix build and release scripts
  • Loading branch information
wlan0 authored Apr 9, 2018
2 parents e75b671 + 32bb74a commit f54b641
Show file tree
Hide file tree
Showing 8 changed files with 2 additions and 737 deletions.
201 changes: 0 additions & 201 deletions cmd/plugin.go

This file was deleted.

24 changes: 1 addition & 23 deletions cmd/root_cmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package cmd

import (
"bytes"
"context"
"flag"
"fmt"
"os"
Expand All @@ -13,7 +12,6 @@ import (

"github.com/koki/short/client"
"github.com/koki/short/parser"
"github.com/koki/short/plugin"
serrors "github.com/koki/structurederrors"
)

Expand Down Expand Up @@ -99,7 +97,6 @@ func init() {
flag.CommandLine.Parse([]string{})

RootCmd.AddCommand(versionCmd)
RootCmd.AddCommand(pluginCmd)
}

func short(c *cobra.Command, args []string) error {
Expand Down Expand Up @@ -165,23 +162,7 @@ func short(c *cobra.Command, args []string) error {
i := 0
convertedData = []interface{}{}

for filename, unfilteredData := range fileDatas {
if err != nil {
return err
}

config := &plugin.AdmitterContext{
Filename: filename,
KubeNative: kubeNative,
}

// using context because it allows for easy copying of
// common info and ability to add arbitrary info
// per loop
ctx := context.WithValue(context.Background(), "config", config)
ctx = context.WithValue(ctx, "index", i)

data, err := plugin.RunAdmitters(ctx, unfilteredData)
for filename, data := range fileDatas {
if err != nil {
return err
}
Expand Down Expand Up @@ -222,8 +203,5 @@ func short(c *cobra.Command, args []string) error {

fmt.Printf("%s\n", buf.String())

if kubeNative && !dryRun {
return plugin.RunInstallers(buf)
}
return nil
}
88 changes: 0 additions & 88 deletions plugin/admit.go

This file was deleted.

Loading

0 comments on commit f54b641

Please sign in to comment.