critique 0.0.8 → 0.0.9

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.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,8 @@
1
+ # 0.0.9
2
+
3
+ - Default command:
4
+ - Increase max lines for diff display
5
+
1
6
  # 0.0.8
2
7
 
3
8
  - Default command:
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "critique",
3
3
  "module": "src/diff.tsx",
4
4
  "type": "module",
5
- "version": "0.0.8",
5
+ "version": "0.0.9",
6
6
  "private": false,
7
7
  "bin": "./src/cli.tsx",
8
8
  "scripts": {
package/src/cli.tsx CHANGED
@@ -198,25 +198,25 @@ cli
198
198
  }
199
199
 
200
200
  const files = parsePatch(gitDiff);
201
-
201
+
202
202
  const filteredFiles = files.filter((file) => {
203
203
  const fileName = file.newFileName || file.oldFileName || "";
204
204
  const baseName = fileName.split("/").pop() || "";
205
-
205
+
206
206
  if (IGNORED_FILES.includes(baseName) || baseName.endsWith(".lock")) {
207
207
  return false;
208
208
  }
209
-
209
+
210
210
  const totalLines = file.hunks.reduce((sum, hunk) => sum + hunk.lines.length, 0);
211
- return totalLines <= 1000;
211
+ return totalLines <= 6000;
212
212
  });
213
-
213
+
214
214
  const sortedFiles = filteredFiles.sort((a, b) => {
215
215
  const aSize = a.hunks.reduce((sum, hunk) => sum + hunk.lines.length, 0);
216
216
  const bSize = b.hunks.reduce((sum, hunk) => sum + hunk.lines.length, 0);
217
217
  return aSize - bSize;
218
218
  });
219
-
219
+
220
220
  setParsedFiles(sortedFiles);
221
221
  } catch (error) {
222
222
  setParsedFiles([]);
@@ -411,7 +411,7 @@ cli
411
411
  `git checkout HEAD -- "${value}"`,
412
412
  { stdio: "pipe" },
413
413
  );
414
-
414
+
415
415
  if (error) {
416
416
  if (error.includes("did not match any file(s) known to git")) {
417
417
  if (fs.existsSync(value)) {