nanocurrency / nano-node

Nano is digital currency. Its ticker is: XNO and its currency symbol is: Ӿ
https://nano.org
BSD 3-Clause "New" or "Revised" License
3.49k stars 787 forks source link

Add support for branches on artifact workflows #3529

Closed zhyatt closed 3 years ago

zhyatt commented 3 years ago

The Beta workflow that produces beta network artifacts (and probably the Test and Live ones which are similar) doesn't appear to use the selected branch, instead it pulls develop. These workflows were intended to be used via tags off the develop branch, but having support for running them off other branches would be useful and avoid confusion when attempting to do so.

dsiganos commented 3 years ago

That description doesn;t make much sense. A tag is a tag and it identifies a specific commit. There should be no mentioning of branches in that conversation.

zhyatt commented 3 years ago

That description doesn;t make much sense. A tag is a tag and it identifies a specific commit. There should be no mentioning of branches in that conversation.

The issue is that the UI for running the workflow allows you to select a branch, but in doing so it doesn't appear the workflow is using the selected one, but is instead hardcoded to use the develop branch. Although we intend to use it primarily with tags off the develop branch, it doesn't restrict you to that one so supporting the use of branches could be done.

If we don't want to support branches and just ensure use is constrained to tags, then it is just a matter of referencing documentation.

dsiganos commented 3 years ago

We should clone and checkout like this:

git clone --recursive https://github.com/nanocurrency/nano-node.git
git checkout refs/tags/$TAG
git submodule update
dsiganos commented 3 years ago

My point is, that it makes no sense to specify both a tag and a branch. When using a branch, a tag is irrelevant. And using a tag, a branch is irrelevant. So there should never be a need to specify both.

zhyatt commented 3 years ago

Ok, so I see the confusion on my end now, thanks @dsiganos . GitHub allows you to select a branch to run the workflow from and then separately specifies the tag to build from. In the case of the beta build failures the branch to run the workflow from was changed to be the branch we wanted to build from, not run the workflow from. And the tag was left as develop so the build was from develop (in this case branch, but either a branch or tag works here).

Given this, there is no change to be made and we can close this out.