If I remove the >g then it outputs fine, but I want to redirect to a file called g.
Notice that it -works- when I remove the >g
Code: Select all
W:\>echo "f" | grep -oP "(?=\")."
"
"
W:\>echo dsftree="f"dfd | grep -oP "(?=\")."
"
"
W:\>echo a"f"a | grep -oP "(?=\")."
"
"
W:\>
I just want to redirect that output into a file.
This is not a regex question.
What is going on here that the redirect fails?
Code: Select all
W:\>echo "f" | grep -oP "(?=\")." >g
grep: >g: Invalid argument
The process tried to write to a nonexistent pipe.
W:\>echo a"f"a | grep -oP "(?=\")." >g
grep: >g: Invalid argument
The process tried to write to a nonexistent pipe.
W:\>echo dsftree="f"dfd | grep -oP "(?=\")." >g
grep: >g: Invalid argument
W:\>
--
Code: Select all
W:\>(echo dsftree="f"dfd | grep -oP "(?=\")." )
." ) was unexpected at this time.
W:\>
Code: Select all
W:\>(echo dsftree="f"dfd | grep -oP "(?=\").") >g
.") >g was unexpected at this time.
W:\>