Skip to content

Commit 821de11

Browse files
authored
Fix _static folder required during release builds (#204)
1 parent 1df5344 commit 821de11

File tree

14 files changed

+77
-239
lines changed

14 files changed

+77
-239
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ Make sure your repository settings are set up to deploy from GitHub actions see:
113113
https://github.com/elastic/{your-repository}/settings/pages
114114
115115
---
116-
![docs/source/_static/img/github-pages.png](docs/source/_static/img/github-pages.png)
116+
![actions/publish/github-pages.png](actions/publish/github-pages.png)
117117
118118
---
119119
File renamed without changes.

docs-builder.sln

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ EndProject
3939
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "publish", "publish", "{CD2887E3-BDA9-434B-A5BF-9ED38DE20332}"
4040
ProjectSection(SolutionItems) = preProject
4141
actions\publish\action.yml = actions\publish\action.yml
42+
actions\publish\github-pages.png = actions\publish\github-pages.png
4243
EndProjectSection
4344
EndProject
4445
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "publish-vercel", "publish-vercel", "{A2A34BBC-CB5E-4100-9529-A12B6ECB769C}"

docs/source/_static/examples/example-xpack.actions.customHostSettings.asciidoc.md

Lines changed: 0 additions & 27 deletions
This file was deleted.

docs/source/_static/templates/settings.jinja

Lines changed: 0 additions & 76 deletions
This file was deleted.

docs/source/_static/yaml/settings.yaml

Lines changed: 0 additions & 102 deletions
This file was deleted.

docs/source/syntax/images.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,32 +19,32 @@ This feature is not currently supported in Elastic Docs V3.
1919
## Block-level images
2020

2121
```markdown
22-
![APM](/_static/img/apm.png)
22+
![APM](img/apm.png)
2323
```
2424

25-
![APM](/_static/img/apm.png)
25+
![APM](img/apm.png)
2626

2727
Or, use the `image` directive.
2828

2929
```markdown
30-
:::{image} /_static/img/observability.png
30+
:::{image} img/observability.png
3131
:alt: Elasticsearch
3232
:width: 250px
3333
:::
3434
```
3535

36-
:::{image} /_static/img/observability.png
36+
:::{image} img/observability.png
3737
:alt: Elasticsearch
3838
:width: 250px
3939
:::
4040

4141
## Inline images
4242

4343
```markdown
44-
Here is the same image used inline ![Elasticsearch](/_static/img/observability.png)
44+
Here is the same image used inline ![Elasticsearch](img/observability.png)
4545
```
4646

47-
Here is the same image used inline ![Elasticsearch](/_static/img/observability.png)
47+
Here is the same image used inline ![Elasticsearch](img/observability.png)
4848

4949
## Asciidoc syntax
5050

File renamed without changes.

src/Elastic.Markdown/Myst/Directives/DirectiveBlockParser.cs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,8 @@ protected override DirectiveBlock CreateFencedBlock(BlockProcessor processor)
7373
if (processor.Context is not ParserContext context)
7474
throw new Exception("Expected parser context to be of type ParserContext");
7575

76-
var directive = info.Trim(['{', '}', '`', ':']);
76+
var closingBracket = info.IndexOf('}');
77+
var directive = info[..closingBracket].Trim(['{', '}', '`', ':']);
7778
if (UnsupportedLookup.TryGetValue(directive, out var issueId))
7879
return new UnsupportedDirectiveBlock(this, directive.ToString(), issueId, context);
7980

@@ -156,6 +157,9 @@ public override BlockState TryOpen(BlockProcessor processor)
156157
if (line.IndexOf("{") == -1)
157158
return BlockState.None;
158159

160+
if (line.IndexOf("}") == -1)
161+
return BlockState.None;
162+
159163
return base.TryOpen(processor);
160164
}
161165

0 commit comments

Comments
 (0)