Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
eepm
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Vladislav
eepm
Commits
fb90eba7
Commit
fb90eba7
authored
Jun 08, 2017
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
make shellcheck more happy
parent
a0be2778
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
25 additions
and
15 deletions
+25
-15
distr_info
bin/distr_info
+1
-1
epm
bin/epm
+2
-2
epm-addrepo
bin/epm-addrepo
+1
-1
epm-print
bin/epm-print
+5
-5
epm-removerepo
bin/epm-removerepo
+1
-1
epm-requires
bin/epm-requires
+1
-1
epm-search
bin/epm-search
+1
-1
epm-upgrade
bin/epm-upgrade
+1
-1
serv-status
bin/serv-status
+2
-2
check_code.sh
check_code.sh
+10
-0
No files found.
bin/distr_info
View file @
fb90eba7
...
...
@@ -33,7 +33,7 @@ rpmvendor()
[
"
$DISTRIB_ID
"
=
"LinuxXP"
]
&&
echo
"lxp"
&&
return
[
"
$DISTRIB_ID
"
=
"TinyCoreLinux"
]
&&
echo
"tcl"
&&
return
[
"
$DISTRIB_ID
"
=
"VoidLinux"
]
&&
echo
"void"
&&
return
echo
"
$DISTRIB_ID
"
|
tr
"
[A-Z]"
"[a-z]
"
echo
"
$DISTRIB_ID
"
|
tr
"
A-Z"
"a-z
"
}
# Translate DISTRIB_ID name to package manner (like in the package release name)
...
...
bin/epm
View file @
fb90eba7
...
...
@@ -356,7 +356,7 @@ check_option()
check_filenames
()
{
local
opt
for
opt
in
$*
;
do
for
opt
in
"
$@
"
;
do
# files can be with full path or have extension via .
if
[
-f
"
$opt
"
]
&&
echo
"
$opt
"
|
grep
-q
"[/
\.
]"
;
then
pkg_files
=
"
$pkg_files
$opt
"
...
...
@@ -406,7 +406,7 @@ pkg_filenames=$(strip_spaces "$pkg_files $pkg_names")
if
[
-z
"
$epm_cmd
"
]
;
then
print_version
echo
fatstr
=
"Unknown command in
$
@
arg(s)"
fatstr
=
"Unknown command in
$
*
arg(s)"
[
-n
"
$*
"
]
||
fatstr
=
"That program needs be running with some command"
fatal
"
$fatstr
. Run
$ $PROGNAME
--help to get help."
fi
...
...
bin/epm-addrepo
View file @
fb90eba7
...
...
@@ -46,7 +46,7 @@ case $DISTRNAME in
;;
autoimports
)
[
-n
"
$DISTRVERSION
"
]
||
fatal
"Empty DISTRVERSION"
repo
=
"
$repo
.
$(
echo
"
$DISTRVERSION
"
|
tr
"
[A-Z]"
"[a-z]
"
)
"
repo
=
"
$repo
.
$(
echo
"
$DISTRVERSION
"
|
tr
"
A-Z"
"a-z
"
)
"
esac
assure_exists apt-repo
...
...
bin/epm-print
View file @
fb90eba7
...
...
@@ -76,7 +76,7 @@ print_pkgname()
print_srcname
()
{
print_name
$(
print_srcpkgname
"
$@
"
)
print_name
"
$(
print_srcpkgname
"
$@
"
)
"
}
print_specname
()
...
...
@@ -137,7 +137,7 @@ EOF
"name"
)
[
-n
"
$1
"
]
||
fatal
"Arg is missed"
if
[
-n
"
$FNFLAG
"
]
;
then
print_name
$(
print_pkgname
"
$@
"
)
print_name
"
$(
print_pkgname
"
$@
"
)
"
elif
[
-n
"
$PKFLAG
"
]
;
then
query_package_field
"name"
"
$@
"
else
...
...
@@ -147,7 +147,7 @@ EOF
"version"
)
[
-n
"
$1
"
]
||
fatal
"Arg is missed"
if
[
-n
"
$FNFLAG
"
]
;
then
print_version
$(
print_pkgname
"
$@
"
)
print_version
"
$(
print_pkgname
"
$@
"
)
"
elif
[
-n
"
$PKFLAG
"
]
;
then
query_package_field
"version"
"
$@
"
else
...
...
@@ -157,7 +157,7 @@ EOF
"release"
)
[
-n
"
$1
"
]
||
fatal
"Arg is missed"
if
[
-n
"
$FNFLAG
"
]
;
then
print_release
$(
print_pkgname
"
$@
"
)
print_release
"
$(
print_pkgname
"
$@
"
)
"
elif
[
-n
"
$PKFLAG
"
]
;
then
query_package_field
"release"
"
$@
"
else
...
...
@@ -222,6 +222,6 @@ epm_print()
{
[
-n
"
$pkg_filenames
"
]
||
fatal
"Missed args. Use epm print help for get help."
__epm_print
$(
eval echo
$quoted_args
)
__epm_print
"
$(
eval echo
$quoted_args
)
"
}
bin/epm-removerepo
View file @
fb90eba7
...
...
@@ -27,7 +27,7 @@ case $DISTRNAME in
autoimports
)
info
"remove autoimports repo"
[
-n
"
$DISTRVERSION
"
]
||
fatal
"Empty DISTRVERSION"
repo
=
"
$repo
.
$(
echo
"
$DISTRVERSION
"
|
tr
"
[A-Z]"
"[a-z]
"
)
"
repo
=
"
$repo
.
$(
echo
"
$DISTRVERSION
"
|
tr
"
A-Z"
"a-z
"
)
"
;;
esac
...
...
bin/epm-requires
View file @
fb90eba7
...
...
@@ -44,7 +44,7 @@ epm_requires_files()
epm_requires_names
()
{
local
pkg_names
=
"
$
@
"
local
pkg_names
=
"
$
*
"
local
CMD
[
-n
"
$pkg_names
"
]
||
return
...
...
bin/epm-search
View file @
fb90eba7
...
...
@@ -132,7 +132,7 @@ __epm_search_make_grep()
#list=$(strip_spaces $list | sed -e "s/ /|/g")
listN
=
$(
strip_spaces
$listN
|
sed
-e
"s/ /|/g"
|
sed
-e
"s/
\^
//g"
)
if
[
"
$short
"
]
;
then
if
[
-n
"
$short
"
]
;
then
echon
" | sed -e
\"
s| .*||g
\"
"
fi
...
...
bin/epm-upgrade
View file @
fb90eba7
...
...
@@ -81,7 +81,7 @@ epm_upgrade()
;;
homebrew
)
#CMD="brew upgrade"
docmd
"brew upgrade
`
brew outdated
`
"
docmd
"brew upgrade
$(
brew outdated
)
"
return
;;
ipkg
)
...
...
bin/serv-status
View file @
fb90eba7
...
...
@@ -61,13 +61,13 @@ is_service_autostart()
LANG
=
C
$SUDO
chkconfig
$1
--list
|
grep
-q
"[35]:on"
;;
service-initd|service-update
)
test
-L
$(
echo
/etc/rc5.d/S??
$1
)
test
-L
"
$(
echo
/etc/rc5.d/S??
$1
)
"
;;
systemd
)
$SUDO
systemctl is-enabled
$1
;;
runit
)
test
-L
/var/service/
$SERVICE
test
-L
"/var/service/
$SERVICE
"
;;
*
)
fatal
"Have no suitable command for
$SERVICETYPE
"
...
...
check_code.sh
View file @
fb90eba7
...
...
@@ -3,5 +3,15 @@
# http://mywiki.wooledge.org/Bashism
# https://wiki.ubuntu.com/DashAsBinSh
EXCL
=
-eSC2086
,SC2039,SC2034,SC2068,SC2155
if
[
-n
"
$1
"
]
;
then
shellcheck
$EXCL
"
$1
"
exit
fi
checkbashisms
-f
bin/
*
checkbashisms
-f
Makefile
shellcheck
$EXCL
\
bin/epm bin/distr_info bin/epm-
*
bin/serv-
*
bin/tools_
*
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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