Convert config loader to use __dirname