Removing dead lang2locale function and associated files, not used anywhere.
[live-boot-grml.git] / scripts / boot / misc-helpers.sh
index 202ebe6..abb2dd2 100755 (executable)
@@ -1,5 +1,22 @@
 #!/bin/sh
 
+#set -e
+
+really_export ()
+{
+       STRING="${1}"
+       VALUE="$(eval echo -n \${$STRING})"
+
+       if [ -f /live.vars ] && grep -sq "export ${STRING}" /live.vars
+       then
+               sed -i -e 's/\('${STRING}'=\).*$/\1'${VALUE}'/' /live.vars
+       else
+               echo "export ${STRING}=\"${VALUE}\"" >> /live.vars
+       fi
+
+       eval export "${STRING}"="${VALUE}"
+}
+
 is_in_list_separator_helper () {
        local sep=${1}
        shift