Code Monkey home page Code Monkey logo

Comments (3)

aarlaud avatar aarlaud commented on August 20, 2024

Ack. Snyk-filter predates all-projects option but we'll take a look.

from snyk-filter.

odlevakp avatar odlevakp commented on August 20, 2024

Any movement on this?

I have the same issue, when using --all-projects with snyk test and feeding it to snyk-filter, it will produce invalid JSONs. Would be nice if I can provide developers with snyk-to-html output to better show why their deployment was stopped, instead of the plain output during a pipeline run.

from snyk-filter.

lili2311 avatar lili2311 commented on August 20, 2024

hi @odlevakp This repository is not actively maintained, we are working on critical bug fixes only. However we can suggest you try something like this as a .sh script, but it would generate individual results instead of 1 html file:


#!/bin/bash

set -euo pipefail

exit_code=0

echo 'Running snyk test --all-projects --json | snyk-filter'


for test in `snyk test --all-projects --json $* | jq -r '. | select(.[] or .vulnerabilities) | @base64'`; do    
    project_exit_code=$?
    exit_code+=$project_exit_code
    project="$(echo ${test} | base64 --decode | jq -r '.displayTargetFile')"
    echo ${test} | base64 --decode | snyk-filter -f ./filter-high-vulns-upgradeable.yml --json |snyk-to-html -o results-${project}.html
done

exit $exit_code

from snyk-filter.

Related Issues (12)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.