Build & lifecycle improvements

Fixed file mode