GithubHelp home page GithubHelp logo

natescherer / update-powershell-metadata-action Goto Github PK

View Code? Open in Web Editor NEW
2.0 2.0 0.0 85 KB

A GitHub Action to update metadata in PowerShell modules and scripts.

License: MIT License

PowerShell 100.00%

update-powershell-metadata-action's People

Contributors

allcontributors[bot] avatar dependabot[bot] avatar natescherer avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar

update-powershell-metadata-action's Issues

Update-PSModuleManifest error due to system.object[] for path parameter

Thanks for this project, it's a nice little addition to the CICD process for me.

When triggering, the action fails for me with an error because it believes the path parameter is being passed an object instead of a string.

The output from the action reads...

Validating Inputs...
Run $SafePath = Join-Path $env:GITHUB_ACTION_PATH src steps 3_build_and_update.ps1
  $SafePath = Join-Path $env:GITHUB_ACTION_PATH src steps 3_build_and_update.ps1
  . $SafePath
  shell: /usr/bin/pwsh -command ". '{0}'"
  env:
    RESOLVEDPATH: /home/runner/work/CoveBackupApi/CoveBackupApi/Output/CoveBackupApi/CoveBackupApi.psd1
    INPUT_PATH: .\Output\CoveBackupApi
...

Update-PSModuleManifest: /home/runner/work/_actions/natescherer/update-powershell-metadata-action/v2/src/steps/3_build_and_update.ps1:53
Line |
  53 |      Update-PSModuleManifest @MetadataSplat
     |      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     | Error occured while running 'New-ModuleManifest': Cannot convert
     | 'System.Object[]' to the type 'System.String' required by parameter
     | 'Path'. Specified method is not supported.

This code uses the RESOLVEDPATH env to set the Path parameter in the splat definitions.

The RESOLVEDPATH env in the output correctly identifies the absolute path to psd1 file, so I can't understand how this error is getting generated.

It's entirely plausible that I've done something stupid!

Release Improvements

  • Changelog automated into releases
  • Automatic merging of GH Actions PRs?
  • Confirm non-draft releases publish to marketplace
  • Set major, possibly minor tags

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.