• (nodebb)

    I've worked at a place which, even though they used source control for the database, demanded that we include a "change log" at the top of the stored proc because it was "easier to see when working on it". The same place also forbade formatting the document because it messed up the Diff.

  • Angela (unregistered)

    I have to deliver source to a customer that has no access to our source control. So this is a requirement. I have to nag people to do it, it's a pain.

  • (author) in reply to Angela

    I'm sure there are constraints around why you can't use it, but this is 100% what Git is good at. Internal remote for development, external facing remote for your customers.

  • (nodebb) in reply to Angela

    If the customer needs source history, they should get source history. There's no guarantee that the comments accurately reflect the source history.

    As Remy said, Git is really good for this. But you don't necessarily need an externally-accessible repository. If you have to deliver history along with the source code, just deliver a Git bundle file.

  • (nodebb)

    Is no one going to mention Remy's typo in the title? Or am I TRWTF because it was intended irony?

  • Angela (unregistered) in reply to Dragnslcr

    Git didn't exist when the project started and I'm not sure anyone wants to make the transition from Clearcase exactly for fear of losing that history.

  • PotatoEngineer (unregistered) in reply to Remy Porter

    Okay, so swearing goes in the Git commit message, not in the source code comments. Got it.

  • (nodebb) in reply to ObiWayneKenobi

    Look, the change log had a lot to do with not everyone who worked on the procedures being included in the licensing when we finally got tooling set up to source-control the database, and the original idea was supposed to be that formatting should always be its own commit, but then we couldn't get the senior dev to fix his line ending settings or everyone to standardize on tabs or spaces plus we had to keep dealing with formatting changes from the folks who didn't have the source control tooling and...

    uh...

    ok you probably didn't really work with me before, but yeah, definitely hits close to home.

  • Registered (unregistered)

    Sooner or later someone will use calculateMassGrossPay() to write the checks and everyone will have to track down the reason no one was paid.

  • asdf (unregistered)

    A nice thing about compiled languages is that the compiler will tell you in no uncertain terms if you try calling a non-existent function.

  • COBOL Dilettante (unregistered)

    I was on a call recently where our internal auditors wanted to know why the control developers hadn't removed the line of code from their script that they'd been told to remove a few years ago.

    Turns out they had "removed" it, it's just the auditors didn't know what "--" means in SQL ... which has taught me a new reason why you should actually delete code instead of commenting it out

  • DrPepper (unregistered) in reply to Angela

    This is something that AI is really good at. Have the AI generate the comment from the diff, and include it as a comment at the top of the source file as it is bundled up to deliver to the customer. And if the comment REALLY needs to be in the source file permanently, have AI generate that comment and insert it before committing the code to the repo. And, you might as well have the AI write the commit message too, while you're at it.

  • Angela (unregistered) in reply to DrPepper

    Maybe we'll have AI tools in a couple decades, and I am not exaggerating. We don't even have widely available tools like Jira, etc.

Leave a comment on “Safegaurd Your Comments”

Log In or post as a guest

Replying to comment #692002:

« Return to Article