extracted directive to file