You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Most of the NCSSAR home-brew python repo's don't use version numbering. While the clean way to do things would be to add version numbering / tag numbering to each repo, that's not completely reliable - what if a hotfix is made but no new tag is or the version number is not incremented? Then a simple version# / tag# comparison would not show a need for an update.
So, to be safer, compare the contents of the installation to the contents of the repo head. A recursive diff of the unzipped downloaded repo head would be one way.
To avoid doing this download-and-compare more often than necessary, maybe keep track of when the latest comparison was run, and what the file modification times were when the comparison was run, and run a comparison again if there are any file modification times more recent than the last comparison? Would need to account for config files / 'local' directories inside the unzipped dir tree, which would intentionally differ from the repo head.
Is there a better way?
The text was updated successfully, but these errors were encountered:
caver456
changed the title
determine if local installation of a git repo needs updating, without relying on tag / release# / version
determine if local installation of a git repo needs updating, without relying on tag / release# / version#
Jun 13, 2022
I haven't used tags at all on any repo's - to rely on tags would mean
adding the manual step of creating a tag to the workflow every time a new
commit is done, right? Regardless of whether it seems easy and seems like
a good habit to get into anyway, the chances of forgetting to do that seem
high.
Most of the NCSSAR home-brew python repo's don't use version numbering. While the clean way to do things would be to add version numbering / tag numbering to each repo, that's not completely reliable - what if a hotfix is made but no new tag is or the version number is not incremented? Then a simple version# / tag# comparison would not show a need for an update.
So, to be safer, compare the contents of the installation to the contents of the repo head. A recursive diff of the unzipped downloaded repo head would be one way.
To avoid doing this download-and-compare more often than necessary, maybe keep track of when the latest comparison was run, and what the file modification times were when the comparison was run, and run a comparison again if there are any file modification times more recent than the last comparison? Would need to account for config files / 'local' directories inside the unzipped dir tree, which would intentionally differ from the repo head.
Is there a better way?
The text was updated successfully, but these errors were encountered: