Skip to contentSkip to conversation

Fix unaesthetic indentation

PATCH In review Matthew Wilcox 2 participants 4 messages Feb 15, 2021 Documentation

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Fix unaesthetic indentation

The current documentation build looks like this:

$ make htmldocs
  SPHINX  htmldocs --> file:///home/willy/kernel/linux-next/Documentation/output
make[2]: Nothing to be done for 'html'.
WARNING: The kernel documentation build process
        support for Sphinx v3.0 and above is brand new. Be prepared for
        possible issues in the generated output.
        $

That extra indentation before my next prompt isn't pretty. This patch fixes it, but I'm not a pythonista, and maybe there's a better way.

Documentation/conf.py +1 -1
index 5bd45d5fb0a0..8a9ed3f29cd5 100644
@@ -50,7 +50,7 @@ if major >= 3:
     sys.stderr.write('''WARNING: The kernel documentation build process
         support for Sphinx v3.0 and above is brand new. Be prepared for
         possible issues in the generated output.
-        ''')
+''')
     if (major > 3) or (minor > 0 or patch >= 2):
         # Sphinx c function parser is more pedantic with regards to type
         # checking. Due to that, having macros at c:function cause problems.
maintainer
#1 lore raw
Quoted 20 lines · Matthew Wilcox

The current documentation build looks like this:

$ make htmldocs
  SPHINX  htmldocs --> file:///home/willy/kernel/linux-next/Documentation/output
make[2]: Nothing to be done for 'html'.
WARNING: The kernel documentation build process
        support for Sphinx v3.0 and above is brand new. Be prepared for
        possible issues in the generated output.
        $

That extra indentation before my next prompt isn't pretty. This patch fixes it, but I'm not a pythonista, and maybe there's a better way.

Documentation/conf.py +0 -0
index 5bd45d5fb0a0..8a9ed3f29cd5 100644

Documentation/conf.py if major >= 3: · line 53

Quoted 5 lines
Documentation/conf.py +1 -1
@@ -50,7 +50,7 @@ if major >= 3:
     sys.stderr.write('''WARNING: The kernel documentation build process
         support for Sphinx v3.0 and above is brand new. Be prepared for
         possible issues in the generated output.
-        ''')
+''')

The alternative would be:

possible issues in the generated output.\n''')

jon

#2 lore raw
Quoted 30 lines · Jonathan Corbet
Quoted 20 lines · Matthew Wilcox

The current documentation build looks like this:

$ make htmldocs
  SPHINX  htmldocs --> file:///home/willy/kernel/linux-next/Documentation/output
make[2]: Nothing to be done for 'html'.
WARNING: The kernel documentation build process
        support for Sphinx v3.0 and above is brand new. Be prepared for
        possible issues in the generated output.
        $

That extra indentation before my next prompt isn't pretty. This patch fixes it, but I'm not a pythonista, and maybe there's a better way.

Documentation/conf.py +0 -0
index 5bd45d5fb0a0..8a9ed3f29cd5 100644

Documentation/conf.py if major >= 3: · line 53

Quoted 5 lines
Documentation/conf.py +1 -1
@@ -50,7 +50,7 @@ if major >= 3:
     sys.stderr.write('''WARNING: The kernel documentation build process
         support for Sphinx v3.0 and above is brand new. Be prepared for
         possible issues in the generated output.
-        ''')
+''')

The alternative would be:

Quoted 1 line

possible issues in the generated output.\n''')

Do you want me to submit a revised patch with that change?

maintainer
#3 lore raw
Quoted 5 lines · Matthew Wilcox
Quoted 3 lines

The alternative would be:

possible issues in the generated output.\n''')

Do you want me to submit a revised patch with that change?

No worries, I can tweak it.

Thanks,

jon