Skip to content

Commit

Permalink
NEW: Add Code Scanning Tests
Browse files Browse the repository at this point in the history
  • Loading branch information
aljawaid committed May 19, 2023
1 parent 26c8099 commit 79635e1
Show file tree
Hide file tree
Showing 13 changed files with 2,456 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
# These are supported funding model platforms

github: aljawaid
17 changes: 17 additions & 0 deletions .github/linters/.eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"env": {
"browser": true,
"commonjs": true,
"jquery": true,
"es2021": true
},
"root": true,
"extends": "eslint:recommended",
"ignorePatterns": ["clipboard-*.min.js", "**/vendor/*.js"],
"globals": {
"ClipboardJS": "readonly"
},
"rules": {
"no-undef": "warn"
}
}
31 changes: 31 additions & 0 deletions .github/linters/.htmlhintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
{
"attr-unsafe-chars": true,
"attr-lowercase": true,
"attr-no-unnecessary-whitespace": true,
"attr-value-double-quotes": true,
"attr-value-not-empty": false,
"attr-no-duplication": true,
"attr-whitespace": true,
"alt-require": true,
"doctype-first": true,
"tagname-lowercase": true,
"tagname-specialchars": true,
"tag-pair": true,
"tag-self-close": false,
"empty-tag-not-self-closed": true,
"src-not-empty": true,
"href-abs-or-rel": false,
"spec-char-escape": true,
"style-disabled": false,
"inline-style-disabled": false,
"inline-script-disabled": false,
"space-tab-mixed-disabled": "tab",
"id-class-ad-disabled": true,
"id-unique": true,
"id-class-value": "dash",
"html-lang-require": true,
"doctype-first": true,
"doctype-html5": true,
"title-require": true,
"head-script-disabled": true
}
38 changes: 38 additions & 0 deletions .github/linters/.markdownlint.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{
"MD007": {
"description": "MD007/ul-indent - Unordered list indentation",
"type": [
"boolean",
"object"
],
"default": true,
"properties": {
"indent": {
"description": "Spaces for indent",
"type": "integer",
"minimum": 1,
"default": 4
},
"start_indented": {
"description": "Whether to indent the first level of the list",
"type": "boolean",
"default": false
},
"start_indent": {
"description": "Spaces for first level indent (when start_indented is set)",
"type": "integer",
"minimum": 1,
"default": 4
}
},
"additionalProperties": false
},
"ul-indent": {
"$ref": "#/properties/MD007"
},
"MD033": false,
"MD013": false,
"MD036": false,
"MD012": false,
"MD032": false
}
79 changes: 79 additions & 0 deletions .github/linters/.stylelintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
{
"extends": "stylelint-config-standard",
"rules": {
"no-extra-semicolons": true,
"number-leading-zero": "never",
"shorthand-property-no-redundant-values": null,
"comment-whitespace-inside": [
"always",
{
"severity": "warning"
}
],
"font-family-name-quotes": "always-where-recommended",
"font-weight-notation": "named-where-possible",
"font-family-no-missing-generic-family-keyword": [
true,
{
"ignoreFontFamilies": ["FontAwesome"],
"severity": "warning"
}
],
"color-no-invalid-hex": true,
"color-hex-case": "upper",
"color-hex-length": [
"long",
{
"severity": "warning"
}
],
"alpha-value-notation": "number",
"value-list-comma-newline-after": null,
"length-zero-no-unit": true,
"no-descending-specificity": null,
"string-quotes": "double",
"selector-type-case": "lower",
"selector-class-pattern": null,
"selector-id-pattern": [
"([A-Z][a-z0-9]+)((\\d)|([A-Z0-9][a-z0-9]+))*([A-Z])?",
{
"message": "Expected CSS Selector ID pattern to be CamelCase",
"severity": "warning"
}
],
"value-list-comma-space-after": "always",
"color-function-notation": "legacy",
"number-max-precision": 5,
"value-keyword-case": [
"lower",
{
"ignoreProperties": ["/^(b|B)ackground$/", "text-rendering"]
}
],
"comment-empty-line-before": [
"always",
{
"except": ["first-nested"],
"ignore": ["after-comment"],
"severity": "warning"
}
],
"declaration-block-no-redundant-longhand-properties": [
true,
{
"severity": "warning"
}
],
"property-no-vendor-prefix": null,
"at-rule-no-vendor-prefix": null,
"value-no-vendor-prefix": null,
"declaration-no-important": [
true,
{
"message": "Try not to use !important in your declaration",
"severity": "warning"
}
],
"media-feature-range-notation": null
}
}
55 changes: 55 additions & 0 deletions .github/linters/.yaml-lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
---
###########################################
# These are the rules used for #
# linting all the yaml files in the stack #
# NOTE: #
# You can disable line with: #
# # yamllint disable-line #
###########################################
rules:
braces:
level: warning
min-spaces-inside: 0
max-spaces-inside: 0
min-spaces-inside-empty: 0
max-spaces-inside-empty: 0
brackets:
level: warning
min-spaces-inside: 0
max-spaces-inside: 0
min-spaces-inside-empty: 0
max-spaces-inside-empty: 5
colons:
level: warning
max-spaces-before: 0
max-spaces-after: 1
commas:
level: warning
max-spaces-before: 0
min-spaces-after: 1
max-spaces-after: 1
comments: disable
comments-indentation: disable
document-end: disable
document-start:
level: warning
present: true
empty-lines:
level: warning
max: 2
max-start: 0
max-end: 0
hyphens:
level: warning
max-spaces-after: 1
indentation:
level: warning
spaces: consistent
indent-sequences: true
check-multi-line-strings: false
key-duplicates: enable
line-length: disable
new-line-at-end-of-file: enable
new-lines:
type: unix
trailing-spaces: {}
Loading

0 comments on commit 79635e1

Please sign in to comment.