Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Jun 15 2020 13:06
    arturcic unlabeled #2095
  • Jun 15 2020 13:05
    arturcic opened #2328
  • Jun 15 2020 08:09
    github-actions[bot] commented #2122
  • Jun 15 2020 08:09
    github-actions[bot] commented #2300
  • Jun 15 2020 08:09
    github-actions[bot] commented #2306
  • Jun 15 2020 08:09
    github-actions[bot] commented #2310
  • Jun 15 2020 08:09
    github-actions[bot] commented #2311
  • Jun 15 2020 08:09
    github-actions[bot] commented #2320
  • Jun 15 2020 08:09
    github-actions[bot] commented #2327
  • Jun 15 2020 07:49
    arturcic milestoned #2095
  • Jun 15 2020 07:49
    arturcic demilestoned #2095
  • Jun 15 2020 07:46

    arturcic on 5.3.6

    (compare)

  • Jun 15 2020 07:27
    arturcic demilestoned #2241
  • Jun 15 2020 07:27
    arturcic unassigned #2241
  • Jun 15 2020 07:27
    arturcic demilestoned #2074
  • Jun 15 2020 07:26
    arturcic milestoned #2327
  • Jun 15 2020 07:25
    arturcic demilestoned #2318
  • Jun 15 2020 07:25
    arturcic milestoned #2122
  • Jun 15 2020 07:25
    arturcic labeled #2122
  • Jun 15 2020 07:23
    arturcic demilestoned #2313
Asbjørn Ulsberg
@asbjornu
@aeos, yes GitVersion produces a new version on every commit, but not all variables reflect it (in the same way). The main variable to use is FullSemVer. Why are you using NuGetVersion?
If not continuous delivery, what do you think feature branches should be, @aeos? I don’t quite understand your use-case.
Calvin Dallmore
@aeos
I might be using a screwdriver as a hammer. But this is my process. I have 3 class packages and two projects using them. I restore, build, pack, push, and update dependencies. In order to do that, and in light of the nuget local cache. The version must change for the nuget package on every change. Therefore I am using gitversion to automate the bump of version. Gitversion bumps every commit only when configured to deployment not delivery. Develop is deployment, feature is delivery by default. I was wondering why. But if I am doing this all wrong, please do tell me so.
@asbjornu I am dealing with illness so I might not be as responsive as I should, but I appreciate the attention!
Tomasz Cielecki
@Cheesebaron
Hey there. I am investigating an issue we have on our macOS build agents, where GitVersion takes around 8 minutes to calculate the version number. Does anyone know what could be the reason as to why it takes that long? Running it locally doesn't seem to take more than a couple of seconds.
Gary Ewan Park
@gep13
@Cheesebaron what version of GitVersion are you using? And what CI system are you using?
Tomasz Cielecki
@Cheesebaron
Azure DevOps, we are using version 4.0.0
We run it as part of our Cake build script in the Setup block
I've checked disk throughput just to see if we have any issues there, but read speeds are 930 mb/s and write are around 500 mb/s
Will take a look at the log to see if there is anything in there, which could lead to anything funky
Gary Ewan Park
@gep13
When running locally, is it using a cached version of the asserted version numbers? Is the history of the repository big?
I have got the queue down to 60
Need to stop and go and do other stuff though
Will look again tomorrow
Tomasz Cielecki
@Cheesebaron
History is quite big now. If I run GitVersion again in with the cached results, it seems to run pretty quickly. Let me try to remove the cache and double check
Locally when removing the gitversion_cache folder it is no where near the 8 minutes as on the build machine. And I have a much slower HDD in this machine too.
Gary Ewan Park
@gep13
It could be that the time is taken up in the rationalizing of the git branches, i.e. going from the original Azure DevOps git clone, to what is actually needed to correctly assert the version number. I am assuming that when running on Azure DevOps you are using the BuildServer argument passed to GitVersion, right?
Tomasz Cielecki
@Cheesebaron
Running GitVersion.exe with /diag I get this a lot: Finding merge base between 'bugfix/DRA-3437-unable-to-connect-message-fix-on-release-1.7.0' and 'feature/ball-conversion-text'
over and over again
Running on the build agent we do:
Gary Ewan Park
@gep13
hmm, I tend to avoid putting version numbers into branch names and commit messages, as I have seen unexpected things happen. Might be good to omit those commits from scan. You can do this by adding the sha into the yml file
Tomasz Cielecki
@Cheesebaron
    versionInfo = context.GitVersion(new GitVersionSettings {
        UpdateAssemblyInfo = true,
        OutputType = GitVersionOutput.Json,
        LogFilePath = gitVersionLog
    });
Yeah, will try to ommit that in the yml and see if it helps
Gary Ewan Park
@gep13
Hmm, interesting... ok, so branch rationalization can be ruled out then
henrik eriksson
@henrik_GJ_Esson_twitter
For us it takes ~60 seconds for gitVersion to initilize, going through the entire branch history of the cached repo. GitVersion is set to no fetch. Would it be possible to limit what gitVersion is indexing?
Tomasz Cielecki
@Cheesebaron
OK so
Seems like the issue is that there is a ton of local branches on the build machines
which haven't been cleaned up and are gone from remote
Gary Ewan Park
@gep13
Is this a hosted build agent, or your own internal one?
Tomasz Cielecki
@Cheesebaron
This a internal build machine on our local network
Gary Ewan Park
@gep13
Ah, ok, so that makes more sense.
Tomasz Cielecki
@Cheesebaron
Seems like, even though clean is enabled in Azure Pipelines it leaves local branches floating around
Seems like, even though clean is enabled in Azure Pipelines it leaves local branches floating around
My own internal one
Asbjørn Ulsberg
@asbjornu
@aeos, your use-case sounds rather special and not something GitVersion is rigged for out of the box, but if develop works as you expect, you can just give feature branches mode: ContinuousDeployment as well.
henrik eriksson
@henrik_GJ_Esson_twitter
@Cheesebaron have you verified that this is not a several step cache being used? E.g. if there is one cache being used for all the builds, which are copied to local build folders for the explicit builds. Both the cache and the build folder needs to be verified to be clean...
henrik eriksson
@henrik_GJ_Esson_twitter
According https://gitversion.readthedocs.io/en/latest/more-info/version-increments/, gitVersion calculates the next semver version. But when I tested setting version 1.2.3 in the branch name, gitversion tells me the assemblySemVer version is 1.2.3
Should it be like that?
henrik eriksson
@henrik_GJ_Esson_twitter
When working with GitVersion in CI environment, must full repo be used? Or shallow clones possible(seems so to me). And on single branches(possible? not recommended?)
...related to speeding up the build environment
henrik eriksson
@henrik_GJ_Esson_twitter
Noticing that shallow clones is fine. But gitversion requires a master or development branch to be present. So CI builds on single branch does not work
Asbjørn Ulsberg
@asbjornu
I suppose it depends on how shallow the clone is. GitVersion needs enough history to find a version source, which will often be a tag. If no source can be found in the history, it will crash.
Igor Artamonov
@splix
I wanted to try GitVersion tool in our project, to tag builds during CI. We use CircleCI and Travis, and none of them comes with GitVersion preinstalled. I was trying to find a release for non-windows os, but don't see any. 'apt-get install gitversion' can't find it too. Am I missing something, or how people use it with circleci/travis?
Kim J. Nordmo
@AdmiringWorm
most projects I've seen make use of the GitVersion.Commandline nuget package (which requires mono on non-windows systems).
There is also a .NET Core global tool called GitVersion.Tool that can also be used (no stable release of this one yet though)
@splix ^^
Igor Artamonov
@splix
Can you please to point to any of such project? open soruce I mean. want to take a look at their CI configs
because I have no idea what is nuget package actually :) and how to install it
ah, maybe I’ve found a project with such travis config. trying now
Kim J. Nordmo
@AdmiringWorm
I see. The projects I've seen using it, mostly build on Windows (some do on Linux as well), and all of them makes use of something called Cake to orchestrate the build, which then pulls down the nuget packages the owners want to use.
This may not apply to you though unfortunately
not seen anyone using the cmd directly yet though.