pybliometrics-dev / pybliometrics

Python-based API-Wrapper to access Scopus
https://pybliometrics.readthedocs.io/en/stable/
Other
410 stars 128 forks source link

Who put my name in AUTHORS and my changes in ChangeLog? #235

Closed raffaem closed 2 years ago

raffaem commented 2 years ago

I am trying to push a simple change here.

However something created an AUTHORS file, ad put my name in it, and a ChangeLog, and put my changes in it.

How did those things ended there?

Michael-E-Rose commented 2 years ago

I don't know how these people ended up there, but it looks like the list of contributors to this repo. They are also here: https://github.com/pybliometrics-dev/pybliometrics/graphs/contributors

raffaem commented 2 years ago

The setup.py install generated them:

[pbr] Writing ChangeLog
[pbr] Generating ChangeLog
[pbr] ChangeLog complete (0.0s)
[pbr] Generating AUTHORS
[pbr] AUTHORS complete (0.0s)
raffaem commented 2 years ago

It's actually pbr that adds them:

AUTHORS: Generate AUTHORS file from git log
ChangeLog: Generate ChangeLog from git log
Michael-E-Rose commented 2 years ago

That sounds correct. But there's flags that prevent pbr to generate those two files.

I forgot to mention that the list you've found is the reason for the flags. Intead we maintain both files manually.

raffaem commented 2 years ago

That sounds correct. But there's flags that prevent pbr to generate those two files.

There seems to be environmental variables to skip creation of AUTHORS and ChangeLog, but I have not found a solution to hard code it.

So it looks like I have to either remember to set the environment variables every time I setup, or remember to don't add the files to the commit (so I cannot call git add -A) or have a commit with those files added.

I forgot to mention that the list you've found is the reason for the flags. Intead we maintain both files manually.

I didn't get that. Those files seems not to be present in the main repo.

Michael-E-Rose commented 2 years ago

This repo has AUTHORS and ChangeLog, too. But we maintain them manually, because the list of authors should be shorter and the git commits do not make for good change log.

To avoid them being overwritten by pbr while creating a new egg, I use this SKIP_GENERATE_AUTHORS=1 SKIP_WRITE_GIT_CHANGELOG=1 python3 setup.py sdist.

raffaem commented 2 years ago

Can we add AUTHORS and ChangeLog to .gitignore? So they don't get mistakenly added when you git add some modifications for a forked version.

Do you use those environmental variables when you try to python setup.py install also?

I find this pbr a bit confusing. Those files are not erased with a python setup.py clean --all either.

You should have some way to hard code skipping the generation of those files. Especially since you have your own, you don't want the pbr generated one?

Michael-E-Rose commented 2 years ago

Those two files are hard-coded members of every repository, at least AUTHORS. You can put them in your .gitignore, but here there's no point in doing that.

Since I execute above command manually in the console, the questions you ask don't really apply for this repo.

raffaem commented 2 years ago

uhm fair enough.

I'll try to remember not to add them when I commit.