Open Alex-Gomez-Lopez opened 1 month ago
This is because that script just copies each function into your script including the signature of the function. You have to remove the signatures and make sure that the functions are in the correct place in the script before it will run.
Thanks @Alex-Gomez-Lopez for reporting this. I recently came across the first error and you beat me to creating an issue for it. This is due to us signing the module beginning in 6.0 and including that in the updated script.
As a workaround, remove the signature(s) for error 1. For the second error, that enum should have been added to the script. Perhaps it is lower in the script. I'll look into it.
This is because that script just copies each function into your script including the signature of the function. You have to remove the signatures and make sure that the functions are in the correct place in the script before it will run.
It actually includes the sigs from the enums and classes, not functions.
After using Set-VenafiStandaloneScript to generate a VenafiPS v6.4.0-based standalone PowerShell script I have encountered these two errors:
I am not sure if these errors are caused by a bug or else there is something I am missing, thanks in advance!! Version of PowerShell is 5.1 running on Windows Server 2019 Datacenter build 17763.2061.