yujiachen-y / goaccessor

`goaccessor` is a Go tool designed to automate the generation of `getter` and `setter` boilerplate code for your types and variables.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Include version number in generated output

yasv98 opened this issue · comments

It would be good if the goaccessor could print out the version number of the package so it can be pinned in tooldeps and help manage version control.

I've linked a PR with a possible way to do this here

Hi @yasv98 , I appreciate your input. Currently, I use go mod for version management, along with other packages use in my projects. However, I'm open to revisiting this approach based on user feedback and evolving needs.

Beside, I'm also considering about removing arguments in the "// Code generated by "goaccessor %s". DO NOT EDIT." statement to make it shorter.

Personally, I find this very useful for generated files. It helps manage version control and identify when there might be a drift in the version being used to generate an output. Similar to the what protobuf has (example below):
image