qrpm 0.3.3 → 0.3.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/exe/qrpm +51 -4
- data/lib/qrpm/version.rb +1 -1
- data/lib/qrpm.rb +5 -6
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 46adf6022a282921ffec7babe5d51a630265fdc006fe6a8f2108b05175d3801f
|
4
|
+
data.tar.gz: 152bedc386c3b1f80d4727c89bb2eda22aea5f98dec9d4bc505eb7484419e93c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5c97e24da7f3bde2793c624300c93ccd8197cae6f8c204e708663a2549c9c718cbd64f1a741c8a576c0aac65af8bcf9272eb633dafe3ca7def268a92a5bae73a
|
7
|
+
data.tar.gz: aab20b330f1968edeac8e4eeb96ba2a1953cb688f74b8274804d7e9c1b8b53ab023552338b438d13ebcdae32f2cf52837d4a9527284349440d55b7c677450601
|
data/exe/qrpm
CHANGED
@@ -55,6 +55,49 @@ begin
|
|
55
55
|
|
56
56
|
BUILT-IN VARIABLES
|
57
57
|
|
58
|
+
There are the following built-in variables. They are listed below with their
|
59
|
+
default values:
|
60
|
+
|
61
|
+
rootdir /
|
62
|
+
rootconfdir /etc
|
63
|
+
rootexecdir /usr
|
64
|
+
rootlibdir /usr
|
65
|
+
rootconstdir /usr/share
|
66
|
+
rootdocdir /usr/share
|
67
|
+
rootdatadir /var
|
68
|
+
|
69
|
+
sysetcdir /etc
|
70
|
+
sysbindir /usr/bin
|
71
|
+
syssbindir /usr/sbin
|
72
|
+
syslibdir /usr/lib64
|
73
|
+
syslibexecdir /usr/libexec
|
74
|
+
syssharedir /usr/share
|
75
|
+
sysdocdir /usr/share/doc
|
76
|
+
sysvardir /var/lib
|
77
|
+
sysspooldir /var/spool
|
78
|
+
sysrundir /var/run
|
79
|
+
syslockdir /var/lock
|
80
|
+
syscachedir /var/cache
|
81
|
+
syslogdir /var/log
|
82
|
+
systmpdir /tmp
|
83
|
+
|
84
|
+
pcketcdir /etc/NAME
|
85
|
+
pckbindir /usr/bin
|
86
|
+
pcksbindir /usr/sbin
|
87
|
+
pcklibdir /usr/lib64/NAME
|
88
|
+
pcklibexecdir /usr/libexec/NAME
|
89
|
+
pcksharedir /usr/share/NAME
|
90
|
+
pckdocdir /usr/share/doc/NAME
|
91
|
+
pckvardir /var/NAME
|
92
|
+
pckspooldir /var/spool/NAME
|
93
|
+
pckrundir /var/run/NAME
|
94
|
+
pcklockdir /var/lock/NAME
|
95
|
+
pckcachedir /var/cache/NAME
|
96
|
+
pcklogdir /var/log/NAME
|
97
|
+
pcktmpdir /tmp/NAME
|
98
|
+
|
99
|
+
Note that there are no package specific directories for bin and sbin
|
100
|
+
|
58
101
|
INSTALLATION DIRECTORIES
|
59
102
|
|
60
103
|
OPTIONS
|
@@ -126,8 +169,12 @@ begin
|
|
126
169
|
currdir = overrides["currdir"] = File.expand_path(overrides["currdir"] || Dir.getwd)
|
127
170
|
qrpmdir = overrides["qrpmdir"] = File.expand_path(overrides["qrpmdir"] || opts.directory || ".")
|
128
171
|
|
172
|
+
# Check builddir (todo: also currdir?)
|
173
|
+
File.directory?(currdir) or error "Can't find '#{currdir}'"
|
174
|
+
File.directory?(qrpmdir) or error "Can't find '#{qrpmdir}'"
|
175
|
+
|
129
176
|
# Compute builddir
|
130
|
-
if opts.builddir? && opts.force_builddir?
|
177
|
+
if opts.builddir? && opts.force_builddir?
|
131
178
|
ShellOpts.error "Can't use both --builddir and --force-builddir"
|
132
179
|
elsif opts.builddir? || opts.force_builddir?
|
133
180
|
builddir = opts.builddir || opts.force_builddir || "builddir"
|
@@ -139,7 +186,7 @@ begin
|
|
139
186
|
end
|
140
187
|
|
141
188
|
# Check if repository is clean
|
142
|
-
opts.force? || opts.dump? || `git status --porcelain | grep -v '??' 2>/dev/null` == "" or
|
189
|
+
opts.force? || opts.dump? || `cd #{qrpmdir}; git status --porcelain | grep -v '??' 2>/dev/null` == "" or
|
143
190
|
ShellOpts.error "Repository is dirty"
|
144
191
|
|
145
192
|
# Check configuration file
|
@@ -156,8 +203,8 @@ begin
|
|
156
203
|
Dir.chdir(qrpmdir)
|
157
204
|
|
158
205
|
# Parse QRPM configuration file. Include paths are still resolved with the
|
159
|
-
# context of the original directory while filesystem paths are
|
160
|
-
# the source directory
|
206
|
+
# context of the original directory if -C is used while filesystem paths are
|
207
|
+
# relative to the source directory
|
161
208
|
compiler = Qrpm::Compiler.new(overrides)
|
162
209
|
qrpm = compiler.compile(conf)
|
163
210
|
rpm = qrpm.rpm
|
data/lib/qrpm/version.rb
CHANGED
data/lib/qrpm.rb
CHANGED
@@ -68,8 +68,8 @@ module Qrpm
|
|
68
68
|
syssbindir: "$rootexecdir/sbin",
|
69
69
|
syslibdir: "$rootlibdir/lib64",
|
70
70
|
syslibexecdir: "$rootexecdir/libexec",
|
71
|
-
syssharedir: "$rootconstdir
|
72
|
-
sysdocdir: "$syssharedir",
|
71
|
+
syssharedir: "$rootconstdir",
|
72
|
+
sysdocdir: "$syssharedir/doc",
|
73
73
|
sysvardir: "$rootdatadir/lib",
|
74
74
|
sysspooldir: "$rootdatadir/spool",
|
75
75
|
sysrundir: "$rootdatadir/run",
|
@@ -79,11 +79,10 @@ module Qrpm
|
|
79
79
|
systmpdir: "/tmp" # Always /tmp because of security
|
80
80
|
}
|
81
81
|
|
82
|
-
# There are no package-specific versions of bindir and sbindir
|
83
82
|
PACKAGE_DIRS = {
|
84
83
|
pcketcdir: "$sysetcdir/$pckdir",
|
85
|
-
pckbindir: "$sysbindir", # No
|
86
|
-
pcksbindir: "$syssbindir", # No
|
84
|
+
pckbindir: "$sysbindir", # No package-specific directory
|
85
|
+
pcksbindir: "$syssbindir", # No package-specific directory
|
87
86
|
pcklibdir: "$syslibdir/$pckdir",
|
88
87
|
pcklibexecdir: "$syslibexecdir/$pckdir",
|
89
88
|
pcksharedir: "$syssharedir/$pckdir",
|
@@ -102,7 +101,7 @@ module Qrpm
|
|
102
101
|
DEFAULTS = {
|
103
102
|
"name" => "$(basename $PWD)",
|
104
103
|
"summary" => "The $name RPM package",
|
105
|
-
"version" => "$(cd ${{srcdir}} && git tag -l 2>/dev/null | tail -1 | tr -dc '.0-9' || echo 0.0.0)",
|
104
|
+
"version" => "$(cd ${{srcdir}} && git tag -l 2>/dev/null | sort -V | tail -1 | tr -dc '.0-9' || echo 0.0.0)",
|
106
105
|
"description" => "$summary",
|
107
106
|
"release" => "1",
|
108
107
|
"license" => "GPL",
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: qrpm
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Claus Rasmussen
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2024-01-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: shellopts
|