fold-dir solution