]> git.mdlowis.com Git - proto/labwc.git/commitdiff
build: refactor in preparation for man page not beginning with 'labwc-'
authorJohan Malm <jgm323@gmail.com>
Mon, 28 Apr 2025 19:33:50 +0000 (20:33 +0100)
committerJohan Malm <johanmalm@users.noreply.github.com>
Sat, 9 Aug 2025 09:44:03 +0000 (10:44 +0100)
No functional change intended.

docs/meson.build

index a667678471caa615e0c40e1f790905c79d6e7928..87acdab1c831c7705bf5b4fcc8c52e282791cb8a 100644 (file)
@@ -1,16 +1,15 @@
 scdoc = find_program('scdoc', required: get_option('man-pages'))
 
 if scdoc.found()
-  sections = [
-    '.1',
-    '-actions.5',
-    '-config.5',
-    '-menu.5',
-    '-theme.5',
+  manpages = [
+    'labwc.1',
+    'labwc-actions.5',
+    'labwc-config.5',
+    'labwc-menu.5',
+    'labwc-theme.5',
   ]
-  foreach s : sections
-    markdown = 'labwc' + s + '.scd'
-    manpage = 'labwc' + s
+  foreach manpage : manpages
+    markdown = manpage + '.scd'
     custom_target(
       manpage,
       input: markdown,
@@ -19,7 +18,7 @@ if scdoc.found()
       feed: true,
       capture: true,
       install: true,
-      install_dir: join_paths(get_option('mandir'), 'man' + s.split('.')[-1])
+      install_dir: join_paths(get_option('mandir'), 'man' + manpage.split('.')[-1])
     )
   endforeach
 endif