diff --git a/.gitignore b/.gitignore index 153ddeb..b52cbe9 100644 --- a/.gitignore +++ b/.gitignore @@ -13,3 +13,4 @@ libs/ metric_monitor/datadir private_net/datadir tron-docker.iml +bin/ diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 05fc6fe..bcfcac3 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -13,13 +13,10 @@ repos: - repo: 'https://github.com/jumanjihouse/pre-commit-hooks' rev: 3.0.0 hooks: + - id: shellcheck - id: script-must-have-extension - id: git-dirty - id: git-check - - repo: 'https://github.com/koalaman/shellcheck-precommit' - rev: v0.7.2 - hooks: - - id: shellcheck - repo: local # check java files format use a customized script hooks: - id: checkstyle diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 333339c..434f4c6 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -3,15 +3,22 @@ tron-docker is an open-source project designed to facilitate the usage of the TRON network. We understand that there is much left to be desired, and if you see any room for improvement, please let us know. Thank you. All contributed code will be covered by the [LGPLv3 license](https://github.com/tronprotocol/tron-docker/blob/main/LICENSE) of this project. Here are some guidelines to get started quickly and easily: -- [Before contribution](#Before-contribution) -- [Contribute to tron-docker](#Contribute-to-tron-docker) - - [Key Branches](#Key-Branches) - - [Submitting Code Steps](#Submitting-Code-Steps) - - [Commit Messages](#Commit-Messages) - - [Branch Naming Conventions](#Branch-Naming-Conventions) - - [Pull Request Best Practise](#Pull-request-best-practise) - - [Special Situations And How To Deal With Them](#Special-Situations-And-How-To-Deal-With-Them) -- [Conduct](#Conduct) +- [Contributing](#contributing) + - [Before contribution](#before-contribution) + - [Ask a question](#ask-a-question) + - [Reporting an issue](#reporting-an-issue) + - [Request a feature](#request-a-feature) + - [Contribute to tron-docker](#contribute-to-tron-docker) + - [Key branches](#key-branches) + - [Submitting code steps](#submitting-code-steps) + - [Fork then make changes](#fork-then-make-changes) + - [Linting](#linting) + - [Push code](#push-code) + - [Commit messages](#commit-messages) + - [Branch naming conventions](#branch-naming-conventions) + - [Pull request best practise](#pull-request-best-practise) + - [Special situations and how to deal with them](#special-situations-and-how-to-deal-with-them) + - [Conduct](#conduct) ## Before contribution @@ -94,7 +101,7 @@ Commit the new branch to your personal remote repository. #### Linting - tron-docker CI uses [pre-commit](https://pre-commit.com/) to lint all code within the repo. Add it to your local following the [installation](https://pre-commit.com/#installation). Check [.pre-commit-config.yaml](.pre-commit-config-fix.yaml) for existing validators. + tron-docker CI uses [pre-commit](https://pre-commit.com/) to lint all code within the repo. Add it to your local following the [installation](https://pre-commit.com/#installation). And ensure ShellCheck is also installed, refer to [installation](https://github.com/koalaman/shellcheck?tab=readme-ov-file#installing). Check [.pre-commit-config.yaml](.pre-commit-config-fix.yaml) for existing validators. #### Push code diff --git a/tools/docker/README.md b/tools/docker/README.md index 4301ad7..1edbb7c 100644 --- a/tools/docker/README.md +++ b/tools/docker/README.md @@ -7,7 +7,7 @@ If you encounter any problems during the build or testing process, please refer Follow the [getting-started](https://github.com/tronprotocol/tron-docker/blob/main/README.md#getting-started) guide to download Docker and the tron-docker repository. Then, navigate to the gradlew directory. ``` -cd /java-tron/tools/gradlew +cd ./tools/gradlew ``` Container testing uses the [Goss](https://github.com/goss-org/goss/blob/v0.4.9/README.md) tool, a YAML-based testing framework for validating service states. While no additional installation is required, it is beneficial to learn the basic usage of [Goss with container](https://goss.readthedocs.io/en/stable/container_image/) to help you better understand the following testing scripts.