Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
aports
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jakub Panek
aports
Commits
52d6af77
Commit
52d6af77
authored
13 years ago
by
Natanael Copa
Browse files
Options
Downloads
Patches
Plain Diff
abump: add -s option for security updates
parent
817db0ea
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
abump.in
+12
-6
12 additions, 6 deletions
abump.in
with
12 additions
and
6 deletions
abump.in
+
12
−
6
View file @
52d6af77
...
@@ -10,18 +10,22 @@ die() {
...
@@ -10,18 +10,22 @@ die() {
# version bump a pkg
# version bump a pkg
do_bump
()
{
do_bump
()
{
pkgname
=
${
1
%-[0-9]*
}
local
pkgname
=
${
1
%-[0-9]*
}
pkgver
=
${
1
#
${
pkgname
}
-
}
local
pkgver
=
${
1
#
${
pkgname
}
-
}
APORTS
=
$HOME
/aports
APORTS
=
$HOME
/aports
set
-e
set
-e
cd
$APORTS
/
*
/
$pkgname
||
return
1
cd
$APORTS
/
*
/
$pkgname
||
return
1
section
=
${
PWD
%/*
}
local
section
=
${
PWD
%/*
}
upgrade
=
"upgrade"
cve
=
section
=
${
section
##*/
}
section
=
${
section
##*/
}
if
[
-n
"
$cvelist
"
]
;
then
upgrade
=
"security upgrade"
cve
=
" (
$cvelist
)"
fi
msg
=
"
$section
/
$pkgname
: upgrade to
$pkgver
"
msg
=
"
$section
/
$pkgname
:
$
upgrade
to
$
{
pkgver
}${
cve
}
"
echo
"
$msg
"
echo
"
$msg
"
(
.
./APKBUILD
;
type
package |
grep
-q
function
)
||
die
"package() missing"
(
.
./APKBUILD
;
type
package |
grep
-q
function
)
||
die
"package() missing"
...
@@ -38,21 +42,23 @@ do_bump() {
...
@@ -38,21 +42,23 @@ do_bump() {
usage
()
{
usage
()
{
echo
"
$program
- utility to bump pkgver in APKBUILDs"
echo
"
$program
- utility to bump pkgver in APKBUILDs"
echo
"usage:
$program
[-hR]"
echo
"usage:
$program
[-hR]
[-s CVE-1,CVE-2,...]
"
echo
""
echo
""
echo
" -h show this help"
echo
" -h show this help"
echo
" -R run abuild with -R for recursive building"
echo
" -R run abuild with -R for recursive building"
echo
" -k keep existing packages"
echo
" -k keep existing packages"
echo
" -s security update"
exit
0
exit
0
}
}
keep
=
keep
=
recursive
=
"-r"
recursive
=
"-r"
while
getopts
"hkR"
opt
;
do
while
getopts
"hkR
s:
"
opt
;
do
case
$opt
in
case
$opt
in
h
)
usage
;;
h
)
usage
;;
k
)
keep
=
"-k"
;;
k
)
keep
=
"-k"
;;
R
)
recursive
=
"-R"
;;
R
)
recursive
=
"-R"
;;
s
)
cvelist
=
"
$OPTARG
"
;;
esac
esac
done
done
shift
$((
$OPTIND
-
1
))
shift
$((
$OPTIND
-
1
))
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment