forked from amazingfate/help
tdf#152323 drop name attribute from <link> elements
Replacement done with
find . -name \*.xhp -print0 |xargs -0 -P 0 perl -CS -pi -e \
's#(<link[^>]*?) +name *="[^"]*" *( [^>]+|) *>#$1$2>#g'
(note some inconsistencies with space between name and = and also having
empty value, and some more complicated expression to also clear up
double space before/after the attribute)
translation files will be prepped with:
find */helpcontent2 -name \*.po -print0 |xargs -0 -P 0 perl -CS -pi -e \
$'s#(<link[^>]*?) +name=(?:\\\\"[^"]*\\\\"|\'[^\']*\') *( [^>]+|) *(/?>)#$1$2$3#g unless /^#/'
(note that not all languages use the " as quote character for the
attributes, but that also single quotes appera in the po file. Hence
the use of the shell $'string' syntax to be able to quote ' as \'
It also requires to quote the backslash, so that it needs to be escaped
once for the shell, then another time for perl. Also don't work on
obsolete strings (those are prefixed with #~ in the po files)
Also note that <link..></link> gets turned into <link ../> during
translation extraction (along with removal of the space between the
attribute name and the value), so the pattern needs to be slightly
different here)
Change-Id: I95e53a08e6b0095cd894109ea0de154cc4859d8f
Reviewed-on: https://gerrit.libreoffice.org/c/help/+/143713
Tested-by: Jenkins
Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
This commit is contained in:
committed by
Christian Lohmaier
parent
490d42493e
commit
7e42394ecb
@ -21,7 +21,7 @@
|
||||
<bookmark_value>Python;Shell</bookmark_value>
|
||||
</bookmark>
|
||||
<section id="pythonshell">
|
||||
<h1 id="N0118"><variable id="pythonshell1"><link href="text/sbasic/python/python_shell.xhp" name="python shell">Running Python Interactive Console</link></variable></h1>
|
||||
<h1 id="N0118"><variable id="pythonshell1"><link href="text/sbasic/python/python_shell.xhp">Running Python Interactive Console</link></variable></h1>
|
||||
</section>
|
||||
<paragraph role="paragraph" id="N0119">The Python interactive console, also known as Python interpreter or Python shell, provides programmers with a quick way to execute commands and try out and test code without creating a file. UNO objects introspection as well as %PRODUCTNAME Python modules documentation can be obtained from the terminal.</paragraph>
|
||||
|
||||
@ -68,14 +68,14 @@
|
||||
</switch>
|
||||
|
||||
<h2 id="hd_id311633513620803">Alternative console</h2>
|
||||
<paragraph role="paragraph" id="par_id81632760673283">Use <link href="https://extensions.libreoffice.org/extensions/apso-alternative-script-organizer-for-Python" name="APSO extension">APSO extension</link> console as an alternative:</paragraph>
|
||||
<paragraph role="paragraph" id="par_id81632760673283">Use <link href="https://extensions.libreoffice.org/extensions/apso-alternative-script-organizer-for-Python">APSO extension</link> console as an alternative:</paragraph>
|
||||
<paragraph role="paragraph" id="N0144">
|
||||
<image src="media/helpimg/python/python_shell.png" id="N0144"><alt id="N0144">APSO console</alt></image>
|
||||
</paragraph>
|
||||
<section id="relatedtopics">
|
||||
<embed href="text/sbasic/python/python_examples.xhp#pythonexamples2"/>
|
||||
<embed href="text/sbasic/python/main0000.xhp#pythonscriptshelp"/>
|
||||
<paragraph role="paragraph" id="par_id351633599611244"><link href="text/sbasic/shared/03/sf_exception.xhp?#PythonShell" name="PythonShell method"><literal>PythonShell</literal></link> function in <link href="text/sbasic/shared/03/sf_exception.xhp" name="ScriptForge.Exception service"><literal>ScriptForge.Exception</literal></link> service</paragraph>
|
||||
<paragraph role="paragraph" id="par_id351633599611244"><link href="text/sbasic/shared/03/sf_exception.xhp?#PythonShell"><literal>PythonShell</literal></link> function in <link href="text/sbasic/shared/03/sf_exception.xhp"><literal>ScriptForge.Exception</literal></link> service</paragraph>
|
||||
|
||||
</section>
|
||||
</body>
|
||||
|
||||
Reference in New Issue
Block a user