Refactor calculation of swap size
This commit is contained in:
parent
1aadd4b9d3
commit
19c475e58d
1 changed files with 1 additions and 2 deletions
|
@ -3,8 +3,7 @@ pushd "${BASH_SOURCE%/*}" > /dev/null;
|
||||||
source "../../Scripts/choose-disk.sh";
|
source "../../Scripts/choose-disk.sh";
|
||||||
chooseDisk archDisk "Which disk do you whish to format for installing Arch?";
|
chooseDisk archDisk "Which disk do you whish to format for installing Arch?";
|
||||||
memory="$(cat /proc/meminfo | awk -F " " '/^MemTotal/ { print $2 }')";
|
memory="$(cat /proc/meminfo | awk -F " " '/^MemTotal/ { print $2 }')";
|
||||||
memory="$(echo "$memory" | awk '{ print int(($1 / 1024 / 1024) + 0.5)}')";
|
swapSize="$(echo "$memory" | awk '{ print int(($1 / 1024 / 1024 4) + 0.5)}')";
|
||||||
swapSize="$(echo "$memory" | awk '{ print int(($1 / 4) + 0.5)}')";
|
|
||||||
|
|
||||||
{
|
{
|
||||||
echo "g";
|
echo "g";
|
||||||
|
|
Loading…
Reference in a new issue