move build logik to script