Skip to content

Fix version for snapshot builds#1178

Closed
sean-breen wants to merge 3 commits intomainfrom
fix-version-for-local-builds
Closed

Fix version for snapshot builds#1178
sean-breen wants to merge 3 commits intomainfrom
fix-version-for-local-builds

Conversation

@sean-breen
Copy link
Contributor

Proposed changes

The version number when building local snapshots incorrectly appears as the default value 3.0.0. This change will allow us to collect the version number by checking git describe for the last available tag instead.

Checklist

Before creating a PR, run through this checklist and mark each as complete.

  • I have read the CONTRIBUTING document
  • I have run make install-tools and have attached any dependency changes to this pull request
  • If applicable, I have added tests that prove my fix is effective or that my feature works
  • If applicable, I have checked that any relevant tests pass after adding my changes
  • If applicable, I have updated any relevant documentation (README.md)
  • If applicable, I have tested my cross-platform changes on Ubuntu 22, Redhat 8, SUSE 15 and FreeBSD 13

@sean-breen sean-breen requested a review from a team as a code owner July 23, 2025 12:11
@github-actions github-actions bot added the bug Something isn't working label Jul 23, 2025
$(shell mkdir -p $(DIRS))

VERSION ?= "v3.0.0"
VERSION ?= $(shell git describe --tags --abbrev=0)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you follow the same logic as in V2?
https://github.com/nginx/agent/blob/dev-v2/Makefile#L6

There is an additional if statement needed for people that might fork the repo

@oCHRISo oCHRISo added the v3.x Issues and Pull Requests related to the major version v3 label Jul 23, 2025
@sean-breen
Copy link
Contributor Author

Closing this, need to fix the action cloning tags correctly.

@sean-breen sean-breen closed this Jul 23, 2025
@sean-breen sean-breen deleted the fix-version-for-local-builds branch July 23, 2025 14:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working v3.x Issues and Pull Requests related to the major version v3

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants