Differences
This shows you the differences between the selected revisions of the page.
| 2014-08-04 | 2014-12-03 | ||
| american spelling (martin) | parameterised powershell script (martin) | ||
| Line 6: | Line 6: | ||
| <code powershell> | <code powershell> | ||
| + | param ( | ||
| + | $localPath = "C:\backup\", | ||
| + | $remotePath = "/home/user/data/" | ||
| + | ) | ||
| + | |||
| try | try | ||
| { | { | ||
| Line 26: | Line 31: | ||
| $session.Open($sessionOptions) | $session.Open($sessionOptions) | ||
| - | $localPath = "C:\backup\" | ||
| - | $remotePath = "/home/user/data/" | ||
| - | |||
| # Synchronize files to local directory, collect results | # Synchronize files to local directory, collect results | ||
| $synchronizationResult = $session.SynchronizeDirectories( | $synchronizationResult = $session.SynchronizeDirectories( | ||