Skip to content

docs:opkg: clean up RST#91

Open
amstewart wants to merge 13 commits into
ni:mainfrom
amstewart:dev/opkg-intro
Open

docs:opkg: clean up RST#91
amstewart wants to merge 13 commits into
ni:mainfrom
amstewart:dev/opkg-intro

Conversation

@amstewart

Copy link
Copy Markdown
Collaborator

Summary

  • Fixup minor RST layout issues.
  • Use inline literal markup for inline code and applications, rather than bold.
  • Refer to IPKs and DEBs, instead of .ipks and .debs in most places.
  • Reflow prose to line-break on sentence ends, for easier diffing.
  • Minor content changes for clarity.

Testing

  • Ran make html locally and manually validated that the opkg tutorials look better and the links work.

This comment was marked as outdated.

@amstewart

Copy link
Copy Markdown
Collaborator Author

Patch V2

  • Address review feedback.

@amstewart amstewart requested a review from Copilot September 8, 2025 20:51

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR cleans up and improves the RST documentation for opkg tutorials by addressing minor formatting issues and improving readability. The changes focus on:

  • Replacing bold formatting with inline literal markup for code elements and applications
  • Changing references from ".ipks" and ".debs" to "IPKs" and "DEBs" for consistency
  • Reflowing prose to break on sentence boundaries for better diff readability
  • Minor content clarifications and link reference improvements

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 7 comments.

File Description
docs/source/opkg/opkg_intro.rst Updates formatting, terminology, and prose flow for the basic opkg tutorial
docs/source/opkg/dkms_opkg.rst Applies similar formatting and terminology improvements to the DKMS-based kernel module tutorial

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Comment thread docs/source/opkg/opkg_intro.rst Outdated
Comment thread docs/source/opkg/opkg_intro.rst Outdated
Comment thread docs/source/opkg/opkg_intro.rst Outdated
Comment thread docs/source/opkg/opkg_intro.rst Outdated
Comment thread docs/source/opkg/opkg_intro.rst Outdated
Comment thread docs/source/opkg/opkg_intro.rst Outdated
Comment thread docs/source/opkg/dkms_opkg.rst Outdated
Alex Stewart added 5 commits June 29, 2026 11:51
* Fixup minor RST layout issues.
* Use inline literal markup for inline code and applications, rather
  than bold.
* Refer to IPKs and DEBs, instead of .ipks and .debs in most places.
* Reflow prose to line-break on sentence ends, for easier diffing.
* Minor content changes for clarity.

Signed-off-by: Alex Stewart <alex.stewart@emerson.com>
Signed-off-by: Alex Stewart <alex.stewart@emerson.com>
Signed-off-by: Alex Stewart <alex.stewart@emerson.com>
Let's not check binary tarballs into the git source. Instead, we can
build the example IPK tars from Make.

Signed-off-by: Alex Stewart <alex.stewart@emerson.com>
No reason to advertise Charlie Johnston's defunct email when we can just
use the generic email address for the RTOS team.

Signed-off-by: Alex Stewart <alex.stewart@emerson.com>
@amstewart

Copy link
Copy Markdown
Collaborator Author

Patch v2

  • Addressed copilot feedback.
  • Removed tarballs from source control and build them from the Makefile.
  • Replace Charlie Johnston's email in the example opkg IPKs with the RTOS team email.

@jpautler

Copy link
Copy Markdown
Collaborator

When I build and preview the HTML content locally, I see a lot of lines wrapping with syllable-boundary hyphenation. Wrapping on word boundaries seems more readable. Was this intentional or just an unintended side effect?

@jpautler

jpautler commented Jun 29, 2026

Copy link
Copy Markdown
Collaborator

When I extract the new locally built dkms_opkg.tar.gz archive, I noticed that it lost the containing dkms_opkg directory upon extraction. Instead it extracts the hello and module_src directories directly into the current directory. This is different than opkg_intro.tar.gz and different than the old dkms_opkg.tar.gz. Perhaps unintended?

@amstewart

amstewart commented Jun 30, 2026

Copy link
Copy Markdown
Collaborator Author

When I build and preview the HTML content locally, I see a lot of lines wrapping with syllable-boundary hyphenation. Wrapping on word boundaries seems more readable. Was this intentional or just an unintended side effect?

I didn't do anything to effect the word-braking logic. I see places on the published docs that sphinx breaks the word as well.

image

https://nilrt-docs.ni.com/opkg-keyrings/opkg-keyrings_index.html#systemlink

Copilot tells me that this behavior is controlled by the browser and your CSS. We could modify our sphinxdocs theme to tell it not to break words. But that isn't a part of this PR's purpose.

@amstewart

Copy link
Copy Markdown
Collaborator Author

When I extract the new locally built dkms_opkg.tar.gz archive, I noticed that it lost the containing dkms_opkg directory upon extraction. Instead it extracts the hello and module_src directories directly into the current directory. This is different than opkg_intro.tar.gz and different than the old dkms_opkg.tar.gz. Perhaps unintended?

These are the example IPKs I just downloaded from the published site. They seem similar to what we package with this PR. Are you seeing something different?

[0]usr0@rtosams3:Downloads$ tar --list -f ./opkg_intro\(2\).tar.gz 
CONTROL
debian-binary
helloworld.c
[0]usr0@rtosams3:Downloads$ tar --list -f ./dkms_opkg.tar.gz 
hello/
hello/debian-binary
hello/CONTROL/
hello/CONTROL/control
hello/CONTROL/prerm
hello/CONTROL/postinst
hello/usr/
hello/usr/src/
hello/usr/src/hello-0.1/
hello/usr/src/hello-0.1/Makefile
hello/usr/src/hello-0.1/hello.c
hello/usr/src/hello-0.1/dkms.conf
module_src/
module_src/hello-0.1/
module_src/hello-0.1/Makefile
module_src/hello-0.1/hello.c
module_src/hello-0.1/dkms.conf

Though now that I look at them more closely... I'm not sure these are good examples of IPKs. Especially the DKMS one seems malformed.

@amstewart

Copy link
Copy Markdown
Collaborator Author

I'll take a deeper look at the example IPKs when I have some time.

Alex Stewart added 8 commits July 2, 2026 16:17
* Converted the hello world c-code example to a more neutral bash
  script.
* Corrected the opkg-intro source so that it follows a normal IPK
  layout.
* Simplified and refactored the example text to walk the user through
  using opkg-build to create an IPK from the source.

Signed-off-by: Alex Stewart <alex.stewart@emerson.com>
The current HTML output will set 'word-break: auto' which will direct
the browser to "intelligently" break words with a hyphen across
newlines. We'd prefer that it not. So set it to 'manual' in a custom css
override, so that it will only break if the word itself contains a
hyphen at that place.

Signed-off-by: Alex Stewart <alex.stewart@emerson.com>
RST image embeds require a blank line before teh directive to parse
correctly.

Signed-off-by: Alex Stewart <alex.stewart@emerson.com>
* Rename ``dkms_opkg`` to ``dkms-opkg``, which is more standard for IPKs
  and archives.
* Adjust Makefile TAR command so that the source archives have a
  containing folder - which is good practice.

Signed-off-by: Alex Stewart <alex.stewart@emerson.com>
Signed-off-by: Alex Stewart <alex.stewart@emerson.com>
Instead of delivering two copies of the dkms module source code, just
give readers the IPK-structured data, which includes the module source
anyway.

Signed-off-by: Alex Stewart <alex.stewart@emerson.com>
Instead of copying source file contents into the RST manually, we should
let sphinx do it for us with literalinclude.

Signed-off-by: Alex Stewart <alex.stewart@emerson.com>
Signed-off-by: Alex Stewart <alex.stewart@emerson.com>
@amstewart

Copy link
Copy Markdown
Collaborator Author

Patch v3

  • Refactor opkg_intro and dkms_opkg source tarballs to be a little more sane.
  • Use literalinclude in dkms_opkg to include source files.
  • Enable -W in sphinx compilation so that we will fail on warnings.
  • Set word-break to 'manual' in the CSS to reduce the frequency of word breaks.
  • Fix some broken image embeds.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants