Skip to content

Commit

Permalink
Merge from dev
Browse files Browse the repository at this point in the history
  • Loading branch information
RobiNino committed Sep 4, 2024
2 parents e7a1ecd + f8edf9e commit 381e58f
Show file tree
Hide file tree
Showing 13 changed files with 369 additions and 20 deletions.
2 changes: 1 addition & 1 deletion build/npm/v2-jf/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion build/npm/v2-jf/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "jfrog-cli-v2-jf",
"version": "2.65.0",
"version": "2.67.0",
"description": "🐸 Command-line interface for JFrog Artifactory, Xray, Distribution, Pipelines and Mission Control 🐸",
"homepage": "https://github.com/jfrog/jfrog-cli",
"preferGlobal": true,
Expand Down
2 changes: 1 addition & 1 deletion build/npm/v2/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion build/npm/v2/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "jfrog-cli-v2",
"version": "2.65.0",
"version": "2.67.0",
"description": "🐸 Command-line interface for JFrog Artifactory, Xray, Distribution, Pipelines and Mission Control 🐸",
"homepage": "https://github.com/jfrog/jfrog-cli",
"preferGlobal": true,
Expand Down
25 changes: 20 additions & 5 deletions buildtools/cli.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ package buildtools
import (
"errors"
"fmt"
"github.com/jfrog/jfrog-cli-security/utils/techutils"
"os"
"strconv"
"strings"
Expand Down Expand Up @@ -91,7 +92,10 @@ func GetCommands() []cli.Command {
SkipFlagParsing: true,
BashComplete: corecommon.CreateBashCompletionFunc(),
Category: buildToolsCategory,
Action: MvnCmd,
Action: func(c *cli.Context) (err error) {
cmdName, _ := getCommandName(c.Args())
return securityCLI.WrapCmdWithCurationPostFailureRun(c, MvnCmd, techutils.Maven, cmdName)
},
},
{
Name: "gradle-config",
Expand Down Expand Up @@ -215,7 +219,10 @@ func GetCommands() []cli.Command {
SkipFlagParsing: true,
BashComplete: corecommon.CreateBashCompletionFunc(),
Category: buildToolsCategory,
Action: GoCmd,
Action: func(c *cli.Context) (err error) {
cmdName, _ := getCommandName(c.Args())
return securityCLI.WrapCmdWithCurationPostFailureRun(c, GoCmd, techutils.Go, cmdName)
},
},
{
Name: "go-publish",
Expand Down Expand Up @@ -252,7 +259,10 @@ func GetCommands() []cli.Command {
SkipFlagParsing: true,
BashComplete: corecommon.CreateBashCompletionFunc(),
Category: buildToolsCategory,
Action: PipCmd,
Action: func(c *cli.Context) (err error) {
cmdName, _ := getCommandName(c.Args())
return securityCLI.WrapCmdWithCurationPostFailureRun(c, PipCmd, techutils.Pip, cmdName)
},
},
{
Name: "pipenv-config",
Expand Down Expand Up @@ -325,9 +335,13 @@ func GetCommands() []cli.Command {
SkipFlagParsing: true,
BashComplete: corecommon.CreateBashCompletionFunc("install", "i", "isntall", "add", "ci", "publish", "p"),
Category: buildToolsCategory,
Action: func(c *cli.Context) error {
Action: func(c *cli.Context) (errFromCmd error) {
cmdName, _ := getCommandName(c.Args())
return npmGenericCmd(c, cmdName, false)
return securityCLI.WrapCmdWithCurationPostFailureRun(c,
func(c *cli.Context) error {
return npmGenericCmd(c, cmdName, false)
},
techutils.Npm, cmdName)
},
},
{
Expand Down Expand Up @@ -831,6 +845,7 @@ func npmGenericCmd(c *cli.Context, cmdName string, collectBuildInfoIfRequested b

// Run generic npm command.
npmCmd := npm.NewNpmCommand(cmdName, collectBuildInfoIfRequested)

configFilePath, args, err := GetNpmConfigAndArgs(c)
if err != nil {
return err
Expand Down
9 changes: 9 additions & 0 deletions docs/general/summary/help.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
package summary

var Usage = []string{"csm"}

func GetDescription() string {
return `Generates a Summary of recorded CLI commands there were executed on the current machine.
The report is generated in Markdown format and saved in the directory stored in the JFROG_CLI_COMMAND_SUMMARY_OUTPUT_DIR environment variable.
`
}
Loading

0 comments on commit 381e58f

Please sign in to comment.