Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OskarStenberg
SnipeIt
Commits
1d7cace0
Commit
1d7cace0
authored
Jul 14, 2021
by
OskarStenberg
Browse files
Updated backup
parent
cf2a423a
Changes
1
Hide whitespace changes
Inline
Side-by-side
backup.sh
View file @
1d7cace0
...
...
@@ -173,7 +173,7 @@ done <<< "$files"
#Try to make a patch of the database dump
file
=
"db-dumps/mysql-snipeit.sql"
if
[
-z
"
$(
ls
-A
"
$destinationDir
/
$lastBackup
/patches"
)
"
]
;
then
if
[
-z
"
$(
ls
-A
p
"
$destinationDir
/
$lastBackup
/patches"
|
grep
-v
/
)
"
]
;
then
diff
-urN
null
$file
>
patch.patch
cp
"patch.patch"
"
$destinationDir
/
$lastBackup
/patches/
$now
.patch"
echo
"Copied patch to
$destinationDir
/
$lastBackup
/patches/
$now
.patch"
...
...
Write
Preview
Supports
Markdown
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