【问题标题】:scss - lint exclusions in yml not being excludedscss - 不排除 yml 中的 lint 排除项
【发布时间】:2014-08-06 13:26:31
【问题描述】:

我正在运行类似 scss-lint app/assets/stylesheets/**/*.css.scss --config=config/scss_lint.yml 的 linter,配置如下:

exclude:
 - app/assets/stylesheets/libraries/reset.css.scss
 - app/assets/stylesheets/libraries/foundation.css.scss

linters:
  BorderZero:
    enabled: true

  CapitalizationInSelector:
    enabled: true

  ColorKeyword:
    enabled: true

  Comment:
    enabled: true

  DebugStatement:
    enabled: true

  DeclarationOrder:
    enabled: false

  DuplicateProperty:
    enabled: true

  ElsePlacement:
    enabled: true
    style: same_line # or 'new_line'

  EmptyLineBetweenBlocks:
    enabled: true
    ignore_single_line_blocks: true

  EmptyRule:
    enabled: true

  FinalNewline:
    enabled: true
    present: true

  HexLength:
    enabled: true
    style: short # or 'long'

  HexNotation:
    enabled: true
    style: lowercase # or 'uppercase'

  HexValidation:
    enabled: true

  IdWithExtraneousSelector:
    enabled: true

  Indentation:
    enabled: true
    character: space # or 'tab'
    width: 2

  LeadingZero:
    enabled: true
    style: exclude_zero # or 'include_zero'

  MergeableSelector:
    enabled: true
    force_nesting: true

  NameFormat:
    enabled: true
    convention: hyphenated_lowercase # or 'BEM', or a regex pattern

  PlaceholderInExtend:
    enabled: true

  PropertySortOrder:
    enabled: false
    ignore_unspecified: false

  PropertySpelling:
    enabled: true
    extra_properties: []

  SelectorDepth:
    enabled: true
    max_depth: 5

  Shorthand:
    enabled: true

  SingleLinePerProperty:
    enabled: true
    allow_single_line_rule_sets: true

  SingleLinePerSelector:
    enabled: true

  SpaceAfterComma:
    enabled: true

  SpaceAfterPropertyColon:
    enabled: true
    style: one_space # or 'no_space', or 'at_least_one_space', or 'aligned'

  SpaceAfterPropertyName:
    enabled: true

  SpaceBeforeBrace:
    enabled: true
    allow_single_line_padding: false

  SpaceBetweenParens:
    enabled: true
    spaces: 0

  StringQuotes:
    enabled: true
    style: single_quotes # or double_quotes

  TrailingSemicolon:
    enabled: true

  UnnecessaryMantissa:
    enabled: true

  UnnecessaryParentReference:
    enabled: true

  UrlFormat:
    enabled: true

  UrlQuotes:
    enabled: true

  ZeroUnit:
    enabled: true

  Compass::*:
    enabled: false

无论我如何构造排除我都不能忽略app/assets/stylesheets/libraries/reset.css.scss中的文件

想法? scss-lint

【问题讨论】:

    标签: ruby-on-rails ruby sass lint


    【解决方案1】:

    我运行排除的路径错误,以及我在 yml 文件中设置它们的方式。

    exclude:
     - '../app/assets/stylesheets/libraries/reset.css.scss'
     - '../app/assets/stylesheets/libraries/foundation.css.scss'
    

    【讨论】:

      猜你喜欢
      • 2017-02-20
      • 1970-01-01
      • 2019-05-26
      • 1970-01-01
      • 1970-01-01
      • 2013-01-19
      • 2017-12-14
      • 2018-07-26
      • 1970-01-01
      相关资源
      最近更新 更多