8000 "Stash selected files..." fails if selected files are not staged or if stash message is more than a single word · Issue #99 · artrz/vscode-gitstash · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
"Stash selected files..." fails if selected files are not staged or if stash message is more than a single word #99
Open
@jolsen-mitsu

Description

@jolsen-mitsu

The "Stash selected files..." fails with did not match any file(s) known to git error messages if the selected file(s) are not also staged. Adding the -u parameter will allow git to stash unstaged selected files, too.

It also looks like the stash message is not quoted, which causes issues if the stash message is more than a single word. The parameter should be quoted (with any quotes within the message escaped with a backslash) to prevent this error.
Example of quoted string with internal quotes escaped:
"This is \"the\" way to do it"

Change the current command being executed from:
git stash push -m MESSAGEHERE -- PATHSHERE
to:
git stash push -m "QUOTEESCAPEDMESSAGEHERE" -u -- PATHSHERE

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

      0