News for hackers. Stuff that matters.
Re:Why Git Is Hard by Xeamek on Saturday October 07, 2023 @04:53AM (#37800154)
Delete the file from (past) commits? Isn't the whole point (idiomatic way) that you don't do that, and only delete it in the newest commit?

Unless you mean some intentionally weird scenario, where you want to just delete the file to prevent it from being accessible period. But that's (afaik) against the whole concept of git, and so verry much outside the intended use.

Do I understand your example?

Re:Why Git Is Hard by kibibu on Saturday October 07, 2023 @10:41PM (#37807439)
It's a fairly common problem when people realise they have inadvertently committed a secrets file.

You could say "well don't commit secrets files" but that doesn't immediately solve the problem.

Re:Why Git Is Hard by nikau on Sunday October 08, 2023 @03:47AM (#37808623)
In that case the secret is blown so you rotate it and leaving in the repo isn't an issue.
Re:Why Git Is Hard by kibibu on Monday October 09, 2023 @05:27PM (#37825743)
Maybe the repo hasn't been made public yet and it's a clean up before release.