For those interested, think there needs to be corrections, have neat trivia, or have some things to say: COMMENTS ARE ENCOURAGED!!!
Ugh, I forgot my book at home. But that's okay, because Cailin provided me with links to her web site and some notes he made. It's not in the order the book was, but I know kind of where I left off.
Regular expressions. You know, I use these a lot, but mostly for globbing (the ubiquitous *). Once in a while, in Perl, I use the "RegEx" set to make decisions. But I don't have a lot of stuff committed to memory, and especially not BASH, because when I do RegEx, I usually do it in Perl, but in either case, I often just look up what I need, cut and paste, and then forget it. This is why I am still a low-class programmer. I have issues with ever basic commands. I always get the caret (^) mixed up, for instance:
^n - matches start of string that begins with n
[^n] - matches any string NOT containing just n
The first part works, the next one does not work like I expect. I keep thinking it's going to work like "grep -v" but it doesn't. I think it's a "complete line" thing. I did a lot of testing with this stupid thing, and made a file containing 3 lines:
ABC abc xyz
If I did an egrep ^A I got just the 1st line, which is what I expected. If I did an egrep [^A], all 3 lines showed up. I expected the 1st line not to. But I think the [^A] means "the whole line," because when I added a 4th line that simply said "A", it didn't show up in either egrep. And to prove this theory, I did egrep [^ABC], and to my surprise, neither the 1st OR 4th lines showed up! In addition, a egrep [^CBA] had the same result. So I am just not "getting" this at all. Is is an "both and/or" situation, like a "super-and?" I added a 5th line, and made it simply "B." egrep [^CBA] excluded it, but egrep [^BA] showed the 1st line, "ABC" which seems to support my theory of "super-and."
This needs more meditation for my teeny, teeny brain.
Disclaimer: While I have been managing Linux systems for almost 10 years now, but I am mostly self-taught. I have a RHCT certification, but I am taking the LPI and CompTIA Linux+ exams to "flesh out" some of the gaps that occur from too much real-world experience versus my lack of good old fashioned book learnin'. This entry in no way assures you my thoughts are correct, I will have frequent misspellings, and they may or may not help you pass the LPI. HUGE parts of the exam will be missing because I already know half of it by heart, so using me as your only study guide is a terrikle idea. Please read this entry with a healthy amount of skepticim, and PLEASE feel free to correct or add comments! My ego is hardy enough to admit when I am wrong.