Last active
January 19, 2018 11:16
-
-
Save keinajar/c52d90cded491f82ffbbf5939fc1b044 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
mkdir git-stash-test | |
cd git-stash-test | |
mkdir component | |
mkdir common | |
touch component/a.scss component/b.scss common/c.scss | |
git init . | |
git add . | |
git commit -m "Added files" | |
echo "modifications for a" > component/a.scss | |
touch common/untracked.scss | |
git status -s | |
git stash push -m "stashing scss" -- *.scss | |
git status -s | |
git stash pop |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Initialized empty Git repository in /Users/keinajar/git-test/git-stash-test/.git/ | |
[master (root-commit) d4e31ce] Added files | |
3 files changed, 0 insertions(+), 0 deletions(-) | |
create mode 100644 common/c.scss | |
create mode 100644 component/a.scss | |
create mode 100644 component/b.scss | |
M component/a.scss | |
?? common/untracked.scss | |
Saved working directory and index state On master: stashing scss | |
On branch master | |
Changes not staged for commit: | |
(use "git add <file>..." to update what will be committed) | |
(use "git checkout -- <file>..." to discard changes in working directory) | |
modified: component/a.scss | |
no changes added to commit (use "git add" and/or "git commit -a") | |
Dropped refs/stash@{0} (e47f5f26ea805e7a2245f90d7502d56a15707fe6) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Relates to SO question: https://stackoverflow.com/q/48339061/216129