From c333d1b658d6a0e8186633697d77f6ab0fd1a5b2 Mon Sep 17 00:00:00 2001 From: Ted Trask Date: Fri, 3 Oct 2008 12:42:13 +0000 Subject: Modified format library. parse_configfile2, update_configfile2, get_section, and set_section became parse_ini_file, update_ini_file, get_ini_section, and set_ini_section. Updated all code that used these functions. git-svn-id: svn://svn.alpinelinux.org/acf/apk-tools/trunk@1539 ab2d0c66-481e-0410-8bed-d214d4d58bed --- apk-model.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apk-model.lua b/apk-model.lua index 5c1af6e..e07ba9a 100644 --- a/apk-model.lua +++ b/apk-model.lua @@ -48,7 +48,7 @@ install_package = function(package,sessiondata) end get_config = function() - local config = format.parse_configfile2(fs.read_file(configfile), "") + local config = format.parse_ini_file(fs.read_file(configfile), "") local source = cfe({ value=config.APK_PATH or "", label="APK Source" }) return cfe({ type="group", value={source=source}, label="APK Config" }) end @@ -57,7 +57,7 @@ set_config = function(newconfig) -- FIXME - don't know how to validate local success = true if success then - fs.write_file(configfile, format.update_configfile2(fs.read_file(configfile) or "", "", "APK_PATH", newconfig.value.source.value)) + fs.write_file(configfile, format.update_ini_file(fs.read_file(configfile) or "", "", "APK_PATH", newconfig.value.source.value)) else newconfig.errtxt = "Failed to update config" end -- cgit v1.2.3