@secretlint/types
Advanced tools
Comparing version 0.2.0 to 0.4.0
@@ -6,2 +6,24 @@ # Change Log | ||
# [0.4.0](https://github.com/secretlint/secretlint/compare/v0.3.0...v0.4.0) (2020-02-28) | ||
### Features | ||
* **core:** support "disabled" options ([17c1391](https://github.com/secretlint/secretlint/commit/17c1391cbd19edfe72f894fcf2e3a9d50fc4a7d2)) | ||
* **core:** support "disabledMessages" options ([17de33e](https://github.com/secretlint/secretlint/commit/17de33eaef2408c63cbaeecb4038c8878a292ca0)) | ||
* **core:** support Context#ignore method ([7ca0445](https://github.com/secretlint/secretlint/commit/7ca0445e9a5c494ea52ab0b9efa302ef5c902e2f)) | ||
* **types:** rule require `messages` ([412803e](https://github.com/secretlint/secretlint/commit/412803eeebe7f14ce67f1c33c2ba16eac2acf9a5)) | ||
# [0.3.0](https://github.com/secretlint/secretlint/compare/v0.2.0...v0.3.0) (2020-02-27) | ||
**Note:** Version bump only for package @secretlint/types | ||
# [0.2.0](https://github.com/secretlint/secretlint/compare/v0.1.2...v0.2.0) (2020-02-23) | ||
@@ -8,0 +30,0 @@ |
@@ -1,2 +0,2 @@ | ||
export { SecretLintCoreIgnoreDescriptor, SecretLintCoreReportDescriptor, SecretLintCoreResult, SecretLintCoreResultMessage, SecretLintCoreDescriptor, SecretLintUnionRuleCreator, SecretLintCoreDescriptorUnionRule, SecretLintCoreDescriptorRule, SecretLintCoreDescriptorRulePreset } from "./SecretLintCore"; | ||
export { SecretLintCoreIgnoreDescriptor, SecretLintCoreReportDescriptor, SecretLintCoreIgnoreMessage, SecretLintCoreResult, SecretLintCoreResultMessage, SecretLintCoreDescriptor, SecretLintUnionRuleCreator, SecretLintCoreDescriptorUnionRule, SecretLintCoreDescriptorRule, SecretLintCoreDescriptorRulePreset } from "./SecretLintCore"; | ||
export { SecretLintRuleSeverityLevel } from "./SecretLintRuleSeverityLevel"; | ||
@@ -6,4 +6,4 @@ export { SecretLintRuleIgnoreDescriptor, SecretLintRuleCreator, SecretLintRuleContext, SecretLintRuleCreatorOptions, SecretLintRuleReportDescriptor, SecretLintRuleReportHandler, SecretLintRuleContentType } from "./SecretLintRule"; | ||
export { SecretLintRawSource, SecretLintSourceIdentifierNode, SecretLintSourceNodeLocation, SecretLintSourceNodePosition, SecretLintSourceNodeRange, SecretLintSourceValueNode } from "./SecretLintSource"; | ||
export { createRuleMessageTranslator, SecretLintRuleMessageTranslate, SecretLintRuleMessageTranslatorOptions, SecretLintRuleLocaleTag, SecretLintRuleLocalizeMessageMulti, SecretLintRuleLocalizeMessages } from "./SecretLintRuleTranslator"; | ||
export { createRuleMessageTranslator, SecretLintRuleMessageTranslate, SecretLintRuleMessageTranslatorOptions, SecretLintRuleLocaleTag, SecretLintRuleLocalizeMessageMulti, SecretLintRuleLocalizeMessages, SecretLintRuleTranslatorResult } from "./SecretLintRuleTranslator"; | ||
export { SecretLintSourceCode } from "./SecretLintSourceCode"; | ||
export { SecretLintConfigDescriptor, SecretLintConfigDescriptorRule, SecretLintConfigDescriptorRulePreset } from "./SecretLintConfigDescriptor"; |
@@ -25,2 +25,7 @@ import { SecretLintRuleCreator, SecretLintRuleCreatorOptions } from "./SecretLintRule"; | ||
/** | ||
* An array of message id for suppress error report. | ||
* message id is defined in each rule. | ||
*/ | ||
allowMessages?: string[]; | ||
/** | ||
* Severity level for the rule. | ||
@@ -27,0 +32,0 @@ * Default: "error" |
@@ -30,2 +30,7 @@ import { SecretLintRuleIgnoreDescriptor, SecretLintRuleReportDescriptor, SecretLintRuleCreator, SecretLintRuleCreatorOptions } from "./SecretLintRule"; | ||
disabled?: boolean; | ||
/** | ||
* An array of message id for suppress reported message. | ||
* Message id is defined in each rule, Please see each README | ||
*/ | ||
allowMessages?: string[]; | ||
}; | ||
@@ -70,2 +75,3 @@ export declare type SecretLintCoreDescriptorRulePreset<Options = SecretLintRulePresetCreatorOptions> = { | ||
message: string; | ||
messageId: string; | ||
range: number[]; | ||
@@ -76,2 +82,13 @@ loc: SecretLintSourceNodeLocation; | ||
}; | ||
export declare type SecretLintCoreIgnoreMessage = { | ||
ruleId: string; | ||
ruleParentId?: string; | ||
/** | ||
* specific rule id or "*" | ||
*/ | ||
targetRuleId: string; | ||
message: string; | ||
range: number[]; | ||
loc: SecretLintSourceNodeLocation; | ||
}; | ||
export declare type SecretLintCoreReportDescriptor = { | ||
@@ -78,0 +95,0 @@ ruleId: string; |
import { SecretLintSourceIdentifierNode } from "./SecretLintSource"; | ||
import { createRuleMessageTranslator, SecretLintRuleTranslatorResult } from "./SecretLintRuleTranslator"; | ||
import { createRuleMessageTranslator, SecretLintRuleLocalizeMessages, SecretLintRuleTranslatorResult } from "./SecretLintRuleTranslator"; | ||
import { SecretLintSourceCode } from "./SecretLintSourceCode"; | ||
export declare type SecretLintRuleReportDescriptor = { | ||
message: string | SecretLintRuleTranslatorResult<{}>; | ||
message: SecretLintRuleTranslatorResult<{}>; | ||
range: number[]; | ||
@@ -10,5 +10,12 @@ data?: {}; | ||
export declare type SecretLintRuleIgnoreDescriptor = { | ||
message: string; | ||
message: SecretLintRuleTranslatorResult<{}>; | ||
/** | ||
* Specify target rule id is ignored. | ||
* If Set "*", match any rule id. | ||
* Examples: | ||
* { targetRuleId: "@secretlint/secretelint-rule-example" } | ||
* { targetRuleId: "*" } | ||
*/ | ||
targetRuleId: string; | ||
range: number[]; | ||
data?: {}; | ||
}; | ||
@@ -24,5 +31,6 @@ export declare type SecretLintRuleContext = { | ||
export declare type SecretLintRuleCreator<Options = SecretLintRuleCreatorOptions> = { | ||
messages: SecretLintRuleLocalizeMessages; | ||
meta: { | ||
id: string; | ||
type: "scanner"; | ||
type: "scanner" | "filter"; | ||
recommended: boolean; | ||
@@ -29,0 +37,0 @@ docs?: { |
@@ -15,2 +15,3 @@ export declare type SecretLintRuleLocaleTag = "en" | "cs" | "de" | "es" | "fr" | "it" | "ja" | "ko" | "pl" | "ru" | "tr" | "zh-CN" | "zh-TW" | string; | ||
message: string; | ||
messageId: string; | ||
data: T | undefined; | ||
@@ -17,0 +18,0 @@ }; |
{ | ||
"name": "@secretlint/types", | ||
"version": "0.2.0", | ||
"version": "0.4.0", | ||
"description": "A typing package for @secretlint", | ||
@@ -57,3 +57,3 @@ "keywords": [ | ||
}, | ||
"gitHead": "dac405de9fab0bb70ecdb3701790e6f0bad48ca3" | ||
"gitHead": "b1458e1ff9ee3d1cf7d2c8bb31879714b6751c09" | ||
} |
@@ -5,2 +5,3 @@ // Core Interface | ||
SecretLintCoreReportDescriptor, | ||
SecretLintCoreIgnoreMessage, | ||
SecretLintCoreResult, | ||
@@ -47,3 +48,4 @@ SecretLintCoreResultMessage, | ||
SecretLintRuleLocalizeMessageMulti, | ||
SecretLintRuleLocalizeMessages | ||
SecretLintRuleLocalizeMessages, | ||
SecretLintRuleTranslatorResult | ||
} from "./SecretLintRuleTranslator"; | ||
@@ -50,0 +52,0 @@ export { SecretLintSourceCode } from "./SecretLintSourceCode"; |
@@ -26,2 +26,7 @@ import { SecretLintRuleCreator, SecretLintRuleCreatorOptions } from "./SecretLintRule"; | ||
/** | ||
* An array of message id for suppress error report. | ||
* message id is defined in each rule. | ||
*/ | ||
allowMessages?: string[]; | ||
/** | ||
* Severity level for the rule. | ||
@@ -28,0 +33,0 @@ * Default: "error" |
@@ -37,2 +37,7 @@ // Core Input and Output | ||
disabled?: boolean; | ||
/** | ||
* An array of message id for suppress reported message. | ||
* Message id is defined in each rule, Please see each README | ||
*/ | ||
allowMessages?: string[]; | ||
}; | ||
@@ -82,2 +87,3 @@ export type SecretLintCoreDescriptorRulePreset<Options = SecretLintRulePresetCreatorOptions> = { | ||
message: string; | ||
messageId: string; | ||
range: number[]; | ||
@@ -88,2 +94,14 @@ loc: SecretLintSourceNodeLocation; | ||
}; | ||
export type SecretLintCoreIgnoreMessage = { | ||
ruleId: string; | ||
ruleParentId?: string; | ||
/** | ||
* specific rule id or "*" | ||
*/ | ||
targetRuleId: string; | ||
message: string; | ||
range: number[]; | ||
loc: SecretLintSourceNodeLocation; | ||
}; | ||
export type SecretLintCoreReportDescriptor = { | ||
@@ -90,0 +108,0 @@ ruleId: string; |
// Rule Interfaces | ||
import { SecretLintSourceIdentifierNode } from "./SecretLintSource"; | ||
import { createRuleMessageTranslator, SecretLintRuleTranslatorResult } from "./SecretLintRuleTranslator"; | ||
import { | ||
createRuleMessageTranslator, | ||
SecretLintRuleLocalizeMessages, | ||
SecretLintRuleTranslatorResult | ||
} from "./SecretLintRuleTranslator"; | ||
import { SecretLintSourceCode } from "./SecretLintSourceCode"; | ||
export type SecretLintRuleReportDescriptor = { | ||
message: string | SecretLintRuleTranslatorResult<{}>; | ||
message: SecretLintRuleTranslatorResult<{}>; | ||
range: number[]; | ||
@@ -12,5 +16,12 @@ data?: {}; | ||
export type SecretLintRuleIgnoreDescriptor = { | ||
message: string; | ||
message: SecretLintRuleTranslatorResult<{}>; | ||
/** | ||
* Specify target rule id is ignored. | ||
* If Set "*", match any rule id. | ||
* Examples: | ||
* { targetRuleId: "@secretlint/secretelint-rule-example" } | ||
* { targetRuleId: "*" } | ||
*/ | ||
targetRuleId: string; | ||
range: number[]; | ||
data?: {}; | ||
}; | ||
@@ -26,5 +37,6 @@ export type SecretLintRuleContext = { | ||
export type SecretLintRuleCreator<Options = SecretLintRuleCreatorOptions> = { | ||
messages: SecretLintRuleLocalizeMessages; | ||
meta: { | ||
id: string; | ||
type: "scanner"; | ||
type: "scanner" | "filter"; | ||
recommended: boolean; | ||
@@ -35,3 +47,3 @@ docs?: { | ||
// meta information for optimizing | ||
// If supportedContentTypes is only "text", secretelint does not pass a binary to this rule | ||
// If supportedContentTypes is only "text", secretlint does not pass a binary to this rule | ||
// Default: all | ||
@@ -38,0 +50,0 @@ supportedContentTypes: SecretLintRuleContentType[]; |
@@ -29,2 +29,3 @@ // TODO: add locale | ||
message: string; | ||
messageId: string; | ||
data: T | undefined; | ||
@@ -31,0 +32,0 @@ }; |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
35822
824