aboutsummaryrefslogtreecommitdiff
path: root/board/common.sh
diff options
context:
space:
mode:
Diffstat (limited to 'board/common.sh')
-rw-r--r--board/common.sh9
1 files changed, 9 insertions, 0 deletions
diff --git a/board/common.sh b/board/common.sh
index ecda59d..8153c2b 100644
--- a/board/common.sh
+++ b/board/common.sh
@@ -6,3 +6,12 @@ remove_text() {
echo sed --in-place "s/$2//" $1
sed --in-place "s/$2//" $1
}
+
+add_tmpfs() {
+ create_missing_dir "$1"
+ if ! grep -qE '$1' "${TARGET_DIR}/etc/fstab"; then
+ cat << __EOF__ >> "${TARGET_DIR}/etc/fstab"
+tmpfs $1 tmpfs rw 0 0
+__EOF__
+ fi
+}