I want to use a particular branch in order to deploy. I am using teamcity to set up a VCS Settings.
My current repository directory structure is as follows:-
My default dir:- http://hg.test.co.uk/mainbranch
branches - ver-11.6
- ver-11.5
Now in VCS Settings teamcity I am setting it as follows:-
Pull changes from: https://hg.test.co.uk/mainbranch
default branch :
Branch Specification: +:/branches/ver-11.6
When I run it from teramcity it always update from default. I want it to update from branch ver11.6. Please guide what I am doing wrong here.
You don't need to type /branches/. Use raw branch name. Correct branch specification is +:ver-11.6 for branch ver-11.6.
Related
The Actions tab shows workflows created in main branche's /.github/workflows/ only
I have workflow.yml files with workflow_dispatch trigger that are defined in another branch (test) that are not yet merged into the main branch
Is there any way I can see and run workflows with workflow_dispatch trigger that are created in another branch not yet merged with the main branch?
It looks that you can't change at the moment. It takes actions from default branch. You can change default branch but I assume that this is not acceptable for you (which I understand). Please take a look here on github community -
Workflow files only picked up from master?
If you use a web browser, you will see a dropdown - Use workflow from
If you use GitHub CLI, you need to use --ref flag
gh.exe workflow run workflown_name --ref branch_name -f param_name=value
documentation is here
I cloned a Mercurial repo and did a bunch of local work, and forgot to make a feature branch for said work.
The normal flow is:
Clone
Create a branch
Switch to that branch
Do your work in that branch
Push that branch
Code review
If code review passes, merge branch w/ default (locally)
Push merged changes to default
Close the feature branch
So I need to create a new branch, port all my unstaged/uncommitted code changes (made to default) over to this branch (so that default is now clean and the new branch contains my changes), and then push my feature branch.
I created the new branch via hg branch new_feature. But after pouring over the Merucrial docs, I can't figure out the next step.
So I ask: How do I move (not just copy) all my unstaged/uncommitted changes from default to my new_feature branch)?
You shouldn't have to do anything in particular.
Your uncommitted working folder changes are fluid, and you can set the branch name before you commit, without losing your changes.
If you're on the command line, simply do this:
hg branch feature-X
hg commit -m "Added feature X"
If you're using TortoiseHg simply click the "Branch: default" button just above the commit message input field and select "Open a new named branch" and give it a name, then click OK, then commit as normal.
Setting the branch name to use during commit does not in fact change your working folder, it doesn't do an update, it doesn't do anything, except record in metadata what the branch name is supposed to be.
Also note that this will only allow you to create a new branch to commit to. If you want to continue on an existing branch you first need to update to the head of that branch and this may cause changes to your working folder. You should not need to do this, however, if you want to create a new branch.
I have a repository called "abc" and my team member has forked this repository as "fork_abc". He commited some changes to "fork_abc". Now I have a cloned repository called "clone_abc" in my local system.
How can I pull the changes from "fork_abc" to "clone_abc" . I want to verify the changes and then push it to "abc" later.
I tried using $ hg pull "fork_abc" ,
but it seems its not the correct way. I am using mercurial for this and not git.Can some suggest what is correct command for this operation.
You could always export as patches the changes in fork_abc, review them as patches and then import them to abc.
Is there a way in mercurial to give an alternate name to the default branch while still having default work as before? I.e., Can I set things up so that either hg update main or hg update default will bring me to the default branch?
You could hand a bookmark named 'main' on the default branch like:
hg bookmark --rev default main
That bookmark will start out on the "most tipward" changeset on the default branch. And the bookmark will follow that along when you commit (including committing merges).
In general though try to keep using the name 'default' for your active development work.
I have some (local) repositories, an original and some clones. The original repository has been corrupted so I'd like to get rid of it and use one of the clones as the master for future development.
Is there a better way to break the connection between the new master and the original repository than simply deleting the default entry in the [paths] section of that clone's hgrc?
Similarly, in the other clones, can I simply change the default entry in their hgrc files' [paths] section to point to the new master repository?
All clones are independent, but they remember where they were cloned from. As you have found out, this is stored in the .hg/hgrc file. You are free to edit this file as you like. You can even add more paths if you want.
So in your case you just delete the original repository and replace it with a good clone.
The idea is either:
to define a new default path in the paths section
or to define a new path (see this SO question)
But in both cases, that involves modifying the hgrc files.