Hello all,
I'm struggling since last week to extract some text from the configuration files. I think you guys are better than me at bash + regexp.
I need to extract the config values from a configuration file. For example, I have a config file (I modified my configuration to be able to sync multiple directories):
---- lipsync.lua
sync{
default.rsyncssh,
source="/home/sergio/lipsync/",
targetdir="/home/sergio/lipsync/",
rsyncOpts="-ltusravC",
offline=true
init=false
}
sync{
default.rsyncssh, source="/home/sergio/bright/",
offline=true
rsyncOpts="-ltusravC", init=false
}
---- end
I need to be able to extract the "source", "host", "target", "offline" and "rsyncOpts" values to trigger a sync event when back online.
Can you help me ?
Thanks in advance.
Sergio