Bug 7386 - Incorrect dash characters used in manual
Summary: Incorrect dash characters used in manual
Status: RESOLVED FIXED
Alias: None
Product: Development Manual
Classification: Documentation
Component: development (show other bugs)
Version: 1.7
Hardware: All Multiple
: Undecided normal
Target Milestone: ---
Assignee: Scott Rifenbark
QA Contact:
URL:
Whiteboard: 27 April 2015: RESOLVED
Depends on:
Blocks:
 
Reported: 2015-03-03 14:02 UTC by Paul Eggleton
Modified: 2015-04-27 15:30 UTC (History)
0 users

See Also:
OS type for building Yocto: ---
Type of Regression: New (Never tested)
Verified:
Documentation change: Yes (doc changes required)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Paul Eggleton 2015-03-03 14:02:03 UTC
I just hit an odd problem. If I copy and paste the first "smart channel..." command from the development manual opened in Firefox on Linux to a terminal where I have an ssh session open to the target, I get the following error:

root@qemux86-64:~# smart channel ‐‐add all type=rpm-md baseurl=http://server.name/rpm/all
error: No action specified for command 'channel'

If I delete and re-type the dashes in --add, it visually looks no different, but if I re-run the edited command, it works. It looks like some unicode dash character is being used there instead of the normal dash, and this appears to have happened pretty much everywhere there is a double-dash (--) in the dev manual, and possibly other manuals. These non-standard dashes need to be replaced throughout the manual so that they can be copied and pasted verbatim and still work.
Comment 1 Scott Rifenbark 2015-03-04 16:47:55 UTC
hmm... yes, I have used ‐‐ in the Docbook source because during development of sections, sometimes I need to comment out stuff, which requires a block such as the following:

  <!--
       comments
       comments
       comments
  -->

Anytime a literal '--' character appears in the commented block, it causes a problem when making the manual.  I guess I can just use the &dash; stuff during debugging and when the manual making correctly, replace with literall dash characters. 

Scott
Comment 2 Scott Rifenbark 2015-03-04 17:08:18 UTC
I scrubbed the manuals and none of these strings remain.  Manuals affected include the dev-manual and the ref-manual.

Scott
Comment 3 Paul Eggleton 2015-03-04 23:08:55 UTC
I'd be interested to know where this &dash; entity is being substituted - is it in the browser or when the HTML is produced by the documentation tools? If the latter, it might be fixable.
Comment 4 Scott Rifenbark 2015-03-04 23:11:35 UTC
Pretty sure that the ENTITY stuff is substituted by the tools.  Which totally doesn't make sense as to why when a person copies a command from an HTML doc it has issues.

Scott
Comment 5 Scott Rifenbark 2015-03-04 23:16:13 UTC
Here is the docbook source for the code in question:

                        <literallayout class='monospaced'>
     # smart channel &dash;&dash;add all type=rpm-md baseurl=http://server.name/rpm/all
     # smart channel &dash;&dash;add i585 type=rpm-md baseurl=http://server.name/rpm/i586
     # smart channel &dash;&dash;add qemux86 type=rpm-md baseurl=http://server.name/rpm/qemux86
                        </literallayout>


When I bring up the HTML version of the manual and select the first smart channel --add command and then "view source", this is what I get.

<pre class="literallayout">     # smart channel ‐‐add all type=rpm-md baseurl=http://server.name/rpm/all
     # smart channel ‐‐add i585 type=rpm-md baseurl=http://server.name/rpm/i586
     # smart channel ‐‐add qemux86 type=rpm-md baseurl=http://server.name/rpm/qemux86
                        </pre>

Note the "--" strings are in there.
Comment 6 Paul Eggleton 2015-03-05 10:21:51 UTC
OK, so I had a look at:

http://www.oasis-open.org/docbook/specs/wd-docbook-xmlcharent-0.3.html

It seems to suggest that &dash; should indeed give you the unicode character we are getting and the correct entity for the normal "-" would be &hyphen; . Can you give that a try?
Comment 7 Scott Rifenbark 2015-03-06 18:17:49 UTC
I tried &hypen; out.  Go to http://www.yoctoproject.org/docs/1.8/dev-manual/dev-manual.html#runtime-package-management-target-rpm and see if you can cut out that command without any issues.

Scott
Comment 8 Paul Eggleton 2015-04-27 12:39:12 UTC
This is still broken in the current manual - the "smart channel" commands are apparently still using the wrong dash characters.
Comment 9 Scott Rifenbark 2015-04-27 15:30:57 UTC
I have universally replaced all the "&dash;" strings in the YP docs with the "-" string.  This should no longer be an issue.  There were many occurrences in the dev-manual and a few occurrences in the ref-manual. 

I pushed the commit to both the 'master' and 'fido' branches in 'yocto-docs'.  I have republished the 'current' and 'latest' set of docs to the server so everything thing should be good with this issue.

Scott