Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
dadigang
Ventoy
Commits
28998edd
Commit
28998edd
authored
Jan 15, 2022
by
longpanda
Browse files
Add check for size in CreatePersistentImg.sh (#1384)
parent
2ad69dec
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
3 deletions
+8
-3
INSTALL/CreatePersistentImg.sh
INSTALL/CreatePersistentImg.sh
+8
-3
No files found.
INSTALL/CreatePersistentImg.sh
View file @
28998edd
...
@@ -56,10 +56,15 @@ fi
...
@@ -56,10 +56,15 @@ fi
# check size
# check size
if
echo
$size
|
grep
-q
"^[0-9][0-9]*$"
;
then
if
echo
$size
|
grep
-q
"^[0-9][0-9]*$"
;
then
if
[
$size
-le
1
]
;
then
vtMinSize
=
1
echo
"Invalid size
$size
"
if
echo
$fstype
|
grep
-q
'^xfs$'
;
then
exit
1
vtMinSize
=
16
fi
fi
if
[
$size
-lt
$vtMinSize
]
;
then
echo
"size too small (
$size
)"
exit
1
fi
else
else
echo
"Invalid size
$size
"
echo
"Invalid size
$size
"
exit
1
exit
1
...
...
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