refactor: refactor setting and config file