MCPcopy Create free account
hub / github.com/Scalingo/cli / ProjectSet

Function ProjectSet

apps/project.go:11–25  ·  view source on GitHub ↗
(ctx context.Context, appName, projectID string)

Source from the content-addressed store, hash-verified

9)
10
11func ProjectSet(ctx context.Context, appName, projectID string) error {
12 c, err := config.ScalingoClient(ctx)
13 if err != nil {
14 return errors.Wrap(ctx, err, "get Scalingo client")
15 }
16
17 _, err = c.AppsSetProject(ctx, appName, projectID)
18 if err != nil {
19 return errors.Wrap(ctx, err, "set project for app")
20 }
21
22 io.Statusf("Project ID has been set to %s for the application %s\n", projectID, appName)
23
24 return nil
25}

Callers 1

apps.goFile · 0.92

Calls 2

ScalingoClientFunction · 0.92
StatusfFunction · 0.92

Tested by

no test coverage detected