Timeline for Remove multiple regular expressions from variable with sed
Current License: CC BY-SA 3.0
4 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Feb 3, 2017 at 15:52 | comment | added | Joshua Schaeffer | I found the reason, it was because the regex only looks for left and right quotes and /proc/1/exe uses regular apostrophes on the system I tested with systemd. I just added \x27 and it worked. I'm not sure why some systems I get one or the other or both, but as long as I include both in the character set it works. | |
| Feb 3, 2017 at 7:18 | comment | added | Michael Vehrs | @JoshuaSchaeffer I find that surprising, since I wrote and tested my solution on a system using systemd. | |
| Feb 2, 2017 at 16:56 | comment | added | Joshua Schaeffer | This works well on systems with sysvinit on it. For some reason I don't get any results when /proc/1/exe links to /lib/systemd/systemd/. I'm trying to dig into that now. | |
| Feb 2, 2017 at 8:02 | history | answered | Michael Vehrs | CC BY-SA 3.0 |