From 564b044c2694410ede7de2b7e2e21b86a5424a12 Mon Sep 17 00:00:00 2001 From: dbale-altoros Date: Thu, 20 Feb 2025 10:04:02 -0300 Subject: [PATCH 1/6] fix: license and md deprecated file --- LICENSE | 2 +- docs/rules/naming/contract-name-pascalcase.md | 42 ------------------- 2 files changed, 1 insertion(+), 43 deletions(-) delete mode 100644 docs/rules/naming/contract-name-pascalcase.md diff --git a/LICENSE b/LICENSE index 72f75f9f..ab545b47 100644 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,6 @@ MIT License -Copyright (c) 2017 Protofire +Copyright (c) 2017-2025 Protofire Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/docs/rules/naming/contract-name-pascalcase.md b/docs/rules/naming/contract-name-pascalcase.md deleted file mode 100644 index d5463638..00000000 --- a/docs/rules/naming/contract-name-pascalcase.md +++ /dev/null @@ -1,42 +0,0 @@ ---- -warning: "This is a dynamically generated file. Do not edit manually." -layout: "default" -title: "contract-name-pascalcase | Solhint" ---- - -# contract-name-pascalcase -![Recommended Badge](https://img.shields.io/badge/-Recommended-brightgreen) -![Category Badge](https://img.shields.io/badge/-Style%20Guide%20Rules-informational) -![Default Severity Badge warn](https://img.shields.io/badge/Default%20Severity-warn-yellow) -> The {"extends": "solhint:recommended"} property in a configuration file enables this rule. - - -## Description -Contract, Structs and Enums should be in PascalCase. - -## Options -This rule accepts a string option of rule severity. Must be one of "error", "warn", "off". Defaults to warn. - -### Example Config -```json -{ - "rules": { - "contract-name-pascalcase": "warn" - } -} -``` - -### Notes -- Solhint allows this rule to automatically fix the code with `--fix` option -- The FIX will only change first letter and remove underscores - -## Examples -This rule does not have examples. - -## Version -This rule is introduced in the latest version. - -## Resources -- [Rule source](https://github.com/protofire/solhint/blob/master/lib/rules/naming/contract-name-pascalcase.js) -- [Document source](https://github.com/protofire/solhint/blob/master/docs/rules/naming/contract-name-pascalcase.md) -- [Test cases](https://github.com/protofire/solhint/blob/master/test/rules/naming/contract-name-pascalcase.js) From 04cc3dbbf995d15ab0eff5914b9eb4f550c2e909 Mon Sep 17 00:00:00 2001 From: dbale-altoros Date: Thu, 20 Feb 2025 10:11:18 -0300 Subject: [PATCH 2/6] fix: footer date --- docs/_includes/page-footer.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/_includes/page-footer.html b/docs/_includes/page-footer.html index 4274e0e8..fdddea80 100644 --- a/docs/_includes/page-footer.html +++ b/docs/_includes/page-footer.html @@ -1,5 +1,5 @@
- ©2017-2019, Protofire + ©2017-2025, Protofire
From ac4e247a6c4f1c71b1fff3aa4babdc485b01ed02 Mon Sep 17 00:00:00 2001 From: dbale-altoros Date: Thu, 20 Feb 2025 10:19:04 -0300 Subject: [PATCH 3/6] fix: typo --- docs/rules/naming/interface-starts-with-i.md | 2 +- lib/rules/best-practices/interface-starts-with-i.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/rules/naming/interface-starts-with-i.md b/docs/rules/naming/interface-starts-with-i.md index b6bfc539..d14f4e47 100644 --- a/docs/rules/naming/interface-starts-with-i.md +++ b/docs/rules/naming/interface-starts-with-i.md @@ -35,7 +35,7 @@ interface IFoo { function foo () external; } ### 👎 Examples of **incorrect** code for this rule -#### Interface name doesnt start with I +#### Interface name doesn't start with I ```solidity interface Foo { function foo () external; } diff --git a/lib/rules/best-practices/interface-starts-with-i.js b/lib/rules/best-practices/interface-starts-with-i.js index f47db110..4bafece8 100644 --- a/lib/rules/best-practices/interface-starts-with-i.js +++ b/lib/rules/best-practices/interface-starts-with-i.js @@ -15,7 +15,7 @@ const meta = { ], bad: [ { - description: 'Interface name doesnt start with I', + description: `Interface name doesn't start with I`, code: `interface Foo { function foo () external; }`, }, ], From 3536edea77f27250b3f75d769821448847517b53 Mon Sep 17 00:00:00 2001 From: dbale-altoros Date: Thu, 20 Feb 2025 10:21:00 -0300 Subject: [PATCH 4/6] fix: typo2 --- test/rules/gas-consumption/gas-length-in-loops.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/rules/gas-consumption/gas-length-in-loops.js b/test/rules/gas-consumption/gas-length-in-loops.js index 37fe451f..a825014a 100644 --- a/test/rules/gas-consumption/gas-length-in-loops.js +++ b/test/rules/gas-consumption/gas-length-in-loops.js @@ -8,7 +8,7 @@ const ERROR_MSG = describe('Linter - gas-length-in-loops', () => { it('should raise error on ForLoop with .length in condition', () => { const code = funcWith(` - for (uint256 length = 0; length > object.length; legnth++) { + for (uint256 length = 0; length > object.length; length++) { // code block to be executed }`) From cc94a22979c88e66e4aded8b3e21e056d163fd0f Mon Sep 17 00:00:00 2001 From: dbale-altoros Date: Thu, 20 Feb 2025 11:01:52 -0300 Subject: [PATCH 5/6] fix: unused package --- e2e/package.json | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/e2e/package.json b/e2e/package.json index 41185fa2..30d7f7ff 100644 --- a/e2e/package.json +++ b/e2e/package.json @@ -9,8 +9,7 @@ "author": "", "license": "MIT", "devDependencies": { - "chai": "^4.3.7", - "chai-spies": "^1.0.0", + "chai": "^4.3.7", "fs-extra": "^11.1.0", "get-stream": "^6.0.0", "mocha": "^10.2.0", From c19f84875e4842c66b18c4bb803b53f3b7c524d7 Mon Sep 17 00:00:00 2001 From: dbale-altoros Date: Thu, 20 Feb 2025 14:54:32 -0300 Subject: [PATCH 6/6] removed roadmap link on readme --- README.md | 1 - 1 file changed, 1 deletion(-) diff --git a/README.md b/README.md index e6b341f0..d6fb422e 100644 --- a/README.md +++ b/README.md @@ -238,7 +238,6 @@ Related documentation you may find [here](https://protofire.github.io/solhint/). ## Table of Contents -* [Roadmap](ROADMAP.md): The core project's roadmap - what the core team is looking to work on in the near future. * [Contributing](docs/contributing.md): The core Solhint team :heart: contributions. This describes how you can contribute to the Solhint Project. * [Shareable configs](docs/shareable-configs.md): How to create and share your own configurations. * [Writing plugins](docs/writing-plugins.md): How to extend Solhint with your own rules.