pendulum icon indicating copy to clipboard operation
pendulum copied to clipboard

Add 'taplo' to the CI workflow to check the formatting of Cargo.toml files

Open ebma opened this issue 1 year ago • 2 comments

Context

There is a tool called taplo that can check and format TOML files. Since different IDEs by default have different rules for formatting TOML files, we want to streamline the formatting by using this tool.

TODO

There is no precommit hook for the pendulum repository yet and it's probably good enough to check for the formatting in the CI and leave it to the developers to run taplo fmt locally before creating the PR.

  • Add taplo to the automated build checks in the Github CI workflow. Only check for wrong formatting with taplo fmt --check but don't correct the formatting in the CI
  • Add a configuration file. We can put it into .config/taplo.toml and draw inspiration from the one used for the polkadot-sdk here
  • Add instructions to install and use taplo to the README.

ebma avatar Oct 02 '24 13:10 ebma

@pendulum-chain/product similar to #490, this is a nice-to-have addition improving the developer experience.

ebma avatar Oct 02 '24 13:10 ebma

Hey team! Please add your planning poker estimate with Zenhub @b-yap @ebma @gianfra-t @TorstenStueber

prayagd avatar Oct 11 '24 07:10 prayagd