larsgw / citation.js

Citation.js converts formats like BibTeX, Wikidata JSON and ContentMine JSON to CSL-JSON to convert to other formats like APA, Vancouver and back to BibTeX.
https://citation.js.org/
MIT License
226 stars 30 forks source link

Handle string BibTeX month field from Mendeley #92

Closed baip closed 7 years ago

baip commented 7 years ago

BibTeX exported from Mendeley has months in textual form ("jan", "sep", etc.).

codecov-io commented 7 years ago

Codecov Report

Merging #92 into master will decrease coverage by 0.34%. The diff coverage is 25%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #92      +/-   ##
==========================================
- Coverage   82.53%   82.19%   -0.35%     
==========================================
  Files          60       60              
  Lines         859      865       +6     
==========================================
+ Hits          709      711       +2     
- Misses        150      154       +4
Impacted Files Coverage Δ
src/parse/csl.js 61.29% <25%> (-3%) :arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update cb93044...beac596. Read the comment docs.

larsgw commented 7 years ago

Sorry for the late response, and thanks for the idea (and the PR)! I think I'll change some things and merge it with dd1a7d7d9afe02ac3a901bd2b4de8c4f107ee4da first. Some more specific feedback:

larsgw commented 7 years ago

Isn't this fixed in 0.3.4 by dd1a7d7d9afe02ac3a901bd2b4de8c4f107ee4da? (see issue #92)

baip commented 7 years ago

Thanks for getting back on the PR, @larsgw! Glad to know you were tracking it on issue #80 , but it looks like that https://github.com/larsgw/citation.js/commit/dd1a7d7d9afe02ac3a901bd2b4de8c4f107ee4da was not merged in 0.3.4. Anyway the 0.3.4 version I installed from npm did not parse the month entry (e.g., "jan", "oct" exported from Mendeley) correctly. And yes, mine was not a pretty fix.. I did a quick browsing of the code in order to make it work for my use case. I appreciate your kind feedback. This is a really great library for handling citation data. Thank you!

larsgw commented 7 years ago

Oh right, that commit is actually on the dev/io branch (don't know how I missed that). Currently the development of #88 is basically blocking any new release, but I might be able to transfer some older commits to master before and release anyway.

baip commented 7 years ago

It is no hurry for me. I just pointed package.json to my forked repo in that particular project. I'll just switch when you release. Thanks again for being responsive on the PR!