Output directory handling