@abaplint/cli 2.113.201 → 2.113.202
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/cli.js +62 -3
- package/package.json +2 -2
package/build/cli.js
CHANGED
|
@@ -55001,7 +55001,7 @@ class Registry {
|
|
|
55001
55001
|
}
|
|
55002
55002
|
static abaplintVersion() {
|
|
55003
55003
|
// magic, see build script "version.sh"
|
|
55004
|
-
return "2.113.
|
|
55004
|
+
return "2.113.202";
|
|
55005
55005
|
}
|
|
55006
55006
|
getDDICReferences() {
|
|
55007
55007
|
return this.ddicReferences;
|
|
@@ -57705,6 +57705,7 @@ class CheckCommentsConf extends _basic_rule_config_1.BasicRuleConfig {
|
|
|
57705
57705
|
super(...arguments);
|
|
57706
57706
|
/** Allows the use of end-of-line comments. */
|
|
57707
57707
|
this.allowEndOfLine = false;
|
|
57708
|
+
this.maxIssuesPerFile = 10;
|
|
57708
57709
|
}
|
|
57709
57710
|
}
|
|
57710
57711
|
exports.CheckCommentsConf = CheckCommentsConf;
|
|
@@ -57750,6 +57751,10 @@ https://github.com/SAP/styleguides/blob/main/clean-abap/CleanABAP.md#put-comment
|
|
|
57750
57751
|
if (this.conf.allowEndOfLine === true) {
|
|
57751
57752
|
return [];
|
|
57752
57753
|
}
|
|
57754
|
+
let max = this.getConfig().maxIssuesPerFile;
|
|
57755
|
+
if (max === undefined || max < 1) {
|
|
57756
|
+
max = 10;
|
|
57757
|
+
}
|
|
57753
57758
|
const commentRows = [];
|
|
57754
57759
|
for (let i = 0; i < rows.length; i++) {
|
|
57755
57760
|
const row = rows[i];
|
|
@@ -57766,6 +57771,9 @@ https://github.com/SAP/styleguides/blob/main/clean-abap/CleanABAP.md#put-comment
|
|
|
57766
57771
|
continue;
|
|
57767
57772
|
}
|
|
57768
57773
|
issues.push(issue_1.Issue.atStatement(file, statement, this.getDescription(IssueType.EndOfLine), this.getMetadata().key, this.conf.severity));
|
|
57774
|
+
if (issues.length >= max) {
|
|
57775
|
+
break;
|
|
57776
|
+
}
|
|
57769
57777
|
}
|
|
57770
57778
|
}
|
|
57771
57779
|
return issues;
|
|
@@ -66026,6 +66034,7 @@ class IndentationConf extends _basic_rule_config_1.BasicRuleConfig {
|
|
|
66026
66034
|
this.globalClassSkipFirst = false;
|
|
66027
66035
|
this.ignoreGlobalClassDefinition = false;
|
|
66028
66036
|
this.ignoreGlobalInterface = false;
|
|
66037
|
+
this.maxIssuesPerFile = 10;
|
|
66029
66038
|
}
|
|
66030
66039
|
}
|
|
66031
66040
|
exports.IndentationConf = IndentationConf;
|
|
@@ -66068,7 +66077,10 @@ ENDCLASS.`,
|
|
|
66068
66077
|
}
|
|
66069
66078
|
runParsed(file, obj) {
|
|
66070
66079
|
var _a, _b;
|
|
66071
|
-
|
|
66080
|
+
let max = this.getConfig().maxIssuesPerFile;
|
|
66081
|
+
if (max === undefined || max < 1) {
|
|
66082
|
+
max = 10;
|
|
66083
|
+
}
|
|
66072
66084
|
let skip = false;
|
|
66073
66085
|
if (file.getStructure() === undefined) {
|
|
66074
66086
|
return []; // syntax error in file
|
|
@@ -66140,7 +66152,7 @@ ENDCLASS.`,
|
|
|
66140
66152
|
const message = "Indentation problem, expected " + expected + " spaces";
|
|
66141
66153
|
const issue = issue_1.Issue.atPosition(file, position, message, this.getMetadata().key, this.conf.severity, fix);
|
|
66142
66154
|
ret.push(issue);
|
|
66143
|
-
if (ret.length >=
|
|
66155
|
+
if (ret.length >= max) {
|
|
66144
66156
|
break;
|
|
66145
66157
|
}
|
|
66146
66158
|
}
|
|
@@ -66810,6 +66822,7 @@ class KeywordCaseConf extends _basic_rule_config_1.BasicRuleConfig {
|
|
|
66810
66822
|
this.ignoreGlobalClassBoundaries = false;
|
|
66811
66823
|
/** A list of keywords to be ignored */
|
|
66812
66824
|
this.ignoreKeywords = [];
|
|
66825
|
+
this.maxIssuesPerFile = 10;
|
|
66813
66826
|
}
|
|
66814
66827
|
}
|
|
66815
66828
|
exports.KeywordCaseConf = KeywordCaseConf;
|
|
@@ -66920,6 +66933,10 @@ class KeywordCase extends _abap_rule_1.ABAPRule {
|
|
|
66920
66933
|
return [];
|
|
66921
66934
|
}
|
|
66922
66935
|
}
|
|
66936
|
+
let max = this.getConfig().maxIssuesPerFile;
|
|
66937
|
+
if (max === undefined || max < 1) {
|
|
66938
|
+
max = 10;
|
|
66939
|
+
}
|
|
66923
66940
|
const skip = new Skip(this.getConfig());
|
|
66924
66941
|
let prev = undefined;
|
|
66925
66942
|
for (const statement of file.getStatements()) {
|
|
@@ -66942,6 +66959,9 @@ class KeywordCase extends _abap_rule_1.ABAPRule {
|
|
|
66942
66959
|
}
|
|
66943
66960
|
prev = result[0].token;
|
|
66944
66961
|
}
|
|
66962
|
+
if (issues.length >= max) {
|
|
66963
|
+
break;
|
|
66964
|
+
}
|
|
66945
66965
|
}
|
|
66946
66966
|
return issues;
|
|
66947
66967
|
}
|
|
@@ -67209,6 +67229,7 @@ class LineLengthConf extends _basic_rule_config_1.BasicRuleConfig {
|
|
|
67209
67229
|
super(...arguments);
|
|
67210
67230
|
/** Maximum line length in characters, trailing whitespace ignored */
|
|
67211
67231
|
this.length = 120;
|
|
67232
|
+
this.maxIssuesPerFile = 10;
|
|
67212
67233
|
}
|
|
67213
67234
|
}
|
|
67214
67235
|
exports.LineLengthConf = LineLengthConf;
|
|
@@ -67237,6 +67258,10 @@ https://docs.abapopenchecks.org/checks/04/`,
|
|
|
67237
67258
|
const issues = [];
|
|
67238
67259
|
// maximum line length in abap files
|
|
67239
67260
|
const maxLineLength = 255;
|
|
67261
|
+
let max = this.getConfig().maxIssuesPerFile;
|
|
67262
|
+
if (max === undefined || max < 1) {
|
|
67263
|
+
max = 10;
|
|
67264
|
+
}
|
|
67240
67265
|
const array = file.getRawRows();
|
|
67241
67266
|
for (let rowIndex = 0; rowIndex < array.length; rowIndex++) {
|
|
67242
67267
|
const row = array[rowIndex].replace("\r", "");
|
|
@@ -67248,6 +67273,9 @@ https://docs.abapopenchecks.org/checks/04/`,
|
|
|
67248
67273
|
const message = `Reduce line length to max ${this.conf.length}, currently ${row.length}`;
|
|
67249
67274
|
issues.push(issue_1.Issue.atRow(file, rowIndex + 1, message, this.getMetadata().key, this.conf.severity));
|
|
67250
67275
|
}
|
|
67276
|
+
if (issues.length >= max) {
|
|
67277
|
+
break;
|
|
67278
|
+
}
|
|
67251
67279
|
}
|
|
67252
67280
|
return issues;
|
|
67253
67281
|
}
|
|
@@ -69692,6 +69720,7 @@ class NoPrefixesConf extends _basic_rule_config_1.BasicRuleConfig {
|
|
|
69692
69720
|
/** importing, exporting, returning and changing parameters, case insensitive regex */
|
|
69693
69721
|
this.methodParameters = "^[ICER].?_";
|
|
69694
69722
|
this.allowIsPrefixBoolean = true;
|
|
69723
|
+
this.maxIssuesPerFile = 10;
|
|
69695
69724
|
// todo, public localClass: string = "";
|
|
69696
69725
|
// todo, public localInterface: string = "";
|
|
69697
69726
|
// todo, public functionModuleParameters: string = "";
|
|
@@ -69738,21 +69767,40 @@ https://github.com/SAP/styleguides/blob/main/clean-abap/sub-sections/AvoidEncodi
|
|
|
69738
69767
|
// syntax error, skip
|
|
69739
69768
|
return [];
|
|
69740
69769
|
}
|
|
69770
|
+
let max = config.maxIssuesPerFile;
|
|
69771
|
+
if (max === undefined || max < 1) {
|
|
69772
|
+
max = 10;
|
|
69773
|
+
}
|
|
69741
69774
|
if (config.data !== undefined && config.data !== "") {
|
|
69742
69775
|
ret.push(...this.checkData(structure, new RegExp(config.data, "i"), file));
|
|
69743
69776
|
}
|
|
69777
|
+
if (ret.length >= max) {
|
|
69778
|
+
return ret;
|
|
69779
|
+
}
|
|
69744
69780
|
if (config.statics !== undefined && config.statics !== "") {
|
|
69745
69781
|
ret.push(...this.checkStatics(structure, new RegExp(config.statics, "i"), file));
|
|
69746
69782
|
}
|
|
69783
|
+
if (ret.length >= max) {
|
|
69784
|
+
return ret;
|
|
69785
|
+
}
|
|
69747
69786
|
if (config.fieldSymbols !== undefined && config.fieldSymbols !== "") {
|
|
69748
69787
|
ret.push(...this.checkFieldSymbols(structure, new RegExp(config.fieldSymbols, "i"), file));
|
|
69749
69788
|
}
|
|
69789
|
+
if (ret.length >= max) {
|
|
69790
|
+
return ret;
|
|
69791
|
+
}
|
|
69750
69792
|
if (config.constants !== undefined && config.constants !== "") {
|
|
69751
69793
|
ret.push(...this.checkConstants(structure, new RegExp(config.constants, "i"), file));
|
|
69752
69794
|
}
|
|
69795
|
+
if (ret.length >= max) {
|
|
69796
|
+
return ret;
|
|
69797
|
+
}
|
|
69753
69798
|
if (config.types !== undefined && config.types !== "") {
|
|
69754
69799
|
ret.push(...this.checkTypes(structure, new RegExp(config.types, "i"), file));
|
|
69755
69800
|
}
|
|
69801
|
+
if (ret.length >= max) {
|
|
69802
|
+
return ret;
|
|
69803
|
+
}
|
|
69756
69804
|
if (config.methodParameters !== undefined && config.methodParameters !== "") {
|
|
69757
69805
|
ret.push(...this.checkMethodParameters(structure, new RegExp(config.methodParameters, "i"), file));
|
|
69758
69806
|
}
|
|
@@ -75678,6 +75726,10 @@ const _irule_1 = __webpack_require__(/*! ./_irule */ "./node_modules/@abaplint/c
|
|
|
75678
75726
|
const edit_helper_1 = __webpack_require__(/*! ../edit_helper */ "./node_modules/@abaplint/core/build/src/edit_helper.js");
|
|
75679
75727
|
const _statement_1 = __webpack_require__(/*! ../abap/2_statements/statements/_statement */ "./node_modules/@abaplint/core/build/src/abap/2_statements/statements/_statement.js");
|
|
75680
75728
|
class UnnecessaryChainingConf extends _basic_rule_config_1.BasicRuleConfig {
|
|
75729
|
+
constructor() {
|
|
75730
|
+
super(...arguments);
|
|
75731
|
+
this.maxIssuesPerFile = 10;
|
|
75732
|
+
}
|
|
75681
75733
|
}
|
|
75682
75734
|
exports.UnnecessaryChainingConf = UnnecessaryChainingConf;
|
|
75683
75735
|
class UnnecessaryChaining extends _abap_rule_1.ABAPRule {
|
|
@@ -75704,6 +75756,10 @@ class UnnecessaryChaining extends _abap_rule_1.ABAPRule {
|
|
|
75704
75756
|
}
|
|
75705
75757
|
runParsed(file) {
|
|
75706
75758
|
const issues = [];
|
|
75759
|
+
let max = this.getConfig().maxIssuesPerFile;
|
|
75760
|
+
if (max === undefined || max < 1) {
|
|
75761
|
+
max = 10;
|
|
75762
|
+
}
|
|
75707
75763
|
const statements = file.getStatements();
|
|
75708
75764
|
for (let i = 0; i < statements.length; i++) {
|
|
75709
75765
|
const colon = statements[i].getColon();
|
|
@@ -75734,6 +75790,9 @@ class UnnecessaryChaining extends _abap_rule_1.ABAPRule {
|
|
|
75734
75790
|
const message = "Unnecessary chaining";
|
|
75735
75791
|
const issue = issue_1.Issue.atToken(file, colon, message, this.getMetadata().key, this.conf.severity, fix);
|
|
75736
75792
|
issues.push(issue);
|
|
75793
|
+
if (issues.length >= max) {
|
|
75794
|
+
break;
|
|
75795
|
+
}
|
|
75737
75796
|
}
|
|
75738
75797
|
return issues;
|
|
75739
75798
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@abaplint/cli",
|
|
3
|
-
"version": "2.113.
|
|
3
|
+
"version": "2.113.202",
|
|
4
4
|
"description": "abaplint - Command Line Interface",
|
|
5
5
|
"funding": "https://github.com/sponsors/larshp",
|
|
6
6
|
"bin": {
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
},
|
|
39
39
|
"homepage": "https://abaplint.org",
|
|
40
40
|
"devDependencies": {
|
|
41
|
-
"@abaplint/core": "^2.113.
|
|
41
|
+
"@abaplint/core": "^2.113.202",
|
|
42
42
|
"@types/chai": "^4.3.20",
|
|
43
43
|
"@types/minimist": "^1.2.5",
|
|
44
44
|
"@types/mocha": "^10.0.10",
|