Skip to content

simple-git 3.32.0 mistakenly recognizes any clone option with u as unsafe #1121

@stevenwdv

Description

@stevenwdv
simpleGit().clone(url, dir, ['--no-checkout'])

Errors with:

Use of clone with option -u is not permitted without enabling allowUnsafePack

Because --no-checkout is marked as unsafe because as it contains a 'u'.

This seems to be caused by 1effd8e.
Affected version: 3.32.0, works fine in 3.31.1.

I didn't check, but I suspect this will also happen with options like -oyourremote (-o<name> is --origin=<name>).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions