find: incomplete statement or Argument for -c ends in backslash. Here's an example of how to do it with some Perl variable substitutions thrown in. Nothing Earth-shattering, but if it saves someone five minutes, it's worth posting.
# in my actual code, I had "rm" instead of "ls -l", but I figured this + would be safer in an example. system "/usr/local/bin/ssh $remote \"find $base_dir -mtime +$days -exe +c ls -l \\{} \\;\"" and warn "system: ssh: $!";
In reply to Run system find -exec on remote machine by gaal
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |