Determine software script name properly
This commit is contained in:
parent
48f0097c45
commit
40a422bb8e
|
@ -16,11 +16,11 @@ $null = New-Module {
|
|||
[hashtable] $Arguments
|
||||
)
|
||||
|
||||
Start-Operation {
|
||||
if (-not $Name) {
|
||||
$Name = Split-Path -Leaf (Split-Path -Parent ((Get-PSCallStack)[1].ScriptName));
|
||||
}
|
||||
if (-not $Name) {
|
||||
$Name = Split-Path -Leaf (Split-Path -Parent ((Get-PSCallStack)[1].ScriptName));
|
||||
}
|
||||
|
||||
Start-Operation {
|
||||
if ($null -ne $Name) {
|
||||
$Name = "``$Name``";
|
||||
} else {
|
||||
|
|
Loading…
Reference in a new issue