[ QUESTION ] ...Expand variable within runscript -Raw #278
-
I am attempting to wait till xmemdump completes before taking further action on the .dmp file
This works fine as the xmemdump output file in C:\ contains the current date and the hostname that was entered in the main script... However,
just gives me the count of the number of directories in C:\ instead of the size of the $mem_file_path file. How do I get the $mem_file_path variable to expand within runscript -Raw? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
You are using the wrong type of quotes for what you're trying to do: https://learn.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_quoting_rules?view=powershell-7.3 Try this: |
Beta Was this translation helpful? Give feedback.
You are using the wrong type of quotes for what you're trying to do: https://learn.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_quoting_rules?view=powershell-7.3
Try this:
(Invoke-FalconRtr runscript ('-Raw=```(Get-ChildItem {0}).length```' -f $mem_file_path) -HostId $host_id).stdout