I once committed a file I should have ignored. Do you know what happened? A coworker's computer exploded. Now you know this is serious, so you should consider using our API.
This API wil be compliant with gitignore.io by toptal, so you can just change your request from:
toptal.com/developers/gitignore/api/ to donotcommit.com/api/
Nice, right?
Access the OpenAPI documentation at https://donotcommit.com/docs and see all our routes. This is a very simple API as you can notice :).
For now, we are using github/gitignore as the gitignore templates source, but we recognize that they take some time to accept PRs. This delay also motivated toptal team to make their own gitignore source, but it is archived now. That's why we are building an alternative.
Use one client to make your life easier when managing gitignore files:
You can list your client here, just open a PR!
To set up the development environment, you'll need to have Python 3.13 installed. You should use uv to manage dependencies and run commands.
- Clone the Repository:
Clone the repository with the submodule.
git clone --recurse-submodules git@github.com:avantguarda/donotcommit.git
cd donotcommit.com-
Install uv:
If you don't have uv installed, you can install it by following the instructions on the uv installation page.
-
Install Dependencies:
uv sync
This command will install all the necessary dependencies for both the application and development.
-
Activate the Virtual Environment:
source .venv/bin/activate
To run the application, use the following command:
task runThis command will start a local development server.
We use taskipy for task management. Here are some useful commands:
-
Linting:
task lint
This command will run Ruff to check for code issues and display any differences.
-
Formatting:
task format
This command will automatically format your code using Ruff.
-
Run Tests:
task testThis will run the test suite using pytest and display coverage information.
-
Run Mypy:
mypy .This will run Mypy for type checking.
-
Pytest:
Configuration for pytest is specified in
pyproject.tomlunder[tool.pytest.ini_options]. -
Mypy:
Configuration for Mypy is specified under
[tool.mypy]. -
Ruff:
Configuration for Ruff, including linting and formatting settings, is specified under
[tool.ruff].
If you would like to contribute to donotcommit API, please fork the repository and submit a pull request with your changes. Ensure that your changes pass the linting and testing requirements before submitting.