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

Extra folder created #114

Open
orosmatthew opened this issue May 1, 2023 · 1 comment
Open

Extra folder created #114

orosmatthew opened this issue May 1, 2023 · 1 comment

Comments

@orosmatthew
Copy link

I have code to loop and create multiple repos in the repo/ directory as shown. It does this all correctly but also creates an empty folder in my main project directory. I can confirm that the repos.create() method is the problem because when I comment it out, the extra folder is not created.

extra_folder.mp4
@orosmatthew
Copy link
Author

The problem seems to be here in git.ts

    if (typeof callback !== 'function')
      callback = () => {
        return;
      };

    if (!/\.git$/.test(repo)) repo += '.git';

    const exists = this.exists(repo);

    if (!exists) {
      this.mkdir(repo);
    }

    next(this);

The this.mkdir is creating the folder in the wrong directory

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant