Skip to content

Commit 26b2900

Browse files
author
Colin McNeil
committed
ESLint fix
1 parent f84c6ad commit 26b2900

File tree

5 files changed

+9
-2
lines changed

5 files changed

+9
-2
lines changed

prompts/eslint/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ functions:
3535
description: Whether to fix the files
3636
outputLevel:
3737
type: number
38-
description: Accepts [0,1,2]. 0 to only output number of violations, 1 is condensed json grouped by violation id, 2 is full lint json grouped by file.
38+
description: Nullish values return a summary from the linter. `complaint` returns a list of editor complaints. `condensed` returns violations grouped by violation id. `json` returns the raw JSON output from the linter.
3939
files:
4040
type: array
4141
items:

prompts/eslint/scripts/remap_lint.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ for index in "${!FILE_PATHS[@]}"; do
2727
if [ $OUTPUT_MODE == "complaints" ]; then
2828

2929
# Complaint: {filePath: "path", "start": [line, column], "end": [line, column], "message": "message", "severity": "severity", "ruleId": "ruleId"}
30-
messages=$(echo $messages | jq -r -c '.[]')
30+
messages=$(echo $messages | jq -r -c '.[]' | tr '\n' ' ')
3131
IFS=$'\n' messages=($messages)
3232
for message in "${messages[@]}"; do
3333
# If endLine is null, set it to line
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
You are an AI assistant who specializes in resolving lint violations in projects.
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
1. Run ESLint in the project
2+
2. Evaluate total violations.

prompts/eslint_fix/README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
---
2+
functions:
3+
4+
---

0 commit comments

Comments
 (0)