Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
alpine
abuild
Commits
076ecdf3
Commit
076ecdf3
authored
Jul 02, 2013
by
Natanael Copa
Browse files
abuild: check for more common spell errors
check for pkguser, pkggroup, subpackage
parent
a5bed6ab
Changes
1
Hide whitespace changes
Inline
Side-by-side
abuild.in
View file @
076ecdf3
...
...
@@ -123,6 +123,10 @@ die() {
exit
1
}
spell_error
()
{
die
"APKBUILD contains '
$1
'. It should be '
$2
'"
}
# check if apkbuild is basicly sane
default_sanitycheck
()
{
local
i
=
j
=
suggestion
=
...
...
@@ -181,7 +185,7 @@ default_sanitycheck() {
fi
done
done
for
i
in
$triggers
;
do
local
f
=
${
i
%=*
}
local
p
=
${
f
%.trigger
}
...
...
@@ -220,8 +224,11 @@ default_sanitycheck() {
done
# common spelling errors
[
-n
"
$depend
"
]
&&
die
"APKBUILD contains 'depend'. It should be depends"
[
-n
"
$makedepend
"
]
&&
die
"APKBUILD contains 'makedepend'. It should be makedepends"
[
-n
"
$depend
"
]
&&
spell_error depend depends
[
-n
"
$makedepend
"
]
&&
spell_error makedepend makedepends
[
-n
"
$pkguser
"
]
&&
spell_error pkguser pkgusers
[
-n
"
$pkggroup
"
]
&&
spell_error pkggroup pkggroups
[
-n
"
$subpackage
"
]
&&
spell_error subpackage subpackages
grep
'^# Maintainer:'
$APKBUILD
>
/dev/null
||
warning
"No maintainer"
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment