apple / apple/container

[Request]: Add directory creation utility to ApplicationRoot

Open Beginner friendly
#2,215 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Swift
Stars
49.9k
Forks
1.8k
Avg merge
1d 20h
Merged PRs (30d)
22

Description

### Feature or enhancement request details

## Feature Description
To make `ApplicationRoot` more practical and prevent runtime errors when managing storage paths, we can introduce a utility method that ensures the root directory exists on disk.

## Proposed Changes
- Add `createDirectoryIfNeeded()` static method to `ApplicationRoot`.
- Automatically create the directory and any intermediate directories if they do not already exist.

### Code of Conduct

- [x] I agree to follow this project's Code of Conduct

Contributor guide

Open the contributing guide

Research direction

Start at the ApplicationRoot definition and inspect how its storage path is represented and used. Add coverage for an existing directory, a missing directory, and missing intermediate directories; done means the static method creates the complete path without runtime errors.

Written by the indexing model from the issue text.

Assessment

Tech stack
swift
Domain
cli
Issue type
Feature
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
72/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.