UNPKG

dclint

Version:

A command-line tool for validating and enforcing best practices in Docker Compose files.

27 lines (26 loc) 921 B
import type { LintContext } from '../linter/linter.types'; import type { Rule, RuleCategory, RuleSeverity, RuleType, RuleMeta, RuleMessage } from './rules.types'; export interface RequireQuotesInPortsRuleInputOptions { quoteType?: 'single' | 'double'; } interface RequireQuotesInPortsRuleOptions { quoteType: 'single' | 'double'; portsSections: string[]; } export default class RequireQuotesInPortsRule implements Rule { static readonly name = "require-quotes-in-ports"; get name(): string; type: RuleType; category: RuleCategory; severity: RuleSeverity; meta: RuleMeta; fixable: boolean; options: RequireQuotesInPortsRuleOptions; constructor(options?: RequireQuotesInPortsRuleInputOptions); getMessage(): string; private getQuoteType; private static extractValues; check(context: LintContext): RuleMessage[]; fix(content: string): string; } export {};