diff options
author | Dieter Plaetinck <dieter@plaetinck.be> | 2008-11-01 14:41:20 +0100 |
---|---|---|
committer | Dieter Plaetinck <dieter@plaetinck.be> | 2008-11-01 14:41:20 +0100 |
commit | 26357a4e72ebd936f27b2677c445b17310cf07db (patch) | |
tree | 9b1c9e79504d91108f77a04dd1400d00e461f5ec /src/lib/lib-blockdevices-filesystems.sh | |
parent | 7c531b9583a4d8459d1e552e41b1d03374334ca1 (diff) |
much of stuff moved from setup script to appropriate places + some more work on lib-ui
Diffstat (limited to 'src/lib/lib-blockdevices-filesystems.sh')
-rw-r--r-- | src/lib/lib-blockdevices-filesystems.sh | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/lib/lib-blockdevices-filesystems.sh b/src/lib/lib-blockdevices-filesystems.sh index 101b737..b441a5e 100644 --- a/src/lib/lib-blockdevices-filesystems.sh +++ b/src/lib/lib-blockdevices-filesystems.sh @@ -260,3 +260,20 @@ _mkfs() { fi } + +# auto_fstab(). taken from setup +# preprocess fstab file +# comments out old fields and inserts new ones +# according to partitioning/formatting stage +# +auto_fstab() +{ + if [ "$S_MKFS" = "1" -o "$S_MKFSAUTO" = "1" ]; then + if [ -f /tmp/.fstab ]; then + # comment out stray /dev entries + sed -i 's/^\/dev/#\/dev/g' $TARGET_DIR/etc/fstab + # append entries from new configuration + sort /tmp/.fstab >>$TARGET_DIR/etc/fstab + fi + fi +} |