GithubHelp home page GithubHelp logo

Comments (5)

julioarruda avatar julioarruda commented on August 20, 2024 2

The checkout and persist credentials is a step, not job configuration, and you need to declare env: on task

steps:
- checkout: self
  persistCredentials: true

- task: GitflowBranchGate@1
  displayName: 'Gitflow Branch Gate'
  inputs:
    hotfixBranchLimit: 5
    hotfixBranchDaysLimit: 30
    releaseBranchLimit: 5
    releaseBranchDaysLimit: 365
    featureBranchLimit: 10
    featureBranchDaysLimit: 90
    hotfixBranchesMustNotHavePendingPullRequests: false
    releaseBranchesMustNotHavePendingPullRequests: false
    releaseMustNotBeBehindMaster: false
    mustNotHaveHotfixAndReleaseBranches: false
    featureBranchesMustNotBeBehindMaster: false
    CurrentFeatureMustNotBeBehindMaster: false
  env:
    SYSTEM_ACCESSTOKEN: $(System.AccessToken)

from vststasks.

MooVC avatar MooVC commented on August 20, 2024 1

We have a winner - thanks @julioarruda and @kerwinc for your support! :)

from vststasks.

julioarruda avatar julioarruda commented on August 20, 2024

This task work on yaml if you put this:

env:
SYSTEM_ACCESSTOKEN: $(System.AccessToken)

And this step:

  • checkout: self
    persistCredentials: true

from vststasks.

kerwinc avatar kerwinc commented on August 20, 2024

@MooVC as @julioarruda mentioned, you need to allow the task to use the System.AccessToken. Has the above solution worked for you?

from vststasks.

MooVC avatar MooVC commented on August 20, 2024

@MooVC as @julioarruda mentioned, you need to allow the task to use the System.AccessToken. Has the above solution worked for you?

Thanks for coming back on this one @kerwinc. I'm probably missing something here but when I did as suggested I get the following:

##[error]Could not find remote branch: refs/heads/master

  • job: Integration
    timeoutInMinutes: 10
    pool:
    vmImage: windows-latest
    workspace:
    clean: all
    checkout: self
    persistCredentials: true

    steps:

    • task: GitflowBranchGate@1
      inputs:
      repository: '$(Build.Repository.Name)'
      masterBranch: 'master'
      developBranch: 'develop'
      hotfixBranches: 'hotfix/'
      releaseBranches: 'release/
      '
      featureBranches: 'feature/*'
      hotfixBranchLimit: '1'
      hotfixBranchDaysLimit: '10'
      releaseBranchLimit: '1'
      releaseBranchDaysLimit: '10'
      featureBranchLimit: '50'
      featureBranchDaysLimit: '45'
      featureBranchesMustNotBeBehindDevelop: true
      authenticationType: 'OAuthToken'

from vststasks.

Related Issues (17)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.