Skip to content

Conversation

@thaJeztah
Copy link
Member

fixes #11331
replaces / closes #12064

Some flag descriptions contain point-brackets to indicate required options, e.g.:

--ssh stringArray   SSH agent socket or keys to expose to the build (format: default|<id>[=<socket>|<key>[,<key>]])

When rendering those options as HTML, those options were not visible as
they were rendered as a HTML element.

Given that flag-descriptions are not expected to have MarkDown or HTML
formatting, we can HTML-escape them to prevent this.

This patch escapes the flag-descriptions using liquid's esacape command.

Before this patch:

Screenshot 2021-01-12 at 16 20 38

After this patch:

Screenshot 2021-01-12 at 16 20 16

@thaJeztah
Copy link
Member Author

@usha-mandya @StefanScherer PTAL

StefanScherer
StefanScherer previously approved these changes Jan 13, 2021
Copy link
Member

@StefanScherer StefanScherer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@thaJeztah
Copy link
Member Author

Hmm, Netlify failed; doesn't look related, but not sure how to restart it

Gem::RemoteFetcher::FetchError: bad response Gateway Error 502 (https://rubygems.org/gems/ruby2_keywords-0.0.2.gem)
  /opt/buildhome/.rvm/rubies/ruby-2.3.6/lib/ruby/site_ruby/2.3.0/rubygems/remote_fetcher.rb:274:in `fetch_http'
  /opt/buildhome/.rvm/rubies/ruby-2.3.6/lib/ruby/site_ruby/2.3.0/rubygems/remote_fetcher.rb:292:in `fetch_path'
  /opt/buildhome/.rvm/rubies/ruby-2.3.6/lib/ruby/site_ruby/2.3.0/rubygems/remote_fetcher.rb:327:in `cache_update_path'

@thaJeztah thaJeztah closed this Jan 13, 2021
@thaJeztah thaJeztah reopened this Jan 13, 2021
@thaJeztah
Copy link
Member Author

close/reopen didn't seem to trigger it again; let me rebase/push

Some flag descriptions contain point-brackets to indicate required
options, e.g.:

    --ssh stringArray   SSH agent socket or keys to expose to the build (format: default|<id>[=<socket>|<key>[,<key>]])

When rendering those options as HTML, those options were not visible as
they were rendered as a HTML element.

Given that flag-descriptions are not expected to have MarkDown or HTML
formatting, we can HTML-escape them to prevent this.

This patch escapes the flag-descriptions using liquid's `esacape` command.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
@netlify
Copy link

netlify bot commented Jan 13, 2021

✔️ Deploy preview for docsdocker ready!

🔨 Explore the source changes: ac39688

🔍 Inspect the deploy logs: https://app.netlify.com/sites/docsdocker/deploys/5ffec14dd22ca500070cbc17

😎 Browse the preview: https://deploy-preview-12083--docsdocker.netlify.app

@thaJeztah
Copy link
Member Author

All green now; @StefanScherer @usha-mandya ptal 🤗

Copy link
Member

@usha-mandya usha-mandya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks @thaJeztah

@usha-mandya usha-mandya merged commit be15606 into docker:master Jan 13, 2021
@thaJeztah thaJeztah deleted the fix_flag_descriptions branch January 13, 2021 10:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Incorrect HTML output

3 participants