From 2eba839db5aeba306d3e834430ad754b215a6c75 Mon Sep 17 00:00:00 2001 From: oncletom Date: Sat, 28 Sep 2013 11:34:56 +0100 Subject: [PATCH] Added tmpfs mount to avoid wasting the hard drive --- bin/tmpfs-osx.sh | 13 +++++++++++++ dist/.gitignore | 1 - 2 files changed, 13 insertions(+), 1 deletion(-) create mode 100755 bin/tmpfs-osx.sh delete mode 100644 dist/.gitignore diff --git a/bin/tmpfs-osx.sh b/bin/tmpfs-osx.sh new file mode 100755 index 00000000000..ba4ea5a0953 --- /dev/null +++ b/bin/tmpfs-osx.sh @@ -0,0 +1,13 @@ +#!/bin/bash +ramfs_size_mb=2560 +mount_point=./tmp + +ramfs_size_sectors=$((${ramfs_size_mb}*1024*1024/512)) +ramdisk_dev=`hdid -nomount ram://${ramfs_size_sectors}` +newfs_hfs -v 'EmuNovaBuild' ${ramdisk_dev} +mkdir -p ${mount_point} +mount -o noatime -t hfs ${ramdisk_dev} ${mount_point} + +echo "remove with:" +echo "umount ${mount_point}" +echo "diskutil eject ${ramdisk_dev}" diff --git a/dist/.gitignore b/dist/.gitignore deleted file mode 100644 index f59ec20aabf..00000000000 --- a/dist/.gitignore +++ /dev/null @@ -1 +0,0 @@ -* \ No newline at end of file