gautamdhameja / medium-2-md

A CLI tool that converts exported Medium posts (html) to Jekyll/Hugo compatible markdown with front matter.
https://www.npmjs.com/package/medium-2-md
Apache License 2.0
142 stars 19 forks source link

Get parameters are breaking file name generation #5

Closed alexanderadam closed 5 years ago

alexanderadam commented 5 years ago

I just copied an URL from medium that contains a (weird) GET parameter:

https://medium.com/@benlaurie_18378/how-to-ruin-a-perfectly-good-container-d33250fca595?source=---------2------------------

When trying to archive it:

$ medium-2-md convertUrl 'https://medium.com/@benlaurie_18378/how-to-ruin-a-perfectly-good-container-d33250fca595?source=---------2------------------' -o .

The file will be called .md (and therefore hidden on *NIX systems).

PS: Maybe it could be fixed together with #4

gautamdhameja commented 5 years ago

I think this issue should have been only with convertUrl and not with convertLocal. Fixed in v0.4.1. https://www.npmjs.com/package/medium-2-md/v/0.4.1