"Fossies" - the Fresh Open Source Software Archive

Member "cli-1.1260.0/src/lib/ecosystems/plugins.ts" (4 Dec 2023, 503 Bytes) of package /linux/misc/snyk-cli-1.1260.0.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) TypeScript source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file.

    1 import * as cppPlugin from 'snyk-cpp-plugin';
    2 import * as dockerPlugin from 'snyk-docker-plugin';
    3 import { codePlugin } from '../plugins/sast';
    4 import { Ecosystem, EcosystemPlugin } from './types';
    5 
    6 const EcosystemPlugins: {
    7   readonly [ecosystem in Ecosystem]: EcosystemPlugin;
    8 } = {
    9   cpp: cppPlugin as EcosystemPlugin,
   10   // TODO: not any
   11   docker: dockerPlugin as any,
   12   code: codePlugin,
   13 };
   14 
   15 export function getPlugin(ecosystem: Ecosystem): EcosystemPlugin {
   16   return EcosystemPlugins[ecosystem];
   17 }