graysky2 / profile-sync-daemon

Symlinks and syncs browser profile dirs to RAM thus reducing HDD/SDD calls and speeding-up browsers.

Home Page:https://wiki.archlinux.org/index.php/Profile-sync-daemon

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

doc/psd.1 man page contains wrong man section number

hosiet opened this issue · comments

In https://github.com/graysky2/profile-sync-daemon/blob/4307a5575f613a441dece17d0fd5360445cdf96b/doc/psd.1 , the following headers are used:

.\" Text automatically generated by txt2man
.TH profile-sync-daemon  "22 September 2020" "" ""
.SH NAME
\fBprofile-sync-daemon \fP- Symlinks and syncs browser profiles to RAM (tmpfs) thus reducing HDD/SSD calls and speeding up browsers.
\fB

The second parameter for .TH should be section number, and in this case it should be 1. However, the section number is missing. You may check the other file (doc/psd-overlay-helper.1) for a correct example.

This issue is treated as an error in Debian packaging:

dh_installman: warning: Section for ./doc/psd.1 is computed as "22", which is not a valid section
dh_installman: error: Could not determine section for ./doc/psd.1

This is obviously a grammar error and should be fixed. I have no idea about how you invoked txt2man to generate this file, but obviously the issue shall be fixed by invoking txt2man to generate this file with some parameters adjusted.

Hereis the raw text I ran through txt2man. Patches welcome.

txt2man -t profile-sync-daemon -s 1 doc/manpage.txt > doc/psd.1

I am using txt2man 1.7.1 from https://tracker.debian.org/pkg/txt2man , and the rendered man page does not contain this error. Perhaps you are using a different version of txt2man?

Anyway, we can close this issue if the following patch is applied. If you would like, we can dig into what actually happens the next time when man pages are updated.

diff --git a/doc/psd.1 b/doc/psd.1
index f122480..ac05d14 100644
--- a/doc/psd.1
+++ b/doc/psd.1
@@ -1,5 +1,5 @@
 .\" Text automatically generated by txt2man
-.TH profile-sync-daemon  "22 September 2020" "" ""
+.TH profile-sync-daemon "1" "22 September 2020" "" ""
 .SH NAME
 \fBprofile-sync-daemon \fP- Symlinks and syncs browser profiles to RAM (tmpfs) thus reducing HDD/SSD calls and speeding up browsers.
 \fB

I have 1.7.1-3. When I reapply it, I get:

--- a/doc/psd.1
+++ b/doc/psd.1
@@ -1,5 +1,5 @@
 .\" Text automatically generated by txt2man
-.TH profile-sync-daemon  "22 September 2020" "" ""
+.TH profile-sync-daemon 1 "02 October 2023" "" ""
 .SH NAME
 \fBprofile-sync-daemon \fP- Symlinks and syncs browser profiles to RAM (tmpfs) thus reducing HDD/SSD calls and speeding up browsers.
 \fB

It is missing the double quotes around the 1 ... does it still trip up your packaging system?

The double quote will not affect the functionality, and the fix looks okay. Thanks!