now with config parsing (not complete working)