5 ms·
Regex is one of those tools that I use a couple times a year - usually for cleaning up lousy input data. I always end up spending a fair amount of time using t
by canada_dry 9y ago
Regex is one of those tools that I use a couple times a year - usually for cleaning up lousy input data.
I always end up spending a fair amount of time using tools like:
http://regex.inginf.units.it/ http://regex.inginf.units.it/
https://regex101.com/ https://regex101.com/
http://www.regexr.com/ http://www.regexr.com/
And of course stackoverflow.
- simlevesque 9y agoI love the fact that you can have unit tests for your regexes on regex101.
- TACIXAT 9y agoI use https://www.debuggex.com/ https://www.debuggex.com/ a lot when it's a complex expression. The visualization really helps.
- squeaky-clean 9y agoI will always keep a Windows install at the ready just for RegexBuddy. I use it mostly to take a regex and generate the code I need for it (e.g. find the first numbered group in match in javascript), without having to remember language specific details.
- rgb122 9y agoWhy don't you just learn learn Linux and pcre? What use are 2-bit windows tools? Don't fill your head with windows - a dead os walking
- dahart 9y agoI think parent said why: there's no RegexBuddy on Linux. I can see you're new, so I won't be harsh but HN isn't the place for this kind of commentary. Everyone here understands the difference between Windows and Linux. Judging and/or trolling over Windows is boring, take it over to Reddit or something.
- fapjacks 9y agoIf, however, you're into judging and/or trolling over Linux, then welcome to HN! There are tons of upvotes to be had in comments disparaging Linux.
- dahart 9y agoI'm sorry you feel that way, that sounds like maybe you've had some bad experiences here and are turning pessimistic about HN. Just because it happens doesn't mean it's universally accepted. Personally I would say exactly the same thing in response to the above comment if it was talking about Linux instead of windows and had nothing substantive to support it. Yes, you can find people who agree with any insults you want to throw out, but how about we try to be the good guys instead? Find some awesomeness here on HN -- there's a lot of that too -- and comment about it. Build something and show it off or support someone else who's built something cool. Write comments that contribute meaningfully and are positive and you will find more upvotes than you can possibly imagine, if upvotes are what you're going for. And you're right, you can find lots of upvotes (and downvotes too) by judging other people's legitimate choices without even bothering to understand them, but that doesn't make HN a better place, it doesn't help anyone learn, and it might not make you happy in the long run either, even if it's fun for you at the time. We get to decide if this place is cool and supportive and fun to play in, or lame and thorny and dangerous to share any of your thoughts for fear someone will be an ass about it and insult your choice of tools. I choose the former, and I'm happy to spread the love and request that people refrain from trying to knock others down or engage in flame wars. I generally upvote people who reply to me just as a way to say thanks for reading what I wrote and engaging with me. Here's one for you. I hope you'll find more peace on HN and get exposure to more of the positive side of it. There are some incredibly amazing people here, and it's true there are also some destructive forces too. I hope you can let the crap roll off and seek out more of the good stuff!
- fapjacks 9y agoThis pipe dream is what drew me to HN ten years ago. And while there are specifically rules against drawing comparisons between HN and reddit, years ago, the parallel made sense. These days, being totally honest, I find reddit to be more approachable and friendly and informative in the types of subreddits I read than HN, the vast majority of times. The reason I keep coming back to HN is for the once-in-a-blue-moon comments which blow your mind. If those comments stopped happening, or if they started happening on reddit, I'd never come back. There is absolutely a creed which is the centerline of HN, and deviation from it -- even totally reasonable, level-headed deviation -- is often punished with downvotes into invisibility. I've specifically created a Chrome browser extension to remove all point/color information from post comments -- and recently uploaded it to Github [0] -- just to keep my own voting habits from being influenced by this brutal kraken of sameness that exists on HN. My post above is a little bit tongue-in-cheek, but in my experience, one of the subjects you can most find downvotes with is the classic win/*nix flamewar. Even something totally reasonable and said in a straightforward, matter-of-fact way which promotes something about Linux in a thread about Windows is annihilated. Unwanted facts and differing viewpoints are erased from existence. That's HN, even if there's some silver lining in there occasionally. [0] https://github.com/fapjacks/antihnbs https://github.com/fapjacks/antihnbs
- eru 9y agoPerl compatible regular expressions are not regular expressions at all. (https://en.wikipedia.org/wiki/Regular_expression#Formal_definition https://en.wikipedia.org/wiki/Regular_expression#Formal_defi...)
- rgb122 9y agoWhy don't you just learn learn Linux and pcre? What use are 2-bit windows tools? Don't fill your head with windows - a dead os walking
- vacri 9y agoAs I get more experienced in operations, I find regex to be more and more invaluable. I used to dread doing a regex, now I get enjoyment out of sorting out a tricky one.
- rosstex 9y agoThat first link, oh my god! I can have some fun with this.
- Drdrdrq 9y agoReally? I use it fairly often, usually for cleaning input data and similar. But I only use a subset of regex functionalities that works across different engines and that doesn't make problems with escaping strings (no backslashes and similar).
- seven800 9y agoYou might also be interested in a tool I made which generates random strings that match a given regex: http://regexicon.com/ http://regexicon.com/ Very useful when code reviewing other people's regular expressions.