New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
$PSScriptRoot
unpopulated when script missing the .ps1
file extension
#21554
Comments
Is this a duplicate of #21402 ? |
Looks like it.
To add; I think what's really responsible is that |
Dup #4217 |
Can't dupe a closed-due-to-inactivity issue. "if this is a bug please try to reproduce on the latest version of PowerShell and reopen a new issue and reference this issue if this is still a blocker for you" |
#21402 did have a work around, creating a shell script without the extension adjacent to the powershell script with ps1
|
I've just resorted to keeping the |
Just so you know, the exec means no fork occurs and pwsh replaces sh with the same process id, environment, file descriptors etc. There is no intermediate. |
It's more bourne itself, I don't want to have to look up the intricacies of |
This issue has been marked as duplicate and has not had any activity for 1 day. It has been closed for housekeeping purposes. |
📣 Hey @Hashbrown777, how did we do? We would love to hear your feedback with the link below! 🗣️ 🔗 https://aka.ms/PSRepoFeedback |
Prerequisites
Steps to reproduce
Create a script utilising
$PSScriptRoot
, running via crunchbang instead of file association.Expected behavior
Actual behavior
Error details
No response
Environment data
Visuals
The text was updated successfully, but these errors were encountered: