Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sed compat #718

Merged
merged 2 commits into from
Apr 15, 2019
Merged

sed compat #718

merged 2 commits into from
Apr 15, 2019

Conversation

fisx
Copy link
Contributor

@fisx fisx commented Apr 15, 2019

On Linux, both variants have the same output, but on mac, allegedly only the second one works:

$ echo '{"email":"l8TVlbK0@example.com","locale":"en","accent_id":0,"picture":[],"name":"demo","id":"29740ea6-c54a-4a92-8fd5-3f8c5b05cdc3","assets":[]}' | sed 's/.*"id":"\([0-9a-z-]\+\)".*/\1/'
$ echo '{"email":"l8TVlbK0@example.com","locale":"en","accent_id":0,"picture":[],"name":"demo","id":"29740ea6-c54a-4a92-8fd5-3f8c5b05cdc3","assets":[]}' | sed 's/.*\"id\":\"\([a-z0-9-]*\)\".*/\1/'

See #712 (thanks @limengyu1990!)

@neongreen
Copy link
Contributor

neongreen commented Apr 15, 2019

$ echo '{"email":"l8TVlbK0@example.com","locale":"en","accent_id":0,"picture":[],"name":"demo","id":"29740ea6-c54a-4a92-8fd5-3f8c5b05cdc3","assets":[]}' | sed 's/.*\"id\":\"\([a-z0-9-]*\)\".*/\1/'
29740ea6-c54a-4a92-8fd5-3f8c5b05cdc3

I have a Mac and I approve this message.

@fisx fisx merged commit 1820364 into develop Apr 15, 2019
@fisx fisx deleted the fisx-sed-compat branch April 15, 2019 14:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants