Skip to content

Add Sha and Pipeline support to New-GitHubRepositoryBranch #261

Description

Feature Idea Summary

Follow-up from PR feedback:

This should have an optional parameter for Sha. If not supplied, I agree, the function can continue to look up the existing Sha value. However, in the event that a user pipes in a GitHub.Branch object, it should have everything that it needs.

  1. New-GitHubRepositoryBranch should be able to completely take in a GitHub.Branch object as its pipeline input. It should therefore have [Parameter(ValueFromPipelineByPropertyName)] added to $BranchName.
  2. Add-GitHubBranchAdditionalProperties should add Sha as a top-level property that it adds to a GitHub.Branch object.
  3. New-GitHubRepositoryBranch should have an optional Sha property that can receive ValueFromPipelineByPropertyName, and only resorts to looking up the Sha via an additional REST request if it wasn't supplied.

Feature Idea Additional Details

Requested Assignment

- I'm just suggesting this idea, but don't want to implement it.

Operating System

Name               : Microsoft Windows 10 Enterprise
OsOperatingSystemSKU : EnterpriseEdition
OsArchitecture       : 64-bit
WindowsVersion       : 2004
WindowsBuildLabEx    : 19041.1001.amd64fre.vb_release_ingestion.191208-1700
OsLanguage           : en-US
OsMuiLanguages       : {en-US, es-MX}

PowerShell Version

Name                           Value
----                           -----
PSVersion                      5.1.19041.1001
PSEdition                      Desktop
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
BuildVersion                   10.0.19041.1001
CLRVersion                     4.0.30319.42000
WSManStackVersion              3.0
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1

Module Version

Running: 0.14.0
Installed:

Activity

  1. added
    enhancementAn issue or pull request introducing new functionality to the project.
    up for grabsAnyone in the community is welcome to do this work
    help wantedAnyone in the community is welcome to do this work
    good first issueIf you're new to the project (or to OSS in general) and you'd like to contribute, try this one.
    on Jul 7, 2020
  2. changed the title [-]Add Sha support to New-GitHubRepositoryBranch[/-] [+]Add Sha and Pipeline support to New-GitHubRepositoryBranch[/+] on Jul 7, 2020
  3. added
    in progressWork on this issue is already underway. Please don't work start new work on it.
    and removed
    good first issueIf you're new to the project (or to OSS in general) and you'd like to contribute, try this one.
    help wantedAnyone in the community is welcome to do this work
    up for grabsAnyone in the community is welcome to do this work
    on Aug 13, 2020
  4. added a commit that references this issue on Aug 13, 2020
    3e79c25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementAn issue or pull request introducing new functionality to the project.in progressWork on this issue is already underway. Please don't work start new work on it.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions