misc/ruby-manpages: more better adaptation with pkg_alternatives
* Take maintainer ship. * More better adaptation with pkg_alternatices; install manual pages with ${RUBY_VER} as like commands. Bump PKGREVISION.
This commit is contained in:
parent
de4eb59e82
commit
e794e5c550
|
@ -1,10 +1,10 @@
|
|||
# $NetBSD: Makefile,v 1.3 2022/12/29 16:21:35 taca Exp $
|
||||
# $NetBSD: Makefile,v 1.4 2022/12/31 16:20:39 taca Exp $
|
||||
|
||||
DISTNAME= manpages-0.6.1
|
||||
PKGREVISION= 1
|
||||
PKGREVISION= 2
|
||||
CATEGORIES= misc
|
||||
|
||||
MAINTAINER= pkgsrc-users@NetBSD.org
|
||||
MAINTAINER= taca@NetBSD.org
|
||||
HOMEPAGE= https://github.com/bitboxer/manpages
|
||||
COMMENT= Adds support for man pages to rubygems
|
||||
LICENSE= mit
|
||||
|
|
|
@ -1,8 +1,9 @@
|
|||
$NetBSD: distinfo,v 1.2 2022/12/29 16:21:35 taca Exp $
|
||||
$NetBSD: distinfo,v 1.3 2022/12/31 16:20:39 taca Exp $
|
||||
|
||||
BLAKE2s (manpages-0.6.1.gem) = f9be6aa72e19fee514ce924206691ff49323ec1c68d1c91160244dc090eaa28b
|
||||
SHA512 (manpages-0.6.1.gem) = 70839c45db9d0eeef94587853db1514842b7a7e9fed7a967c7a1e9fcfe1ae204de93e04a8bdb24c4dfe6641cef5a27d29136bc4ae6e233040d1d2aa71b077378
|
||||
Size (manpages-0.6.1.gem) = 14848 bytes
|
||||
SHA1 (patch-lib_manpages_install.rb) = cb490bc69237aa8d2bbcae1f314c644f2bf09d0e
|
||||
SHA1 (patch-lib_manpages_man__files.rb) = 55757e60d132a876bcbad0fe94256522867cdafd
|
||||
SHA1 (patch-lib_rubygems__plugin.rb) = fe8e5bf91c42caf9a19f4f4658f6fa16a6e99f7c
|
||||
SHA1 (patch-lib_rubygems_commands_manpages__command.rb) = a4ab65190a9ef1bab7805d2eb76f39dd97743937
|
||||
|
|
|
@ -0,0 +1,27 @@
|
|||
$NetBSD: patch-lib_manpages_man__files.rb,v 1.1 2022/12/31 16:20:39 taca Exp $
|
||||
|
||||
* Install manual page with RUBY_VER style.
|
||||
|
||||
--- lib/manpages/man_files.rb.orig 2022-12-30 09:50:10.725925400 +0000
|
||||
+++ lib/manpages/man_files.rb
|
||||
@@ -1,7 +1,9 @@
|
||||
require "pathname"
|
||||
+require "rbconfig"
|
||||
|
||||
module Manpages
|
||||
class ManFiles
|
||||
+ RUBY_VER = RbConfig::CONFIG["MAJOR"] + RbConfig::CONFIG["MINOR"]
|
||||
attr_reader :man_dir
|
||||
|
||||
def initialize(gem_dir, target_dir = "")
|
||||
@@ -23,7 +25,9 @@ module Manpages
|
||||
|
||||
def man_file_path(file)
|
||||
man_section = file.extname.match(/\.(\d*)/)
|
||||
- @target_dir.join("man#{man_section[1]}", file.basename)
|
||||
+ suffix = ".#{man_section[1]}"
|
||||
+ name = file.basename(suffix).to_s + RUBY_VER + suffix
|
||||
+ @target_dir.join("man#{man_section[1]}", name)
|
||||
end
|
||||
end
|
||||
end
|
Loading…
Reference in New Issue