editorconfig / editorconfig-vim

EditorConfig plugin for Vim
http://editorconfig.org
Other
3.14k stars 139 forks source link

compiled python files should be ignored by git #219

Closed mlippert closed 1 year ago

mlippert commented 1 year ago

Description

I have editorconfig-vim as a submodule for my personal vim config git repository. It is in vim/pack/my/start/editorconfig-vim.

When I look at untracked files, I see all of editorconfig-vim/plugin/editorconfig-core-py/editorconfig/__pycache__/*.pyc files.

Since cached compiled python shouldn't be committed, I think it would be best to add them to the .gitignore file at the root of the editorconfig-vim repository.

Solution

Adding this to the .gitignore should do it:

# ignore cached compiled (*.pyc) python files
__pycache__/
cxw42 commented 1 year ago

PRs welcome!

mlippert commented 1 year ago

sure I'll submit one, gotta fork the repo first, so give me a bit.

mlippert commented 1 year ago

Well I was about to create a PR (and I still will if you want) but I discovered that the *.pyc files in my vim/pack were just left behind files from an old (very old) version of the plugin.

It seems that commit 37bedf88 "fixed" the issue by removing the files that were being compiled.

So a PR to update the .gitignore as I suggesting would be useful only if python code that needs to be compiled is added to the repo again.

This issue can be closed.

cxw42 commented 1 year ago

OK --- thanks!