mirror of
https://github.com/myvesta/vesta
synced 2025-08-14 10:37:42 -07:00
refactoring: log_event(), is_format_valid()
This commit is contained in:
parent
325ca65f32
commit
a61a6e979e
52 changed files with 582 additions and 1170 deletions
|
@ -28,7 +28,7 @@ if [ -z $homedir ]; then
|
|||
fi
|
||||
|
||||
# Checking source file
|
||||
if [ ! -f "$src_file" ]; then
|
||||
if [ ! -fe "$src_file" ]; then
|
||||
echo "Error: source file doesn't exist $src_file"
|
||||
exit 3
|
||||
fi
|
||||
|
@ -41,11 +41,11 @@ if [ -z "$(echo $rpath |egrep "^/tmp|^$homedir")" ]; then
|
|||
fi
|
||||
|
||||
# Changing file permissions
|
||||
sudo -u $user chmod $permissions "$src_file" >/dev/null 2>&1
|
||||
sudo -u $user chmod -R $permissions "$src_file" >/dev/null 2>&1
|
||||
if [ $? -ne 0 ]; then
|
||||
echo "Error: access permission on $src_file was not changed"
|
||||
exit 3
|
||||
fi
|
||||
|
||||
# Exiting
|
||||
exit
|
||||
exit
|
Loading…
Add table
Add a link
Reference in a new issue