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
etersoft
eepm
Commits
dfb9b480
Commit
dfb9b480
authored
Jan 30, 2023
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
epm: add echocmd (special for command print out) and use it in the empty arg error message
parent
58d42515
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
5 deletions
+15
-5
epm
bin/epm
+5
-5
epm-sh-functions
bin/epm-sh-functions
+10
-0
No files found.
bin/epm
View file @
dfb9b480
...
...
@@ -551,12 +551,12 @@ pkg_filenames=$(strip_spaces "$pkg_files $pkg_names")
# Just printout help if run without args
if
[
-z
"
$epm_cmd
"
]
;
then
print_version
echo
fatstr
=
"Un
known command in
$*
arg(s)"
print_version
>
&2
echo
>
&2
fatstr
=
"Un
recognized command in '
$*
'
arg(s)"
[
-n
"
$*
"
]
||
fatstr
=
"That program needs be running with some command"
echo
"Run
$
$PROGNAME
--help
to get help."
>
&2
echo
"Run
$
epm print info
to get some system and distro info."
>
&2
echo
"Run
$
(
echocmd
"
$PROGNAME
--help"
)
to get help."
>
&2
echo
"Run
$
(
echocmd
"epm print info"
)
to get some system and distro info."
>
&2
fatal
"
$fatstr
."
fi
...
...
bin/epm-sh-functions
View file @
dfb9b480
...
...
@@ -129,6 +129,16 @@ showcmd()
fi
>
&2
}
# Print command
echocmd
()
{
set_boldcolor
$GREEN
local
PROMTSIG
=
"
\$
"
is_root
&&
PROMTSIG
=
"#"
echo
-n
"
$PROMTSIG
$*
"
restore_color
}
# Print command line and run command line
docmd
()
{
...
...
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