Skip to content

Commit

Permalink
fixed megalinter reported issues
Browse files Browse the repository at this point in the history
  • Loading branch information
fchastanet committed Dec 7, 2023
1 parent 69d616f commit 9d65325
Show file tree
Hide file tree
Showing 13 changed files with 88 additions and 8 deletions.
2 changes: 2 additions & 0 deletions .checkov.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
skip-path:
- vendor
15 changes: 14 additions & 1 deletion .cspell.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,19 +27,32 @@
"words": ["megalinter", "oxsecurity"],
"dictionaryDefinitions": [
{"name": "bashCustom", "path": ".cspell/bash.txt"},
{"name": "loremIpsum", "path": ".cspell/loremIpsum.txt"},
{"name": "config", "path": ".cspell/config.txt"},
{"name": "softwares", "path": ".cspell/softwares.txt"},
{"name": "readme", "path": ".cspell/readme.txt"},
{"name": "dirColors", "path": ".cspell/dirColors.txt"},
{"name": "plantUml", "path": ".cspell/plantUml.txt"}
],
"dictionaries": ["bash", "bashCustom", "config", "softwares", "plantUml"],
"dictionaries": [
"bash",
"bashCustom",
"config",
"softwares",
"plantUml",
"loremIpsum"
],
"languageSettings": [
{
"languageId": "dirColors",
"locale": "*",
"dictionaries": ["dirColors"]
},
{
"languageId": "loremIpsum",
"locale": "*",
"dictionaries": ["loremIpsum"]
},
{
"languageId": "bashCustom",
"locale": "*",
Expand Down
4 changes: 4 additions & 0 deletions .cspell/bash.txt
Original file line number Diff line number Diff line change
Expand Up @@ -118,3 +118,7 @@ ppassword
DELIMS
Facadesh
Scriptsh
noargs
exitcode
Datash
installsh
40 changes: 40 additions & 0 deletions .cspell/loremIpsum.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
Lorem
ipsum
dolor
sit
amet
consectetur
adipiscing
elit
Maecenas
vel
eros
id
ipsum
lobortis
cursus
id
dignissim
turpis
Nam
pretium
placerat
nulla
in
posuere
Mauris
libero
purus
aliquet
et
commodo
quis
semper
sit
amet
sapien
Curabitur
condimentum
finibus
abitur
fini
1 change: 1 addition & 0 deletions .github/workflows/docsify-gh-pages.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
---
# kics-scan disable=555ab8f9-2001-455e-a077-f2d0f41e2fb9
# build and deploy Docsify site to GitHub Pages
name: Deploy Docsify

Expand Down
1 change: 1 addition & 0 deletions .github/workflows/lint-test.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
---
# kics-scan disable=555ab8f9-2001-455e-a077-f2d0f41e2fb9
# Lint the code base and launch unit test at each push or pull request
name: Lint and test
on: # yamllint disable-line rule:truthy
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/precommit-autoupdate.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
---
# kics-scan disable=555ab8f9-2001-455e-a077-f2d0f41e2fb9
# Check if precommit packages need to be updated and create PR if this is the case
name: Pre-commit auto-update
on:
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/set-github-status-on-pr-approved.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
---
# kics-scan disable=555ab8f9-2001-455e-a077-f2d0f41e2fb9
# set git commit status when PR is approved
name: Set PR approved git status
on:
Expand Down
15 changes: 15 additions & 0 deletions .lycheeignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
http://localhost*
file://pages/Commands.md
s3://s3server/exports
https://github.com/sharkdp/fd/releases/download/v@version@/fd_@version@_amd64.deb*
https://github.com/sharkdp/bat/releases/download/v@version@/bat_@version@_amd64.deb*
https://github.com/koalaman/shellcheck/releases/download/v@version@/shellcheck-v@[email protected]_64.tar.xz*
https://github.com/hadolint/hadolint/releases/download/v@version@/hadolint-Linux-x86_64*
https://github.com/kubernetes-sigs/kind/releases/download/v@version@/kind-linux-amd64*
https://github.com/Blacksmoke16/oq/releases/download/v@version@/oq-v@version@-/*
https://github.com/kubernetes/minikube/releases/download/v@version@/minikube-linux-amd64*
https://github.com/docker/compose/releases/download/v@version@/docker-compose*
https://github.com/plantuml/plantuml/releases/download/v@version@/plantuml-@[email protected]*
https://github.com/docker/docker-credential-helpers/releases/download/v@version@/docker-credential-wincred-v@[email protected]*
https://github.com/Versent/saml2aws/releases/download/v@version@/saml2aws_@version@_linux_amd64.tar.gz
https://github.com/fchastanet/bash-tools/tree/master/src/_binaries*
8 changes: 2 additions & 6 deletions .mega-linter.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
# Configuration file for MegaLinter
# See all available variables at https://oxsecurity.github.io/megalinter/configuration/ and in linters documentation
# See all available variables at https://megalinter.io/latest/configuration/ and in linters documentation

APPLY_FIXES: all # all, none, or list of linter keys
# ENABLE: # If you use ENABLE variable, all other languages/formats/tooling-formats will be disabled by default
Expand Down Expand Up @@ -95,11 +95,7 @@ JAVASCRIPT_DEFAULT_STYLE: prettier
JAVASCRIPT_ES_CONFIG_FILE: .eslintrc.js
JAVASCRIPT_ES_FILTER_REGEX_EXCLUDE: (report/)

JSON_JSONLINT_FILTER_REGEX_EXCLUDE: |
(?x)(
^\.vscode/(settings|launch)\.json|
^conf/\.vscode/settings\.json
)
JSON_JSONLINT_FILTER_REGEX_EXCLUDE: (.vscode/)

MARKDOWN_MARKDOWN_LINK_CHECK_FILTER_REGEX_EXCLUDE: (report)

Expand Down
2 changes: 2 additions & 0 deletions kics.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
exclude-paths:
- "vendor/"
1 change: 0 additions & 1 deletion src/_binaries/DbImport/dbImport.bats
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,6 @@ function Database::dbImport::remote_db_fully_functional_from_mysql { #@test
export BASH_FRAMEWORK_ENV_FILEPATH="${BATS_TEST_DIRNAME}/testsData/.env"

run "${binDir}/dbImport" --verbose -f default.local fromDb toDb 2>&1
unstub_all
assert_output --partial "Import database duration : "
assert_output --partial "begin insert emptyTable"
assert_output --partial "begin insert dataTable"
Expand Down
5 changes: 5 additions & 0 deletions trivy.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
scan:
# Same as '--skip-dirs'
# Default is empty
skip-dirs:
- vendor/

0 comments on commit 9d65325

Please sign in to comment.