Python template has .gitignore without .git

Problem description

the recent python template has a .gitignore file while lacking a .git directory or a managed git repo.

Expected behavior

.gitignore is useful, but only when a git repo is being used.

Actual behavior

there is a .gitignore file.

Steps to reproduce

https://replit.com/@python660/ClosePastPhp#.gitignore

Browser

Chrome

OS

OSx

Device if mobile

N/A

Plan

FREE

2 Likes

@python660 Thanks for bringing this up. This is currently by design.

When users initialize git repositories, there isn’t a gitignore that gets generated, so users can end up with unexpected items committed. We’ve decided to add gitignore to help with those issues, and users can delete it if it’s not useful. On the other side, we didn’t want to initialize git repositories in the templates for a few reasons (such as users ending up with a blank git repository they didn’t want).

Discussing internally, there doesn’t seem to be a good solution to make everyone happy, but we’re looking at continuing improvements. For example, there might be a way to organize or present it better in the Repl.

Hope it helps.

3 Likes

Thank you for you answer! I completely agree with the presence of a .gitignore file, and I’ll mark your answer as the solution.

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.