script termination from module: exit vs. break
hi, have script below loads module writes line.
runme.ps1 contents:
import-module .\mymod.psm1
write-host "from runme.ps1"
mymod.psm1 contents:
exit
running script outputs:
from runme.ps1
this indicates exit in module not terminate script, exits module load. why? isn't supposed exit script?
just comparison, i've done same in ruby , python. both exit when exit() called , output nothing.
and can't find reference exit command if can send me links...
importing module not execute module. loads memory.
\_(ツ)_/
Windows Server > Windows PowerShell
Comments
Post a Comment