@zohodesk/codestandard-analytics
Advanced tools
Comparing version 0.0.1-exp-17 to 0.0.1-exp-18
@@ -115,3 +115,3 @@ "use strict"; | ||
* @param {path} branchDiffPath - path of branch diff json | ||
* @returns {{JsFiles:[],featureFiles:[],branch_diff_json:[]}} | ||
* @returns {{JsFiles:[],cssFiles:[],featureFiles:[],branch_diff_json:[]}} | ||
*/ | ||
@@ -165,3 +165,3 @@ | ||
} | ||
if (currentFile.includes('.js') && (0, _fileUtils.checkIfFileExists)(currentFile)) { | ||
if (currentFile.includes('.js') || currentFile.includes('.ts') || currentFile.includes('.tsx') || currentFile.includes('.jsx') && (0, _fileUtils.checkIfFileExists)(currentFile)) { | ||
files.JsFiles.push(currentFile); | ||
@@ -168,0 +168,0 @@ } |
@@ -22,2 +22,3 @@ "use strict"; | ||
var _fileUtils = require("../../utils/fileUtils"); | ||
var _hash = require("../../utils/hash"); | ||
/** | ||
@@ -93,10 +94,7 @@ * @function getSonarHostUrl - get sonar host url from property file | ||
const sonar_scanner_path = (0, _rootPath.getSonarJarPath)(); | ||
const { | ||
Dlogin, | ||
Dpassword | ||
} = getCredentials(); | ||
const metric_token = getCredentials(); | ||
var project_name = getProjectName(cliObjects); | ||
var resultFilesPath = featureFiles; | ||
var source_directories = JsFiles; | ||
const command = ["-jar", sonar_scanner_path, `-Dsonar.host.url=${sonarqube_host_url}`, `-Dsonar.projectKey=${project_name}`, `-Dsonar.login=${Dlogin}`, `-Dsonar.password=${Dpassword}`, `-Dsonar.sources=${source_directories}`, `-Dsonar.tests=${resultFilesPath}`, "-Dsonar.language=js", `-Dsonar.working.directory=${getSonarArtifactsDir()}`, `-Dsonar.eslint.reportPaths=${(0, _getFileUtils.getLintReportPath)()}`, "-Dsonar.javascript.lcov.reportPaths=coverage/lcov-report/lcov.info"]; | ||
const command = ["-jar", sonar_scanner_path, `-Dsonar.host.url=${sonarqube_host_url}`, `-Dsonar.projectKey=${project_name}`, `-Dsonar.login=${metric_token}`, `-Dsonar.sources=${source_directories}`, `-Dsonar.tests=${resultFilesPath}`, "-Dsonar.language=js", `-Dsonar.working.directory=${getSonarArtifactsDir()}`, `-Dsonar.eslint.reportPaths=${(0, _getFileUtils.getLintReportPath)()}`, "-Dsonar.javascript.lcov.reportPaths=coverage/lcov-report/lcov.info"]; | ||
return command; | ||
@@ -168,9 +166,5 @@ } | ||
const { | ||
loginName, | ||
password | ||
metric_token | ||
} = (0, _fileUtils.getLintConfiguration)(); | ||
return { | ||
Dlogin: loginName, | ||
Dpassword: password | ||
}; | ||
return (0, _hash.decrypt)(metric_token, 7); | ||
} | ||
@@ -177,0 +171,0 @@ |
@@ -23,4 +23,3 @@ const path = require("path"); | ||
sonar_hostURL: "https://client-linters.zohodesk.csez.zohocorpin.com", | ||
loginName: "developer", | ||
password: "developer", | ||
metric_token: "zxh_9737850jh2l53ml17223929ihii73072j54j2260", | ||
branchDiffPath:path.resolve(process.cwd(),"diffBranch.json"), | ||
@@ -27,0 +26,0 @@ gitEndPoint:"https://zgit.csez.zohocorpin.com", |
@@ -143,3 +143,3 @@ "use strict"; | ||
const defaultLintConfPath = _path.default.resolve(__dirname, "..", "setup", "sampleLint.config.js"); | ||
return checkIfFileExists(actualLintConfPath) ? require(actualLintConfPath) : require(defaultLintConfPath); | ||
return checkIfFileExists(actualLintConfPath) && JSON.stringify(require(actualLintConfPath)) === JSON.stringify(require(defaultLintConfPath)) ? require(actualLintConfPath) : require(defaultLintConfPath); | ||
} | ||
@@ -146,0 +146,0 @@ /** |
{ | ||
"name": "@zohodesk/codestandard-analytics", | ||
"version": "0.0.1-exp-17", | ||
"version": "0.0.1-exp-18", | ||
"description": "linting tool", | ||
"dependencies": { | ||
"@babel/runtime": "^7.25.6", | ||
"eslint": "8.57.0" | ||
}, | ||
"devDependencies": { | ||
"@babel/runtime": "^7.25.6", | ||
"@babel/core": "7.24.3", | ||
@@ -11,0 +11,0 @@ "@babel/plugin-transform-runtime": "7.24.7", |
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
729750
1
7
2053
17
- Removed@babel/runtime@^7.25.6
- Removed@babel/runtime@7.26.0(transitive)
- Removedregenerator-runtime@0.14.1(transitive)