Closed halcyon closed 8 years ago
Hello,
Thanks for the PR, i need some time to ingest it though.
In your description, I don't get the expression front-matter
you keep using, can you please clarify it? Thanks.
Ah do you mean front-related
?
Antoine, I apologize for not submitting this pull request for you to look over sooner. I have been ill, and have only recently recovered.
No problem.
I had a use case similar to that of the other person who needed to be able to use customized front-matter. As I dug into the issue, I did some refactoring that you might find beneficial.
- ... org2jekyll doesn't have to be updated to accomodate this.
That's good, indeed.
- Org special lines are parsed directly from the buffer in a generalized way, and only from the top of the buffer where they relate to front-matter.
I don't understand this sentence. Can you please also clarify?
- Data-driven approach gives us the ability to test directly without mocks, resulting in tests that can be more concise, readable and maintainable.
Good point.
Cheers,
Thanks for the PR, i need some time to ingest it though.
Thanks for your quick response, I appreciate you taking the time to look it over and discuss.
I don't get the expression front-matter you keep using, can you please clarify it
Yes, front matter is the YAML at the top of Jekyll pages.
Org special lines are parsed directly from the buffer in a generalized way, and only from the top of the buffer where they relate to front-matter.
Org special lines are described in the Org manual as, "...lines in the buffer to define settings on a per-file basis. These lines start with a ‘#+’ followed by a keyword, a colon, and then individual words defining a setting." While they serve a similar purpose as Jekyll's front matter, they differ in that they can also be used anywhere in an Org document for things that wouldn't make sense to set globally for the entire document - such as syntax highlighting some source code in the middle of the document with #+BEGIN_SRC: and #+END_SRC:.
As a result of this, it would make sense to only retrieve the Org special lines that are at the top of the document - where they are analogous to front matter. This is important, because you wouldn't want properties relating only to formatting a section of an Org document to be copied into the Jekyll front matter. Searching only the top of the document should also yield a nominal performance improvement.
Currently, only predefined Org special lines are found. In the PR I've added a regular expression that will find any Org special line - this is what I meant by it being more generalized.
Thanks for your quick response, I appreciate you taking the time to look it over and discuss.
Well, how can we achieve improvments without discussion?
^^
Yes, frontmatter is the YAML at the top of Jekyll pages.
Thanks for the explanation and the link. I did not read all of jekyll's manual indeed. It did not even occur to me it was a jekyll term.
Org special lines are described in the Org manual as, ...
Thanks. I thought i took care of that. I need to take a closer look at your PR. If i recall correctly though, my approach may have been naive ^^
Searching only the top of the document should also yield a nominal performance improvement.
Indeed.
Currently, only predefined Org special lines are found. In the PR I've added a regular expression that will find any Org special line - this is what I meant by it being more generalized.
Ok... Ah yes, i see now. Indeed.
Thus your initial remark org2jekyll doesn't have to be updated to accomodate this.
.
Do you think you can take a stab at rebasing to the latest code or is it too much of a hassle?
Thanks anyway.
Sure, I can do that. Would you be ok with me removing the recently added extra-yaml feature when I rebase? I'll also break the changes up into smaller commits so it's easier to examine.
Would you be ok with me removing the recently added extra-yaml feature when I rebase?
Sure, we'll need to update the readme accordingly (either you or me).
Cool, sounds good - team work! 😃
Cool, sounds good - team work! :smiley:
Indeed ^^
cf. #41 for the follow-up.
Antoine, I apologize for not submitting this pull request for you to look over sooner. I have been ill, and have only recently recovered.
I had a use case similar to that of the other person who needed to be able to use customized front-matter. As I dug into the issue, I did some refactoring that you might find beneficial.
Notable changes
Looking forward to your thoughts.