Skip to contentSkip to conversation

KUnit: Docs: style: fix some Kconfig example issues

PATCH Superseded Randy Dunlap 2 participants 4 messages Oct 27, 2020 – Oct 29, 2020

Subsystems (4)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

Randy Dunlap

author reviewer
#0 lore raw

PATCH 1/1 KUnit: Docs: style: fix some Kconfig example issues

Fix the Kconfig example to be closer to Kconfig coding style. (Except that it still uses spaces instead of tabs for indentation; I guess that Sphinx wants it that way.)

Also add punctuation and a trailing slash ('/') to a sub-directory name -- this is how the text mostly appears in other Kconfig files.

---
 Documentation/dev-tools/kunit/style.rst |    8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
Documentation/dev-tools/kunit/style.rst +4 -4
@@ -180,12 +180,12 @@ An example Kconfig entry:
                 depends on KUNIT
                 default KUNIT_ALL_TESTS
                 help
-                    This builds unit tests for foo.
+                  This builds unit tests for foo.
 
-                    For more information on KUnit and unit tests in general, please refer
-                    to the KUnit documentation in Documentation/dev-tools/kunit
+                  For more information on KUnit and unit tests in general, please refer
+                  to the KUnit documentation in Documentation/dev-tools/kunit/.
 
-                    If unsure, say N
+                  If unsure, say N.
 
 
 Test File and Module Names
Reviewed-by on v1 1/1
#1 lore raw
Quoted 8 lines · Randy Dunlap

Fix the Kconfig example to be closer to Kconfig coding style. (Except that it still uses spaces instead of tabs for indentation; I guess that Sphinx wants it that way.)

Also add punctuation and a trailing slash ('/') to a sub-directory name -- this is how the text mostly appears in other Kconfig files.

Quoted 8 lines

---

Thanks for fixing this!

For what it's worth, I _think_ we could get away with tabs for indentation in the file without Sphinx actually complaining, but it does annoy some of the editors, and as far as I can tell, Sphinx converts them back to spaces in its output. I'm far from an expert, though...

Regardless, this is:

-- David

author reviewer
#2 lore raw
Quoted 26 lines · David Gow
Quoted 8 lines · Randy Dunlap

Fix the Kconfig example to be closer to Kconfig coding style. (Except that it still uses spaces instead of tabs for indentation; I guess that Sphinx wants it that way.)

Also add punctuation and a trailing slash ('/') to a sub-directory name -- this is how the text mostly appears in other Kconfig files.

Quoted 8 lines

---

Thanks for fixing this!

For what it's worth, I _think_ we could get away with tabs for indentation in the file without Sphinx actually complaining, but it does annoy some of the editors, and as far as I can tell, Sphinx converts them back to spaces in its output. I'm far from an expert, though...

Quoted 3 lines

Regardless, this is:

I tested with tabs for indentation and it's no problem with Sphinx. Some editors care? I am surprised. and don't much care.

I would be happy to submit a v2 using tabs for indentation.

thanks.

Signature · 1 line
~Randy
#3 lore raw
Quoted 28 lines · Randy Dunlap
Quoted 26 lines · David Gow
Quoted 8 lines · Randy Dunlap

Fix the Kconfig example to be closer to Kconfig coding style. (Except that it still uses spaces instead of tabs for indentation; I guess that Sphinx wants it that way.)

Also add punctuation and a trailing slash ('/') to a sub-directory name -- this is how the text mostly appears in other Kconfig files.

Quoted 8 lines

---

Thanks for fixing this!

For what it's worth, I _think_ we could get away with tabs for indentation in the file without Sphinx actually complaining, but it does annoy some of the editors, and as far as I can tell, Sphinx converts them back to spaces in its output. I'm far from an expert, though...

Quoted 6 lines
Quoted 3 lines

Regardless, this is:

I tested with tabs for indentation and it's no problem with Sphinx. Some editors care? I am surprised. and don't much care.

Neat!

As for editors, I think it was just some aggressively set per-filetype defaults, so I'm not particularly concerned either.

Quoted 1 line

I would be happy to submit a v2 using tabs for indentation.

That sounds good to me if it works, thanks!

Cheers,
-- David