Need help debugging GREP regular expression [closed]











up vote
-5
down vote

favorite












Write a single command including a regular expression to find all usernames and domains that eliminates duplicates, includes only the matching search hit text, excluding line numbers, and redirects the output to a text file.



Remember that a username can include letters, numbers and special characters. What I have written will run when [:punct:] is not present. Please let me know I need to fix. Thanks!



egrep -ro 'b[[:alnum:]][[:punct:]]+@[[:alnum:]][[:punct:]]+.[[:alpha:]]+b'









share|improve this question















closed as unclear what you're asking by pomsky, Zanna, wjandrea, Thomas, Tom Brossman Nov 18 at 13:58


Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.











  • 2




    We're not going to do your homework for you. What do you need help with exactly? Please read How to Ask and edit to clarify.
    – wjandrea
    Nov 16 at 2:11








  • 3




    What usernames and domains? You need to give an input sample with your desired output from it for text processing
    – Zanna
    Nov 17 at 16:53















up vote
-5
down vote

favorite












Write a single command including a regular expression to find all usernames and domains that eliminates duplicates, includes only the matching search hit text, excluding line numbers, and redirects the output to a text file.



Remember that a username can include letters, numbers and special characters. What I have written will run when [:punct:] is not present. Please let me know I need to fix. Thanks!



egrep -ro 'b[[:alnum:]][[:punct:]]+@[[:alnum:]][[:punct:]]+.[[:alpha:]]+b'









share|improve this question















closed as unclear what you're asking by pomsky, Zanna, wjandrea, Thomas, Tom Brossman Nov 18 at 13:58


Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.











  • 2




    We're not going to do your homework for you. What do you need help with exactly? Please read How to Ask and edit to clarify.
    – wjandrea
    Nov 16 at 2:11








  • 3




    What usernames and domains? You need to give an input sample with your desired output from it for text processing
    – Zanna
    Nov 17 at 16:53













up vote
-5
down vote

favorite









up vote
-5
down vote

favorite











Write a single command including a regular expression to find all usernames and domains that eliminates duplicates, includes only the matching search hit text, excluding line numbers, and redirects the output to a text file.



Remember that a username can include letters, numbers and special characters. What I have written will run when [:punct:] is not present. Please let me know I need to fix. Thanks!



egrep -ro 'b[[:alnum:]][[:punct:]]+@[[:alnum:]][[:punct:]]+.[[:alpha:]]+b'









share|improve this question















Write a single command including a regular expression to find all usernames and domains that eliminates duplicates, includes only the matching search hit text, excluding line numbers, and redirects the output to a text file.



Remember that a username can include letters, numbers and special characters. What I have written will run when [:punct:] is not present. Please let me know I need to fix. Thanks!



egrep -ro 'b[[:alnum:]][[:punct:]]+@[[:alnum:]][[:punct:]]+.[[:alpha:]]+b'






grep






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Nov 16 at 2:09









wjandrea

7,80642258




7,80642258










asked Nov 16 at 1:49









Noel

1




1




closed as unclear what you're asking by pomsky, Zanna, wjandrea, Thomas, Tom Brossman Nov 18 at 13:58


Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.






closed as unclear what you're asking by pomsky, Zanna, wjandrea, Thomas, Tom Brossman Nov 18 at 13:58


Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.










  • 2




    We're not going to do your homework for you. What do you need help with exactly? Please read How to Ask and edit to clarify.
    – wjandrea
    Nov 16 at 2:11








  • 3




    What usernames and domains? You need to give an input sample with your desired output from it for text processing
    – Zanna
    Nov 17 at 16:53














  • 2




    We're not going to do your homework for you. What do you need help with exactly? Please read How to Ask and edit to clarify.
    – wjandrea
    Nov 16 at 2:11








  • 3




    What usernames and domains? You need to give an input sample with your desired output from it for text processing
    – Zanna
    Nov 17 at 16:53








2




2




We're not going to do your homework for you. What do you need help with exactly? Please read How to Ask and edit to clarify.
– wjandrea
Nov 16 at 2:11






We're not going to do your homework for you. What do you need help with exactly? Please read How to Ask and edit to clarify.
– wjandrea
Nov 16 at 2:11






3




3




What usernames and domains? You need to give an input sample with your desired output from it for text processing
– Zanna
Nov 17 at 16:53




What usernames and domains? You need to give an input sample with your desired output from it for text processing
– Zanna
Nov 17 at 16:53















active

oldest

votes






















active

oldest

votes













active

oldest

votes









active

oldest

votes






active

oldest

votes

Popular posts from this blog

Biblatex bibliography style without URLs when DOI exists (in Overleaf with Zotero bibliography)

ComboBox Display Member on multiple fields

Is it possible to collect Nectar points via Trainline?