zakhenry / embedme

Utility for embedding code snippets into markdown documents
MIT License
229 stars 38 forks source link

README.md#L57-L60 No comment detected in first line for block with extension yaml #106

Open cmoulliard opened 1 month ago

cmoulliard commented 1 month ago

Issue

The command npx embedme README.md reports top of my README.md file that no comments exist

Embedding...
Skipped 0 files ignored in '.gitignore'
  Analysing README.md...
   README.md#L20-L22 No comment detected in first line for block with extension bash
   README.md#L28-L39 No comment detected in first line for block with extension bash
   README.md#L41-L43 No comment detected in first line for block with extension bash
   README.md#L57-L60 No comment detected in first line for block with extension yaml
   README.md#L62-L64 No comment detected in first line for block with extension bash
   README.md#L66-L90 No comment detected in first line for block with extension yaml
   README.md#L93-L111 No comment detected in first line for block with extension bash
   README.md#L113-L256 No comment detected in first line for block with extension yaml
   README.md#L261-L289 No comment detected in first line for block with extension bash
   README.md#L291-L649 No comment detected in first line for block with extension yaml
   README.md#L653-L663 No comment detected in first line for block with extension bash
   README.md#L668-L675 No comment detected in first line for block with extension bash
   README.md#L677-L690 No comment detected in first line for block with extension bash
  No changes to write for README.md

while the comment is well defined

##### Simple pipeline with script embedded

```yaml
// configurations/tekton/simple-job-embedded-script-cfg.yaml

I'm using the following version of the tool: 1.22.1

zakhenry commented 1 month ago

the library expects comment formatting to match the format of the language being embedded, so in this case if you substitute // with # it should work for yaml files.

cmoulliard commented 1 month ago

Such a feature is not documented at all as all the examples use // ;-)