1

I have a python file that creates commands to run. My example command is

mycmd tags add --name email --regex [\\w-\\.]+@([\\w-]+\\.)+[\\w-]{2,4}

In python file, I'm getting name and regex args using this code.

name = self.args.name
regex = self.args.regex

I get this error. zsh: no matches found: [\w-\.]+@([\w-]+\.)+[\w-]2 How would I get rid of this error and pass regex string?

1 Answer 1

1

just enclosed your regex in " " such as
mycmd tags add --name email --regex "[\\w-\\.]+@([\\w-]+\\.)+[\\w-]{2,4}"
It works for me on zsh

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.