Differences

This shows you the differences between the selected revisions of the page.

2018-02-20 2018-02-23
5.13 Extensions metadata can span multiple lines (martin) test for empty text (martin)
Line 21: Line 21:
#                  -pause -sessionLogPath "%SessionLogPath%" #                  -pause -sessionLogPath "%SessionLogPath%"
# @description  Searches recursively for a text in the current remote directory # @description  Searches recursively for a text in the current remote directory
-# @version      5+# @version      6
# @homepage    ~~SELF~~ # @homepage    ~~SELF~~
# @require      WinSCP 5.13 # @require      WinSCP 5.13
Line 44: Line 44:
try try
{ {
 +    if (!$text)
 +    {
 +        throw "No Text was specified."
 +    }
 +
    # Load WinSCP .NET assembly     # Load WinSCP .NET assembly
    $assemblyPath = if ($env:WINSCP_PATH) { $env:WINSCP_PATH } else { $PSScriptRoot }     $assemblyPath = if ($env:WINSCP_PATH) { $env:WINSCP_PATH } else { $PSScriptRoot }

Last modified: by martin