Search code examples
gitgitignore

What does the dot . mean here in the gitignore


I have searched online and on git website for this gitignore explanation but cant find an answer.

What does the dot . mean here in the gitignore line .env.development.local?

# misc
.DS_Store
.env.local
.env.development.local
.env.test.local
.env.production.loc

Solution

  • Those files are the . files in your folder.

    .DS_STORE exists only for Mac, has something to do with Mac folder structure.

    The different .env files are used in different development teams depending on the situation.

    Environment variables are more common for something like a nodejs application like an API which has to have a database url or something

    For example:

    • .env is the main environment variables file.
    • .env.development are environment variable file for development only
    • .env.local are enviornment variables only for local

    The files are above are just example type standards. I personally don't follow all those files actually.