Anto enhances Git project organization and code quality by automating commit message validation, project structure checks, and file content analysis. Its user-friendly features cater to projects of any scale, ensuring that your documentation remains accurate and your development process is smooth.
Anto - Simplifying Git Project Organization and Enhancing Code Quality
Anto is an innovative solution designed to streamline code reviews and improve project integration, documentation, and overall code quality. By automating checks for commit messages, project structure, and file content through VSK/MSK files and Git hooks, Anto ensures that your projects maintain a high standard of quality. This makes it an invaluable tool for teams of all sizes, from open-source contributors to corporate developers.
Key Features
Commit Message Validation (.anto/commit.msk)
With Anto's commit message validation, you can enforce consistent commit message formats by defining rules directly in the .anto/commit.msk
file. Ensure your commit messages adhere to the Conventional Commits structure:
[optional scope]: <description>
Allowed types:
- feat: A new feature
- fix: A bug fix
Commits should not contain the word 'commit' and must be a maximum of 300 characters.
Project Structure Validation (.anto/validation.vsk)
Anto empowers your project structure validation by utilizing the .anto/structure.vsk
file. Define your project's file and folder hierarchy rules to maintain an organized structure:
[app]
[src]
[main]
[java]
[anto]
[feature]
{*utils.6} 1..5
[ui]
[utils]
[test]
[feature-*] < 5
{*utils.6}
Generate your validation file effortlessly with:
.anto create-validation
File Content Validation (.anto/{projectName/*/*.msk})
File content validation keeps your code clean and organized by applying specific rules for individual files. For instance, use the following sample for validating your MainActivity.kt
:
/*
The MainActivity.kt file should only contain navigation code and must not include any @Composable annotations.
The file should be a maximum of 300 lines to prevent overly large classes.
*/
# must have 300 lines max
l 300 <
# the class name must contain Activity
+ *Activity
# the activity should not contain any composable
- @Composable*
To build your file structure quickly, execute:
.anto create-structure
Seamless Integration and Testing
Anto integrates smoothly with your existing Git setup. You can skip validations during commits if necessary by adding the --no-verify
flag. Testing your configurations is simple; just make a commit and let Anto perform its checks to ensure adherence to your defined rules.
Expand Your Validation
Customize your commit message hooks further by adding additional scripting steps in validations.sh
(for Mac and Linux) or validation.ps1
(for Windows). This allows you to integrate tests, linters, and manageable automation tasks into your workflow:
#!/bin/sh
./anto validate
# Navigate to the root of the project
cd ..
# Execute additional scripts (e.g., tests, linters)
lint
gradle test
Anto-UI: A User-Friendly Interface
Anto also offers the Anto UI, a user-friendly interface that consolidates all functionalities into a cohesive platform for ease of use. Manage your project tasks effectively and save time with its intuitive design. Gain access to Anto UI through a donation of 49 USD on Patreon or KoFi.
Support Development
Your support is crucial for the growth of Anto. Please consider donating via Patreon or KoFi to help maintain and develop the tool further.
Anto is not just a tool; it’s a movement towards cleaner, more reliable code and structured development practices.