-
Notifications
You must be signed in to change notification settings - Fork 582
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: (experimental) shoiw pinning remediation advice for Python
- Loading branch information
Showing
14 changed files
with
1,234 additions
and
68 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import request = require('./request'); | ||
import snyk = require('.'); // TODO(kyegupov): fix import | ||
import * as config from './config'; | ||
|
||
interface OrgFeatureFlagResponse { | ||
ok: boolean; | ||
userMessage?: string; | ||
} | ||
|
||
export async function isFeatureFlagSupportedForOrg(featureFlag: string): Promise<OrgFeatureFlagResponse> { | ||
const response = await request({ | ||
method: 'GET', | ||
headers: { | ||
Authorization: `token ${snyk.api}`, | ||
}, | ||
url: `${config.API}/cli-config/feature-flags/${featureFlag}`, | ||
gzip: true, | ||
json: true, | ||
}); | ||
|
||
return (response as any).body; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.