{"action":"opened","issue":{"url":"https://api.github.com/repos/MSOpenTech/redis/issues/451","repository_url":"https://api.github.com/repos/MSOpenTech/redis","labels_url":"https://api.github.com/repos/MSOpenTech/redis/issues/451/labels{/name}","comments_url":"https://api.github.com/repos/MSOpenTech/redis/issues/451/comments","events_url":"https://api.github.com/repos/MSOpenTech/redis/issues/451/events","html_url":"https://github.com/MSOpenTech/redis/issues/451","id":150892509,"number":451,"title":"redis-cli output stdout","user":{"login":"jgranduel","id":586675,"avatar_url":"https://avatars.githubusercontent.com/u/586675?v=3","gravatar_id":"","url":"https://api.github.com/users/jgranduel","html_url":"https://github.com/jgranduel","followers_url":"https://api.github.com/users/jgranduel/followers","following_url":"https://api.github.com/users/jgranduel/following{/other_user}","gists_url":"https://api.github.com/users/jgranduel/gists{/gist_id}","starred_url":"https://api.github.com/users/jgranduel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jgranduel/subscriptions","organizations_url":"https://api.github.com/users/jgranduel/orgs","repos_url":"https://api.github.com/users/jgranduel/repos","events_url":"https://api.github.com/users/jgranduel/events{/privacy}","received_events_url":"https://api.github.com/users/jgranduel/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-04-25T15:06:10Z","updated_at":"2016-04-25T15:06:10Z","closed_at":null,"body":"Hi, \r\n\r\nin PowerShell, how to capture output for other processing within a pipe as $_ or a variable ?\r\nFor example, to emulate Bash command \r\n\r\n    [bash] $ redis-cli SCAN 0 match \"prefix:*\" | xargs redis-cli DEL\r\n\r\n    [PowerShell] PS4> redis-cli.exe --scan --pattern \"prefix:*\"\r\n    prefix:a\r\n    prefix:b\r\n    ...\r\n    PS4> $result = redis-cli.exe --scan --pattern \"prefix:*\"\r\n    $result -eq $null\r\n    True\r\n    PS4> $result = redis-cli.exe --scan --pattern \"prefix:*\" | % { $_ }\r\n    no result\r\n  \r\nThanks for any tip.\r\nBest regards\r\n\r\n\r\n"}}