Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(mkdir): consistent error handling #854

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Commits on Jun 3, 2018

  1. refactor(mkdir): consistent error handling

    This refactors mkdir() to (for the most part) invoke mkdirSync() and
    catch any exceptions, instead of the error-prone approach of trying to
    predict when specific errors would happen.
    
    This adds two new tests for "name too long" and that it's OK to `mkdir
    -p` a directory which already exists. The latter was implicitly covered
    by another test case, but this should be explicit.
    
    Lastly, this changes error messages to be more consistent with Linux
    mkdir, and adds the "avoid-escape" rule in the test directory to allow
    using double-quoted strings when it aids readability.
    
    Fixes #722
    nfischer committed Jun 3, 2018
    Configuration menu
    Copy the full SHA
    dac1a48 View commit details
    Browse the repository at this point in the history
  2. move dir into temp dir

    nfischer committed Jun 3, 2018
    Configuration menu
    Copy the full SHA
    17b10b9 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    03d08f3 View commit details
    Browse the repository at this point in the history
  4. Revert "try to join paths differently in test"

    This didn't fix the issue for Windows.
    
    This reverts commit 03d08f3.
    nfischer committed Jun 3, 2018
    Configuration menu
    Copy the full SHA
    c28319f View commit details
    Browse the repository at this point in the history

Commits on Jun 26, 2018

  1. move object to module scope

    nfischer committed Jun 26, 2018
    Configuration menu
    Copy the full SHA
    95bfdd1 View commit details
    Browse the repository at this point in the history