Anyone into RegEx?
#1

I need a few made for something I am working on...
Reply
#2

http://regexr.com/

RegExr is an online tool to learn, build, & test Regular Expressions (RegEx / RegExp).
Reply
#3

Yea, I'm asking if someone is capable in it, not asking for links that you just picked up from ******.
Reply
#4

Isnt hard to assemble regexes. I could help though.
Reply
#5

Quote:
Originally Posted by Sew_Sumi
Посмотреть сообщение
Yea, I'm asking if someone is capable in it, not asking for links that you just picked up from ******.
...to learn...

I didn't pick it up from ******, I've used the site before. And for your information, the site is fairly complete. It has expressions community members made, references to help you create your own expressions, shows you hints, what you did wrong, if there's an error in your expression, etc.

Give a guy a fish and he's set for a day, teach him how to fish and he's set for the rest of his life. That was mainly my intention, you don't need assistance if you got all you need on one site.
Reply
#6

Quote:
Originally Posted by CheezIt
Посмотреть сообщение
...to learn...

I didn't pick it up from ******, I've used the site before. And for your information, the site is fairly complete. It has expressions community members made, references to help you create your own expressions, shows you hints, what you did wrong, if there's an error in your expression, etc.

Give a guy a fish and he's set for a day, teach him how to fish and he's set for the rest of his life. That was mainly my intention, you don't need assistance if you got all you need on one site.
Yea yea, I'm not looking to learn it, I need 3 regexs made that are relatively basic, but aren't covered in examples, or shared solutions. This is part of a bigger project, and again, I'd rather not learn it as it's such a small component.

I'll shoot that high horse down, as if it was never meant to be...
Reply
#7

Quote:
Originally Posted by Sew_Sumi
Посмотреть сообщение
Yea yea, I'm not looking to learn it, I need 3 regexs made that are relatively basic, but aren't covered in examples, or shared solutions. This is part of a bigger project, and again, I'd rather not learn it as it's such a small component.

I'll shoot that high horse down, as if it was never meant to be...
Basic yet you can't do it on your own, or don't want it (still yet basic...). Sad.
Reply
#8

Quote:
Originally Posted by CheezIt
Посмотреть сообщение
Basic yet you can't do it on your own, or don't want it (still yet basic...). Sad.
Basic, yet I'd rather not spend the time, learning a language, just for 3 friggen lines... Now stop spamming/postwhoring/trolling/whatever the fuck you think you are doing, and jog on...
Reply
#9

Quote:
Originally Posted by CheezIt
Посмотреть сообщение
Basic yet you can't do it on your own, or don't want it (still yet basic...). Sad.
Honestly man all of your posts generally are alike and full of the same condescending bullshit that you've been derailing threads with for the past two weeks

You actually remind me of someone who apparently "quit" a while back lmfao

just stop
Reply
#10

Quote:
Originally Posted by CheezIt
View Post
And you have to have someone else write those 3 basic friggen lines for you instead? What you ned is given to you, now stop being lazy and start writting!!!
Maybe he doesn't have the time or desire to learn, why bother if you see yourself only using it for 3 lines of code?
Reply
#11

And you can't just post the lines you need to match here? Or an example of what should be matched? Get to the point.
Reply
#12

Quote:
Originally Posted by Vince
View Post
And you can't just post the lines you need to match here? Or an example of what should be matched? Get to the point.
I am to the point...

I'm wanting the pawno error messages regexed.

Code:
C:\Users\Fudge\Desktop\samp037_svr_R2-1-1_win32\filterscripts\errors.pwn(27) : warning 217: loose indentation
Code:
C:\Users\Fudge\Desktop\samp037_svr_R2-1-1_win32\gamemodes\LSTDM1.pwn(4760) : error 021: symbol already defined: "strtok"
So in this case, it would come out with
Code:
C:\Users\Fudge\Desktop\samp037_svr_R2-1-1_win32\gamemodes\LSTDM1.pwn 4760 021 symbol already defined: "strtok"
So it can give the complete filename, error line, error number and the message.

Same with a warning line.


There will be others, but the basic file/line number/message is fine for the minute.

The filename in particular should also recognize \\LANMGR\Share\ as well as D:\SAMP\

Minus the braces of course around the line number.
Reply
#13

The time you wasted to write this thread, you could have learned regular expressions by yourself instead.
Reply
#14

Quote:
Originally Posted by BigETI
View Post
The time you wasted to write this thread, you could have learned regular expressions by yourself instead.
Again, not interested in this response. Go spam elsewhere.
Reply
#15

Fairly straight forward and something like this should do:
Code:
/^(.+)\((\d+)\) : (warning|error|fatal error) (\d+): (.+)$/ig
Code:
$1: path
$2: line number
$3: class (warning, error or fatal error)
$4: error/warning number
$5: message
Reply
#16

Cheers for that Vince, seems like it has something with it.

When I'm getting a response from an output, I get nothing in all, except for the Error number, instead of being in 4, is in 3.

(.+) The compiler logs I think don't have endline between the filename and the (error). They also seem to only have the endline in them, not a clear line.


Are there any command line switches to change the output of pawncc at all?
Reply
#17

AgAiN, nOt InTeReStEd In ThIs ReSpOnSe. Go SpAm ElSeWhErE.
Reply
#18

Quote:
Originally Posted by BigETI
View Post
AgAiN, nOt InTeReStEd In ThIs ReSpOnSe. Go SpAm ElSeWhErE.
Sorry but the only sign language I know is...



Maybe that will help you on your way to a new, healthier you...
Reply
#19

My health condition was fine, until now. Thank you.
Reply
#20

Quote:
Originally Posted by Vince
View Post
Fairly straight forward and something like this should do:
Code:
/^(.+)\((\d+)\) : (warning|error|fatal error) (\d+): (.+)$/ig
Code:
$1: path
$2: line number
$3: class (warning, error or fatal error)
$4: error/warning number
$5: message
That will work well, but only for a single error. You forgot the multiline parameter to check line-by-line

Code:
/^(.+)\((\d+)\) : (warning|error|fatal error) (\d+): (.+)$/igm
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)