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

Lost new untracked files #779

Closed
misha-erm opened this issue Jan 26, 2020 · 30 comments · Fixed by #780
Closed

Lost new untracked files #779

misha-erm opened this issue Jan 26, 2020 · 30 comments · Fixed by #780
Labels

Comments

@misha-erm
Copy link

Hello there.

For the second time I experience very strange issue which leads to total lose of unstaged files :((((

I had some changes and few new files. I did:

  • git add
  • git commit

After running all the hooks I can see that all my new files are lost.

Thanks in advance for any help

image

Here is log from console:

cast-call-client on  integrate-tailwindcss [$✘!?] via ⬢ v12.14.1
➜ gst                                                                                                       21:12:54
On branch integrate-tailwindcss
Changes not staged for commit:
  (use "git add/rm <file>..." to update what will be committed)
  (use "git checkout -- <file>..." to discard changes in working directory)

	modified:   .eslintrc
	modified:   package-lock.json
	modified:   packages/client/.flowconfig
	deleted:    packages/client/.storybook/addons.js
	deleted:    packages/client/.storybook/config.js
	deleted:    packages/client/flow-typed/npm/styled-components_v3.x.x.js
	modified:   packages/client/package-lock.json
	modified:   packages/client/package.json
	modified:   packages/client/src/app.jsx
	deleted:    packages/client/src/assets/castcalls-logo.png
	deleted:    packages/client/src/assets/logo_black.png
	modified:   packages/client/src/components/Header.jsx
	modified:   packages/client/src/components/portfolio/PortfolioGrid.stories.jsx
	modified:   packages/client/src/components/portfolio/PortfolioPreview.stories.jsx
	modified:   packages/client/src/components/portfolio/PortfolioTile.stories.jsx
	modified:   packages/client/src/components/portfolio/PortfolioTileWithPreview.stories.jsx
	modified:   packages/client/src/components/portfolio/portfolio-tile/PortfolioTileInfo.stories.jsx
	modified:   packages/client/src/components/subscriptions/stories/InvolvementCard.stories.jsx
	modified:   packages/client/src/components/subscriptions/subscription-grid/SubscriptionGrid.stories.jsx
	modified:   packages/client/src/components/subscriptions/subscription-grid/components/SubscriptionPortfolioTile.stories.jsx
	modified:   packages/client/src/index.jsx
	modified:   packages/client/src/pages/landing/LandingPage.jsx
	modified:   packages/client/src/router/MainRouter.jsx
	modified:   packages/client/src/style-config.js

Untracked files:
  (use "git add <file>..." to include in what will be committed)

	packages/client/.storybook/main.js
	packages/client/.storybook/preview.js
	packages/client/flow-typed/npm/classnames_v2.x.x.js
	packages/client/postcss.config.js
	packages/client/src/assets/Logos/
	packages/client/src/cc-kit/
	packages/client/src/components/Header.stories.jsx
	packages/client/src/tailwind-out.css
	packages/client/src/tailwind.config.js
	packages/client/src/tailwind.css
	packages/client/src/utils/MediaMatcher.js
	packages/tests/package-lock.json

no changes added to commit (use "git add" and/or "git commit -a")

cast-call-client on  integrate-tailwindcss [$✘!?] via ⬢ v12.14.1
➜ ga packages/client/package.json                                                                           21:12:55

cast-call-client on  integrate-tailwindcss [$✘!+?] via ⬢ v12.14.1
➜ gst                                                                                                       21:13:18
On branch integrate-tailwindcss
Changes to be committed:
  (use "git reset HEAD <file>..." to unstage)

	modified:   packages/client/package.json

Changes not staged for commit:
  (use "git add/rm <file>..." to update what will be committed)
  (use "git checkout -- <file>..." to discard changes in working directory)

	modified:   .eslintrc
	modified:   package-lock.json
	modified:   packages/client/.flowconfig
	deleted:    packages/client/.storybook/addons.js
	deleted:    packages/client/.storybook/config.js
	deleted:    packages/client/flow-typed/npm/styled-components_v3.x.x.js
	modified:   packages/client/package-lock.json
	modified:   packages/client/src/app.jsx
	deleted:    packages/client/src/assets/castcalls-logo.png
	deleted:    packages/client/src/assets/logo_black.png
	modified:   packages/client/src/components/Header.jsx
	modified:   packages/client/src/components/portfolio/PortfolioGrid.stories.jsx
	modified:   packages/client/src/components/portfolio/PortfolioPreview.stories.jsx
	modified:   packages/client/src/components/portfolio/PortfolioTile.stories.jsx
	modified:   packages/client/src/components/portfolio/PortfolioTileWithPreview.stories.jsx
	modified:   packages/client/src/components/portfolio/portfolio-tile/PortfolioTileInfo.stories.jsx
	modified:   packages/client/src/components/subscriptions/stories/InvolvementCard.stories.jsx
	modified:   packages/client/src/components/subscriptions/subscription-grid/SubscriptionGrid.stories.jsx
	modified:   packages/client/src/components/subscriptions/subscription-grid/components/SubscriptionPortfolioTile.stories.jsx
	modified:   packages/client/src/index.jsx
	modified:   packages/client/src/pages/landing/LandingPage.jsx
	modified:   packages/client/src/router/MainRouter.jsx
	modified:   packages/client/src/style-config.js

Untracked files:
  (use "git add <file>..." to include in what will be committed)

	packages/client/.storybook/main.js
	packages/client/.storybook/preview.js
	packages/client/flow-typed/npm/classnames_v2.x.x.js
	packages/client/postcss.config.js
	packages/client/src/assets/Logos/
	packages/client/src/cc-kit/
	packages/client/src/components/Header.stories.jsx
	packages/client/src/tailwind-out.css
	packages/client/src/tailwind.config.js
	packages/client/src/tailwind.css
	packages/client/src/utils/MediaMatcher.js
	packages/tests/package-lock.json


cast-call-client on  integrate-tailwindcss [$✘!+?] via ⬢ v12.14.1
➜ gc -m 'integrate-tailwindcss'                                                                             21:13:19
husky > pre-commit (node v12.14.1)
  ✔ Preparing...
  ✔ Running tasks...
  ✔ Applying modifications...
  ✔ Cleaning up...
[integrate-tailwindcss 2c1a81f] integrate-tailwindcss
 1 file changed, 15 insertions(+), 4 deletions(-)

cast-call-client on  integrate-tailwindcss [$✘!] via ⬢ v12.14.1 took 2s
➜ gst                                                                                                       21:13:25
On branch integrate-tailwindcss
Changes not staged for commit:
  (use "git add/rm <file>..." to update what will be committed)
  (use "git checkout -- <file>..." to discard changes in working directory)

	modified:   .eslintrc
	modified:   package-lock.json
integrate-tailwindcss
	modified:   packages/client/.flowconfig
	deleted:    packages/client/.storybook/addons.js
	deleted:    packages/client/.storybook/config.js
	deleted:    packages/client/flow-typed/npm/styled-components_v3.x.x.js
	modified:   packages/client/package-lock.json
	modified:   packages/client/src/app.jsx
	deleted:    packages/client/src/assets/castcalls-logo.png
	deleted:    packages/client/src/assets/logo_black.png
	modified:   packages/client/src/components/Header.jsx
	modified:   packages/client/src/components/portfolio/PortfolioGrid.stories.jsx
	modified:   packages/client/src/components/portfolio/PortfolioPreview.stories.jsx
	modified:   packages/client/src/components/portfolio/PortfolioTile.stories.jsx
	modified:   packages/client/src/components/portfolio/PortfolioTileWithPreview.stories.jsx
	modified:   packages/client/src/components/portfolio/portfolio-tile/PortfolioTileInfo.stories.jsx
	modified:   packages/client/src/components/subscriptions/stories/InvolvementCard.stories.jsx
	modified:   packages/client/src/components/subscriptions/subscription-grid/SubscriptionGrid.stories.jsx
	modified:   packages/client/src/components/subscriptions/subscription-grid/components/SubscriptionPortfolioTile.stories.jsx
	modified:   packages/client/src/index.jsx
	modified:   packages/client/src/pages/landing/LandingPage.jsx
	modified:   packages/client/src/router/MainRouter.jsx
	modified:   packages/client/src/style-config.js

no changes added to commit (use "git add" and/or "git commit -a")

Environment

  • OS: macOs Catalina 10.15.1
  • Node.js: 12.14.1
  • lint-staged: 10.0.0
@misha-erm misha-erm changed the title New files are fully reset Lost new untracked files Jan 26, 2020
@iiroj
Copy link
Member

iiroj commented Jan 26, 2020

This definitely shouldn't happen.

What's your git version? I see this is a monorepo, are you running lint-staged in a subdirectory or the main git repo root directory? Can you run using the --debug flag and post the output?

The untracked files are hidden into the main backup stash, using git stash --include-untracked --keep-index and restored after the tasks have run. If they're not back, there might be something wrong in this part.

Can you add an untracked file, and then run these commands:

git  stash save --include-untracked --keep-index
git stash pop

If the untracked file is back, then it might not be a direct Git issue but something else.

@misha-erm
Copy link
Author

Thanks for the fast reply

git version 2.21.0 (Apple Git-122)

Yes, it's a monorepo and lint-staged is set up on the root

@misha-erm
Copy link
Author

Maybe you know some way to restore those files? A little bit afraid to do something with 'stash' is there is a chance to restore them. Lost work results from few days

@iiroj
Copy link
Member

iiroj commented Jan 26, 2020

The command git reflog might help with that.

@kratos-42
Copy link

kratos-42 commented Jan 27, 2020

I'm also experiencing this. I've been trying to figure out why this is happening, and as far as I could understand, I think this is happening because when executing the stashBackup, the unstagedDiff will just store the already existing files (git diff [--options] stash@{n} will not display nothing for untracked files since they are on the third parent of a stash commit). In order to add the untracked files code to unstagedDiff, we can do it by executing git rev-list -g stash | git rev-list --stdin --max-parents=0 | xargs git diff --binary --unified=0 --no-color --no-ext-diff --patch.

(This is undesired behaviour is not happening in version v10.0.0-beta.1).

@jefrydco
Copy link

After upgrading to version 10, I'm experiencing this as well. I lost my entirely untracked files. Unfortunately, VSCode keeps the files open so that I can save it again. But the static files I made are all gone.

In order to get the untracked files code we can do it by executing git rev-list -g stash | git rev-list --stdin --max-parents=0 | xargs git diff --binary --unified=0 --no-color --no-ext-diff --patch.

Hi @kratos-42 , when I run that command, it returns

image

I'm reverting back to use version 9.

@kratos-42
Copy link

kratos-42 commented Jan 27, 2020

@jefrydco when I said to run that command I was proposing a solution to solve the bug, and not providing a way to get your files back. I'm sorry if I was not clear.
(Btw, you are getting that error probably because your stash is empty).

@iiroj
Copy link
Member

iiroj commented Jan 27, 2020

I’m terribly sorry about this bug, and I’ve no idea where it comes from since it hasn’t been an issue during development.

I’ll try to get this fixed ASAP. The first thing to do is throw errors when restoring untracked files fails, so the process fails and everything gets restored.

Are there a lot of untracked files when this happens? The tests only use a single untracked file so maybe it’s maybe it’s related to the size of the diff (speculating based on the first report’s git status).

@kratos-42
Copy link

kratos-42 commented Jan 27, 2020

I don't think there is a failure in restoring to be thrown. I think the problem is in the response from the git diff because it does not include the untracked files code, so when executing git apply the only changes it will apply/restore are just for the files that already exists (remotely or in a previous commit).

It happens no matter if there's just one or many untracked files.

@iiroj
Copy link
Member

iiroj commented Jan 27, 2020

The untracked files are restored separately from the this.unstagedDiff here:

https://github.com/okonet/lint-staged/blob/293547d46080eac007393709a0d63a63f2063fff/lib/gitWorkflow.js#L200

This happens after running tasks and applying back the unstaged diff. The untracked files are taken straight from the third commit.

@jefrydco
Copy link

@kratos-42 Oke, got it. My stash files aren't empty anyway.

Are there a lot of untracked files when this happens? The tests only use a single untracked file so maybe it’s maybe it’s related to the size of the diff (speculating based on the first report’s git status).

I think the @kratos-42 opinion was right. It will apply/restore are just for the files that already exist. My unstaged files are mostly just created and there was a lot of them.

@iiroj
Copy link
Member

iiroj commented Jan 27, 2020

The untracked diff might not have taken binary files into acocunt, because the --binary flag was missing. Could this be the reason?

@jefrydco
Copy link

I don't know what kind of binary files you mean, but my untracked files were consists of markdown, images and video files. The files that already exist were unfortunately opened in VS Code so I can save it again. But the images and video were all gone.

@kratos-42
Copy link

The untracked diff might not have taken binary files into acocunt, because the --binary flag was missing. Could this be the reason?

I tried using the --binary flag and it indeed worked for .js files. However, for an image it did not work...

@iiroj
Copy link
Member

iiroj commented Jan 27, 2020

I'm afraid the error may have been caused by the combination of the missing --binary flag and the empty catch {}. These in combination would not cause lint-staged to abort when the patch failed to apply.

I've opened #780 for this issue.

@kratos-42
Copy link

kratos-42 commented Jan 27, 2020

Sorry man, but I don't think that is enough to solve the problem. Using --binary the git show output is fine, but the changes are not being applied as expected. The binary files are still being deleted and no error is being thrown.

@iiroj
Copy link
Member

iiroj commented Jan 27, 2020

@kratos-42 If you're able to debug further, are the binary files in the diff, or missing?

I'll try this:

  1. add new untracked binary file
  2. create a stash with --include-untracked
  3. get the diff
  4. apply it
  5. ???
  6. see if binary file is back

EDIT: This works at least when manually running the commands. The major difference is that I'm piping the output of the diff to git apply, vs. lint-staged saves it in a variable.

@kratos-42
Copy link

@kratos-42 If you're able to debug further, are the binary files in the diff, or missing?

The binary files are in the diff.

@iiroj
Copy link
Member

iiroj commented Jan 27, 2020

@kratos-42 In the PR, if the git apply step fails, it now throws an error. This will cause lint-staged to do a git reset and return to the original state by applying the entire backup stash. In this sense it would fix the current behaviour.

However, it would be nice to figure out why it doesn't apply.

@misha-erm
Copy link
Author

The command git reflog might help with that.

Tried it but haven't found any info about lost files in commits here (

@kratos-42
Copy link

kratos-42 commented Jan 27, 2020

However, it would be nice to figure out why it doesn't apply.

Well, a possibly an error with execa input option?

The major difference is that I'm piping the output of the diff to git apply, vs. lint-staged saves it in a variable.

A way to do this could be redirecting the output to a file and read from there, something like:

await execa(
  'git',
  [
    'show',
    ...GIT_DIFF_ARGS,
    '--format=%b',
    `${backupStash}^3`
  ],
  { all: true, cwd: process.cwd() }
).stdout.pipe(fs.createWriteStream('stdout.patch'));

await this.execGit([...GIT_APPLY_ARGS, 'stdout.patch']);

@iiroj
Copy link
Member

iiroj commented Jan 27, 2020

@MikeYermolayev Maybe read this if it contains something that can help:
https://stackoverflow.com/questions/89332/how-to-recover-a-dropped-stash-in-git

@kratos-42 Thanks for the suggestion. Since we create two diffs (unstaged, untracked), I'd then probably redirect both of those to files. The files should probably be deleted right after applying.

@misha-erm
Copy link
Author

Thanks a lot!

Your link helped and I was able to find my files pretty easily by using
gitk --all $( git fsck --no-reflog | awk '/dangling commit/ {print $3}' )

@iiroj
Copy link
Member

iiroj commented Jan 27, 2020

@kratos-42 based on your suggestion, I pushed new commits to #780 that, instead of using variables inside the Node.js process, saves the unstaged and untracked diffs temporarily inside the .git directory (so as to not mess up git status). The files are then deleted in the cleanup step.

Can you perhaps test this yourself?

@kratos-42
Copy link

@iiroj Everything is perfectly working 👌

@iiroj
Copy link
Member

iiroj commented Jan 27, 2020

@kratos-42 Very good! We'll assume that one contributing factor was indeed the very large size of the diff.

iiroj added a commit that referenced this issue Jan 27, 2020
If you were affected by this bug and lost untracked files, you can try to restore them with:

```sh
gitk --all $( git fsck --no-reflog | awk '/dangling commit/ {print $3}' )
```

Please see #779 and https://stackoverflow.com/questions/89332/how-to-recover-a-dropped-stash-in-git for more info
@okonet
Copy link
Collaborator

okonet commented Jan 27, 2020

🎉 This issue has been resolved in version 10.0.3 🎉

The release is available on:

Your semantic-release bot 📦🚀

@cjones26
Copy link

FYI I also experienced a similar issue to this (not sure if it's the same thing as this is marked as fixed) with lint-staged 10.5.3, though I was luckily able to retrieve my files utilizing the tip from @MikeYermolayev above.

@raldred
Copy link

raldred commented Aug 26, 2021

lint-staged 11.1.2 just lost an untracked file whilst running prettier and eslint (failed)
No sign in stash
Nothing found in gitk as suggested by @MikeYermolayev

MacOS: 11.2
Git: 2.33 (homebrew)

@smasilamani-cfins
Copy link

smasilamani-cfins commented Feb 13, 2022

Same here. I keep losing all the files including the existing one that have been modified. I keep those files open in VScode and then saving them again to restore. However this happens only in one repo and other repos are working fine. Everything is same like the version/OS/folder structure etc except that any changes made in the file in this repo are getting deleted. However it keeps some of the files, for e.g it keeps pacakge.json file but all my typescript files are keep getting deleted. As you can see at the end it says 1 deletion where in fact I have not deleted any files.

git version 2.32.0
lint-staged version : ^12.3.3

package.json

"husky": {
		"hooks": {
			"pre-commit": "lint-staged --debug"
		}
	},
	"lint-staged": {
		"**/*.ts": [
			"npx --no-install eslint -c ./.eslintrc.js",
			"npm run compile"
		]
	}

Here is the debug log

husky > pre-commit (node v16.13.2)
  lint-staged:bin Running `lint-staged@12.3.3` +0ms
  lint-staged:bin Options parsed from command-line: {
  allowEmpty: false,
  concurrent: true,
  configPath: undefined,
  cwd: undefined,
  debug: true,
  maxArgLength: 65536,
  quiet: false,
  relative: false,
  shell: false,
  stash: true,
  verbose: false
} +1ms
  lint-staged:validateOptions Validating options... +0ms
  lint-staged:validateOptions Validated options! +1ms
  lint-staged Unset GIT_LITERAL_PATHSPECS (was `undefined`) +0ms
  lint-staged:runAll Running all linter scripts... +0ms
  lint-staged:runAll Using working directory `/mnt/c/Repos/services` +1ms
  lint-staged:resolveGitRepo Resolving git repo from `/mnt/c/Repos/services` +0ms
  lint-staged:resolveGitRepo Unset GIT_DIR (was `undefined`) +0ms
  lint-staged:resolveGitRepo Unset GIT_WORK_TREE (was `undefined`) +1ms
  lint-staged:execGit Running git command [ 'rev-parse', '--show-prefix' ] +0ms
  lint-staged:resolveGitRepo Resolved git directory to be `/mnt/c/Repos/services` +24ms
  lint-staged:resolveGitRepo Resolved git config directory to be `/mnt/c/Repos/services/.git` +1ms
  lint-staged:execGit Running git command [ 'log', '-1' ] +25ms
  lint-staged:execGit Running git command [ 'diff', '--staged', '--diff-filter=ACMR', '--name-only', '-z' ] +23ms
  lint-staged:runAll Loaded list of staged files in git:
  lint-staged:runAll [
  lint-staged:runAll   '/mnt/c/Repos/services/package.json',
  lint-staged:runAll   '/mnt/c/Repos/services/src/shared/shared.module.ts'
  lint-staged:runAll ] +69ms
  lint-staged:getConfigGroups Grouping configuration files... +0ms
  lint-staged:getConfigGroups Grouping staged files by their directories... +0ms
  lint-staged:getConfigGroups Grouped staged files into 2 directories: +0ms
  lint-staged:getConfigGroups {
  lint-staged:getConfigGroups   '/mnt/c/Repos/services': [ '/mnt/c/Repos/services/package.json' ],
  lint-staged:getConfigGroups   '/mnt/c/Repos/services/src/shared': [ '/mnt/c/Repos/services/src/shared/shared.module.ts' ]
  lint-staged:getConfigGroups } +2ms
  lint-staged:getConfigGroups Searching config files... +1ms
  lint-staged:loadConfig Searching for configuration from `/mnt/c/Repos/services`... +0ms
  lint-staged:loadConfig Successfully loaded config from `/mnt/c/Repos/services/package.json`:
  lint-staged:loadConfig {
  lint-staged:loadConfig   './**/*.ts': [ 'npx --no-install eslint -c ./.eslintrc.js', 'npm run compile' ]
  lint-staged:loadConfig } +2ms
  lint-staged:getConfigGroups Found new config "/mnt/c/Repos/services/package.json" from "/mnt/c/Repos/services"! +4ms
  lint-staged:validateConfig Validating config from `/mnt/c/Repos/services/package.json`... +0ms
  lint-staged:validateConfig Validated config from `/mnt/c/Repos/services/package.json`: +0ms
  lint-staged:validateConfig {
  lint-staged:validateConfig   './**/*.ts': [ 'npx --no-install eslint -c ./.eslintrc.js', 'npm run compile' ]
  lint-staged:validateConfig } +1ms
  lint-staged:loadConfig Searching for configuration from `/mnt/c/Repos/services`... +3ms
  lint-staged:loadConfig Searching for configuration from `/mnt/c/Repos/services/src/shared`... +1ms
  lint-staged:loadConfig Successfully loaded config from `/mnt/c/Repos/services/package.json`:
  lint-staged:loadConfig {
  lint-staged:loadConfig   './**/*.ts': [ 'npx --no-install eslint -c ./.eslintrc.js', 'npm run compile' ]
  lint-staged:loadConfig } +2ms
  lint-staged:getConfigGroups Found existing config "/mnt/c/Repos/services/package.json" from "/mnt/c/Repos/services"! +6ms
  lint-staged:loadConfig Successfully loaded config from `/mnt/c/Repos/services/package.json`:
  lint-staged:loadConfig {
  lint-staged:loadConfig   './**/*.ts': [ 'npx --no-install eslint -c ./.eslintrc.js', 'npm run compile' ]
  lint-staged:loadConfig } +6ms
  lint-staged:getConfigGroups Found existing config "/mnt/c/Repos/services/package.json" from "/mnt/c/Repos/services/src/shared"! +6ms
  lint-staged:getConfigGroups Grouped staged files into 1 groups! +1ms
  lint-staged:chunkFiles Resolved an argument string length of 96 characters from 2 files +0ms
  lint-staged:chunkFiles Creating 1 chunks for maxArgLength of 65536 +1ms
  lint-staged:generateTasks Generating linter tasks +0ms
  lint-staged:generateTasks Generated task:
  lint-staged:generateTasks {
  lint-staged:generateTasks   pattern: './**/*.ts',
  lint-staged:generateTasks   commands: [ 'npx --no-install eslint -c ./.eslintrc.js', 'npm run compile' ],
  lint-staged:generateTasks   fileList: [ '/mnt/c/Repos/services/src/shared/shared.module.ts' ]
  lint-staged:generateTasks } +1ms
  lint-staged:makeCmdTasks Creating listr tasks for commands [ 'npx --no-install eslint -c ./.eslintrc.js', 'npm run compile' ] +0ms
  lint-staged:resolveTaskFn cmd: npx +0ms
  lint-staged:resolveTaskFn args: [ '--no-install', 'eslint', '-c', './.eslintrc.js' ] +0ms
  lint-staged:resolveTaskFn execaOptions: {
  cwd: '/mnt/c/Repos/services',
  preferLocal: true,
  reject: false,
  shell: false
} +0ms
  lint-staged:resolveTaskFn cmd: npm +2ms
  lint-staged:resolveTaskFn args: [ 'run', 'compile' ] +0ms
  lint-staged:resolveTaskFn execaOptions: {
  cwd: '/mnt/c/Repos/services',
  preferLocal: true,
  reject: false,
  shell: false
} +1ms
  lint-staged:chunkFiles Resolved an argument string length of 55 characters from 1 files +9ms
  lint-staged:chunkFiles Creating 1 chunks for maxArgLength of 65536 +0ms
[STARTED] Preparing lint-staged...
  lint-staged:GitWorkflow Backing up original state... +0ms
  lint-staged:GitWorkflow Getting partially staged files... +0ms
  lint-staged:execGit Running git command [ 'status', '-z' ] +58ms
  lint-staged:GitWorkflow Found partially staged files: [] +39ms
  lint-staged:GitWorkflow Backing up merge state... +1ms
  lint-staged:file Reading file `/mnt/c/Repos/services/.git/MERGE_HEAD` +0ms
  lint-staged:file Reading file `/mnt/c/Repos/services/.git/MERGE_MODE` +0ms
  lint-staged:file Reading file `/mnt/c/Repos/services/.git/MERGE_MSG` +0ms
  lint-staged:file File `/mnt/c/Repos/services/.git/MERGE_HEAD` doesn't exist, ignoring... +1ms
  lint-staged:file File `/mnt/c/Repos/services/.git/MERGE_MODE` doesn't exist, ignoring... +0ms
  lint-staged:file File `/mnt/c/Repos/services/.git/MERGE_MSG` doesn't exist, ignoring... +1ms
  lint-staged:GitWorkflow Done backing up merge state! +3ms
  lint-staged:GitWorkflow Getting deleted files... +1ms
  lint-staged:execGit Running git command [ 'ls-files', '--deleted' ] +43ms
  lint-staged:GitWorkflow Found deleted files: [] +22ms
  lint-staged:execGit Running git command [ 'stash', 'create' ] +22ms
  lint-staged:execGit Running git command [
  'stash',
  'store',
  '--quiet',
  '--message',
  'lint-staged automatic backup',
  '865dcc3e01539c2e4075d865e62bdcc2b693fb01'
] +77ms
  lint-staged:GitWorkflow Done backing up original state! +121ms
[SUCCESS] Preparing lint-staged...
[STARTED] Running tasks for staged files...
[STARTED] package.json — 2 files
[STARTED] ./**/*.ts — 1 file
[STARTED] npx --no-install eslint -c ./.eslintrc.js
[SUCCESS] npx --no-install eslint -c ./.eslintrc.js
[STARTED] npm run compile
[SUCCESS] npm run compile
[SUCCESS] ./**/*.ts — 1 file
[SUCCESS] package.json — 2 files
[SUCCESS] Running tasks for staged files...
[STARTED] Applying modifications from tasks...
  lint-staged:GitWorkflow Adding task modifications to index... +24s
  lint-staged:execGit Running git command [
  'add',
  '--',
  '/mnt/c/Repos/services/src/shared/shared.module.ts'
] +24s
  lint-staged:GitWorkflow Done adding task modifications to index! +35ms
  lint-staged:execGit Running git command [ 'diff', '--name-only', '--cached' ] +34ms
[SUCCESS] Applying modifications from tasks...
[STARTED] Cleaning up temporary files...
  lint-staged:GitWorkflow Dropping backup stash... +21ms
  lint-staged:execGit Running git command [ 'stash', 'list' ] +21ms
  lint-staged:execGit Running git command [ 'stash', 'drop', '--quiet', 'refs/stash@{0}' ] +28ms
  lint-staged:GitWorkflow Done dropping backup stash! +82ms
[SUCCESS] Cleaning up temporary files...
  lint-staged Tasks were executed successfully! +24s
[feature/package_upgrades 0aee73e] Added missing file
 1 file changed, 1 insertion(+), 1 deletion(-)

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

Successfully merging a pull request may close this issue.

8 participants