back to home

toptal / gitignore.io

Create useful .gitignore files for your project

8,671 stars
685 forks
57 issues
SwiftLessJavaScript

AI Architecture Analysis

This repository is indexed by RepoMind. By analyzing toptal/gitignore.io in our AI interface, you can instantly generate complete architecture diagrams, visualize control flows, and perform automated security audits across the entire codebase.

Our Agentic Context Augmented Generation (Agentic CAG) engine loads full source files into context, avoiding the fragmentation of traditional RAG systems. Ask questions about the architecture, dependencies, or specific features to see it in action.

Embed this Badge

Showcase RepoMind's analysis directly in your repository's README.

[![Analyzed by RepoMind](https://img.shields.io/badge/Analyzed%20by-RepoMind-4F46E5?style=for-the-badge)](https://repomind-ai.vercel.app/repo/toptal/gitignore.io)
Preview:Analyzed by RepoMind

Repository Summary (README)

Preview
<p align="center"> <a href="https://www.toptal.com/developers/gitignore"> <img src="Public/img/gitignoreio.svg"/> </a> <br> <strong>Create useful .gitignore files for your project</strong> </p> <p align="center"> <a href="https://swift.org"><img src="https://img.shields.io/badge/Swift-4.1-orange.svg?style=flat-square"/></a> <a href="https://travis-ci.org/toptal/gitignore.io"><img src="https://img.shields.io/travis/toptal/gitignore.io/master?style=flat-square" alt="Travis"></a> <a href="https://codeclimate.com/github/joeblau/gitignore.io/test_coverage"><img src="https://img.shields.io/codeclimate/coverage/joeblau/gitignore.io.svg?style=flat-square" alt="Code Climate Test Coverage"></a> <a href="https://codeclimate.com/github/joeblau/gitignore.io/maintainability"><img src="https://img.shields.io/codeclimate/maintainability/joeblau/gitignore.io.svg?style=flat-square" alt="Code Climate Maintainability"></a> <img src="https://img.shields.io/badge/Platforms-Linux%20%7C%20macOS%20%7C%20Windows-blue.svg?style=flat-square"alt="Platforms"> <a href="https://github.com/joeblau/gitignore.io/blob/master/LICENSE.md"><img src="https://img.shields.io/github/license/joeblau/gitignore.io.svg?style=flat-square" alt="license"></a> </p>

About

.gitignore.io is a web service designed to help you create .gitignore files for your Git repositories. The site has a graphical and command line method of creating a .gitignore for your operating system, programming language, or IDE.

.gitignore Template Source

Source templates for gitignore.io: https://github.com/toptal/gitignore

License of the generated files

All files generated by https://www.toptal.com/developers/gitignore are under CC0.

Documentation

Complete gitignore.io documentation: https://docs.gitignore.io/

Docker Container

Prerequisites

Build

Production

docker-compose up --build

Development

docker-compose -f ./docker-compose-dev.yml build
docker-compose -f ./docker-compose-dev.yml up

It will start the web server running on http://localhost:8080

Development mode mounts the following directories to docker volumes:

  • /Public
  • /Resources

LESS and CSS

The app uses LESS as its CSS preprocessor for the files in Public/css.

To process the less file you need to:

  • Install all dependencies with yarn install
  • Process the assets with yarn build

Environment Variables

Please set your environment variables to docker configurations. All are optional.

...
services:
  app:
    ...
    environment:
      HOST_ORIGIN: http://www.example.com
      BASE_PREFIX: /foo/bar
      GOOGLE_ANALYTICS_UID:
    ...
...

HOST_ORIGIN

Origin of your web server, falls back to https://www.toptal.com

HOST_ORIGIN: http://www.example.com

BASE_PREFIX

If you want to host this web server under a subdirectory (http://www.example.com/foo/bar for example), please set this variable.

BASE_PREFIX: /foo/bar

GOOGLE_ANALYTICS_UID

User ID for Google Tag Manager snippet

GOOGLE_ANALYTICS_UID: UA-XXXXXXXX-X

E2E Tests

Tests are located in e2e-tests folder with:

  • API tests in api folder - implemented using Superagent
  • E2E tests in pages folder - implemented with Puppeteer

Prerequisites:

Running:

  • Set the BASE_URL env variable (only if you have changed the default URL or port)
  • docker-compose up --build --detach
  • yarn gitupdate
  • yarn install
  • yarn build
  • yarn test
  • docker-compose stop