mirror of
https://github.com/coder/coder.git
synced 2026-09-24 15:04:27 +08:00
feat: add examples to api (#5331)
Co-authored-by: Dean Sheather <dean@deansheather.com>
This commit is contained in:
co-authored by
Dean Sheather
parent
6cc864c048
commit
ca0374b94f
+2
-1
@@ -8,6 +8,7 @@ import (
|
||||
"github.com/spf13/cobra"
|
||||
|
||||
"github.com/coder/coder/cli/cliui"
|
||||
"github.com/coder/coder/codersdk"
|
||||
"github.com/coder/coder/examples"
|
||||
"github.com/coder/coder/provisionersdk"
|
||||
)
|
||||
@@ -22,7 +23,7 @@ func templateInit() *cobra.Command {
|
||||
return err
|
||||
}
|
||||
exampleNames := []string{}
|
||||
exampleByName := map[string]examples.Example{}
|
||||
exampleByName := map[string]codersdk.TemplateExample{}
|
||||
for _, example := range exampleList {
|
||||
name := fmt.Sprintf(
|
||||
"%s\n%s\n%s\n",
|
||||
|
||||
Reference in New Issue
Block a user