-
-
Notifications
You must be signed in to change notification settings - Fork 3
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
Add the ability to parse a line with a link and a description #13
Add the ability to parse a line with a link and a description #13
Conversation
I tried it with:
And go test failed. Can we test what happens if there is no description too? |
Sure ... working on it |
Speaking of using this PR to solve nikitavoloboev/alfred-learn-anything#9, are you on mac or windows. And if on mac, do you have Alfred? :) |
I'm on Mac ... but I don't have Alfred |
Also, can you take a look at nikitavoloboev/license-up#28 |
When we don't have a description, the regex completely changes ... how exactly do you want to go about checking if there is a description. Regex for link without description: |
It has to be all encompassing. The use case if to parse a file like this: https://github.com/learn-anything/books And extract all the links (books + # Other) inside the file to some data structure. |
If there is no description, it should only return the title and URL (those are bound to be there). |
That's a shame. It's a pretty amazing tool. Would definitely recommend. 🚀 There's lots of workflows for it too https://github.com/learn-anything/alfred-workflows#readme |
I know it's an amazing tool ... but the problem is that they charge for workflows |
Can send your PayPal, I can sponsor a license for you. 🙂 |
I don't have a PayPal account ... thank you though, that's very kind of you! |
Should we change the function name from |
yes |
And do the error handling there in case there is no description. I believe there is none currently. |
There should be a test case called |
Or maybe just |
Doing that now |
@nikitavoloboev How does it look now? |
Works great. Awesome! |
Great! So is it now usable for your knowledge and other projects? |
Will have to check. Will need few minutes/hours. 😅 |
Got it |
Actually for nikitavoloboev/knowledge#25 it won't work as Imgur link embeds are of different format. Will have to write code specifically for parsing image embeds.
^ Is image embed. |
I see ... you can probably just copy and paste the code for I can try to do this if you'd like |
Opened #15 |
Here's a rough draft ... tell me what you think