lint-staged 16.1.4 → 16.1.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -39,18 +39,18 @@ export const resolveGitRepo = async (cwd = process.cwd()) => {
39
39
  try {
40
40
  debugLog('Resolving git repo from `%s`', cwd)
41
41
 
42
- /** Git rev-parse returns all three flag values on separate lines */
43
- const revParseOutput = await execGit(['rev-parse', CDUP, TOPLEVEL, ABSOLUTE_GIT_DIR], {
44
- cwd,
45
- })
46
- const [relativeTopLevelDir, topLevel, absoluteGitDir] = revParseOutput.split('\n')
47
-
48
42
  // Unset GIT_DIR before running any git operations in case it's pointing to an incorrect location
49
43
  debugLog('Unset GIT_DIR (was `%s`)', process.env.GIT_DIR)
50
44
  delete process.env.GIT_DIR
51
45
  debugLog('Unset GIT_WORK_TREE (was `%s`)', process.env.GIT_WORK_TREE)
52
46
  delete process.env.GIT_WORK_TREE
53
47
 
48
+ /** Git rev-parse returns all three flag values on separate lines */
49
+ const revParseOutput = await execGit(['rev-parse', CDUP, TOPLEVEL, ABSOLUTE_GIT_DIR], {
50
+ cwd,
51
+ })
52
+ const [relativeTopLevelDir, topLevel, absoluteGitDir] = revParseOutput.split('\n')
53
+
54
54
  const topLevelDir = normalizePath(path.join(cwd, relativeTopLevelDir))
55
55
  debugLog('Resolved git repository top-level directory to be `%s`', topLevelDir)
56
56
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lint-staged",
3
- "version": "16.1.4",
3
+ "version": "16.1.5",
4
4
  "description": "Lint files staged by git",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -51,7 +51,7 @@
51
51
  "tag": "npx changeset tag"
52
52
  },
53
53
  "dependencies": {
54
- "chalk": "^5.4.1",
54
+ "chalk": "^5.5.0",
55
55
  "commander": "^14.0.0",
56
56
  "debug": "^4.4.1",
57
57
  "lilconfig": "^3.1.3",
@@ -60,7 +60,7 @@
60
60
  "nano-spawn": "^1.0.2",
61
61
  "pidtree": "^0.6.0",
62
62
  "string-argv": "^0.3.2",
63
- "yaml": "^2.8.0"
63
+ "yaml": "^2.8.1"
64
64
  },
65
65
  "devDependencies": {
66
66
  "@changesets/changelog-github": "0.5.1",
@@ -74,7 +74,7 @@
74
74
  "eslint-config-prettier": "10.1.8",
75
75
  "eslint-plugin-jest": "29.0.1",
76
76
  "eslint-plugin-n": "17.21.3",
77
- "eslint-plugin-prettier": "5.5.3",
77
+ "eslint-plugin-prettier": "5.5.4",
78
78
  "eslint-plugin-simple-import-sort": "12.1.1",
79
79
  "husky": "9.1.7",
80
80
  "jest": "30.0.5",