kubectl/pkg
Arda Güçlü a9dd2e4bec Preserve code blocks in templates.Normalizer (#118029)
* Preserve code blocks in templates.Normalizer

Currently, if templates.LongDesc function is invoked multiple times
for a string including a code block, this code block is converted to
invalid code block.

The reason of this issue is that blackfriday package, which templates package uses, relies on
4 * indentation to detect code blocks. This PR always preserves
4 * indentation in code blocks to always detect it code blocks in also
post invocations.

* Add indentations to test for code blocks

* Use strings.repeat for repetition

Kubernetes-commit: 0bff705acd8982e34b937116eb2016c9d6e4c4a6
2023-05-24 09:20:49 +03:00
..
apps Remove `newlineReporter` custom report 2022-06-01 13:09:47 +08:00
cmd rename err to lookupErr 2023-05-15 16:41:54 +02:00
describe Sort and limit to the describers the return (string, error) 2023-05-17 16:36:46 +00:00
drain kubectl/pkg/drain: Include namespace in evictPods return error 2023-02-07 13:10:30 -08:00
explain openapi: Make file client more easy to re-use 2023-03-28 13:40:28 -07:00
generate Clean unused generators 2021-03-03 22:47:53 +01:00
metricsutil Added --sum flag to kubectl top pod 2021-09-16 09:28:30 -04:00
polymorphichelpers Replace uses of diff.ObjectDiff with cmp.Diff 2023-03-23 11:29:01 -07:00
proxy Remove ioutil from kubectl 2022-07-30 22:31:16 +09:00
rawhttp Migrate genericclioptions.IOStreams usage to genericiooptions 2023-04-05 14:07:46 +03:00
scale Support kubectl scale --dry-run=server|client 2020-03-30 17:33:15 -04:00
scheme Replace uses of diff.ObjectDiff with cmp.Diff 2023-03-23 11:29:01 -07:00
util Preserve code blocks in templates.Normalizer (#118029) 2023-05-24 09:20:49 +03:00
validation test: fix ginkgolinter issues 2023-02-22 10:35:09 +01:00