fiduswriter / biblatex-csl-converter

A set of JavaScript converters: bib(la)tex => json, json => csl, and json => biblatex
GNU Lesser General Public License v3.0
34 stars 10 forks source link

2+ newlines should collapse to 2 #74

Closed retorquere closed 7 years ago

retorquere commented 7 years ago

In this reference

@PhdThesis{Sirbu_2008_PhDthesis,
  Title                    = {Induced excitations in some metal oxides},
  Author                   = {Sirbu, Silviu},
  School                   = {University of Groningen},
  Year                     = {2008},

  Abstract                 = {An optical spectrometer may be a tool unfamiliar to an outsider of the optics community. It can be regarded as a natural evolution of the way we perceive the surrounding environment. Light coming from the sun is reflected or transmitted by objects. The human eye, by measuring this reflected or transmitted light, gains some information about the objects themselves, such as their color, brightness, and shape. Using the same principles, an optical spectrometer is designed to gain even more information. It has a source of light used to send light on some objects, and a hi-tech detector to measure the transmitted or reflected light.
After the material has been measured, a relation needs to be established between its optical response and its main physical properties. In this thesis we consider the case of solid state materials. These are materials where the atoms are in close proximity to each other, and arranged in repetitive patterns on macroscopic distances, to make a compact structures (a good example is NaCl, kitchen salt). To establish the above mentioned relation the following procedure is followed. First the optical response (transmission, reflectivity, absorption, etc.) at each frequency in the incident light is measured. The result in quantified in terms of the so called dielectric constant of the bulk ε(∞). In a second step, this function is related to the main physical propertied of the measured solid state material, using the knowledge of this particular structure, determined before by different type of measurements, such as for instance X-ray diffraction. Today, optical spectroscopy has become one of the most important standard tools for investigating novel condensed matter materials.

The aim of the work presented in this thesis is to investigate the low energy excitation spectra and the (induced) phase transitions in transition metal oxides.}
}

there should be two newlines between materials. and The aim in the parsed structure.

retorquere commented 7 years ago

Aw, yeah! I have a post-processing workaround for this and other than that all my non-synthetic import tests pass!

retorquere commented 7 years ago

Oh yeah it would be really useful if you could release a new version to npm :)

johanneswilm commented 7 years ago

Ok. I would also be ok with adding the two line max limit in the parser. I just didn't have time today.

retorquere commented 7 years ago

No worries. What I have works, I prefer it would be done on the parser, but you've already done so much. I'm just happy with the current state of affairs, import was a huge effort but fully worth it and I'm one step further towards a working and cleaner bbt.

johanneswilm commented 7 years ago

Ok, I fixed it in the parser. And you have your new version.

johanneswilm commented 7 years ago

@retorquere I noticed we still have lots comments saying "% TODO: verify output" in the test bib-files. Does that mean that these files haven't been tested yet?

retorquere commented 7 years ago

I dropped that into every test file at some point but must admit I haven't thought about it since so I can't say what the current state on each is... but the last 911 test cases I went through one-by-one and that should be pretty good coverage (also seeing the activity in the past period).

johanneswilm commented 7 years ago

ok. well, feel free to delete them whenever you have checked a particular file

retorquere commented 7 years ago

I've cleaned up the todo comment for all the files we touched in the past week -- which happened to be all the files that had the todo comment.

johanneswilm commented 7 years ago

Ok, so should we make a new version with everything fixed now? Version 0.27 or 1.0?

retorquere commented 7 years ago

Semantically nothing has changed, right? So semver would say 0.27, although 1.0 would signify the milestone we reached better.

johanneswilm commented 7 years ago

Right. But does semver then say that all software that never changes public API should always stay < 1?

To me, 0.X signifies that the software has not yet reached production level stability. 1.x signifies that it has.

retorquere commented 7 years ago

I suppose the first is a conclusion you could draw from that :)

I'm not too hung up on semver, and I agree with the 0.x "vibe".

johanneswilm commented 7 years ago

I think rule 5 in semver kind of says that semver rules only kick in starting version 1.0.0?

retorquere commented 7 years ago

You're right, pre-1 rules are different. 1.0 it is then.

johanneswilm commented 7 years ago

done!

retorquere commented 7 years ago

I still see only 0.26.0 on npmjs?

johanneswilm commented 7 years ago

uh. I'll restart the build. Hopefully that works. Otherwise we'll have to go back to manual pushes to npm.

retorquere commented 7 years ago

Doesn't look like it did.

johanneswilm commented 7 years ago

I found the reason: Travis has upgraded everyone from precise to trusty as of September 2017. And apparently their trusty environment works slightly different and doesn't keep the development dependencies for deployment.... annoying. Working on solution now. I will like be about v. 1.0.5 that will work again.

retorquere commented 7 years ago

That's a nuisance but only a minor one for me. I don't expect new testcases before I release, and I've just peeked into my commit history and I've been at the port about two months now pretty much full time... and I'm only two thirds through before beta... so...

johanneswilm commented 7 years ago

yeah, it will be there tonight, but the version number may end up being 1.0.5 or 1.0.10 or something like that. But unless I tag a release, travis won't even try to publish it. So I made a 1.0.1, making a small adjustment that didn't work... now I made a 1.0.2 with another adjustment, etc. . I don't think there is any other way to debug it and it doesn't look like this is a common issue. Probably most have switched to trusty a while ago. I didn't know we were on precise until just now.

johanneswilm commented 7 years ago

1.0.5 has been released on npm.

retorquere commented 7 years ago

And has been picked up and (as expected) passes all my tests.