files add and refactoring on activation