Skip to content

Check & create parent directory before calling FileOutputStream #379

@deusaquilus

Description

@deusaquilus

In addition to #372 please check that when opening the FileOutputStream the parent directory of the file exists (and create it if it doesn't). Have a look in commons-io at FileUtils.openOutputStream (here) or PathUtils.newOutputStream (here).

Both of those functions:

  1. Check that the parent directory of the file exists, if it does not then create it.
  2. Check that the file exists
  3. Check that the file is writable (not possible with 'path' API)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions