fix: explicit dagger project usage

Resolves: #2091
Signed-off-by: Vasek - Tom C <tom.chauveau@epitech.eu>
This commit is contained in:
Tom Chauveau 2022-04-11 11:57:15 +02:00 committed by Vasek - Tom C
parent e110ac05a2
commit bc87547390
No known key found for this signature in database
GPG Key ID: 175D82E572427960
2 changed files with 4 additions and 0 deletions

View File

@ -41,6 +41,7 @@ var initCmd = &cobra.Command{
if err != nil { if err != nil {
lg.Fatal().Err(err).Msg("failed to initialize project") lg.Fatal().Err(err).Msg("failed to initialize project")
} }
fmt.Println("Project initialized! To install dagger packages, run `dagger project update`")
}, },
} }

View File

@ -1,6 +1,8 @@
package project package project
import ( import (
"fmt"
"github.com/spf13/cobra" "github.com/spf13/cobra"
"github.com/spf13/viper" "github.com/spf13/viper"
"go.dagger.io/dagger/cmd/dagger/cmd/common" "go.dagger.io/dagger/cmd/dagger/cmd/common"
@ -35,6 +37,7 @@ var updateCmd = &cobra.Command{
if len(args) == 0 { if len(args) == 0 {
lg.Debug().Msg("No package specified, updating all packages") lg.Debug().Msg("No package specified, updating all packages")
pkg.Vendor(ctx, cueModPath) pkg.Vendor(ctx, cueModPath)
fmt.Println("Project updated")
return return
} }