Преглед изворни кода

CI: Bump prettier to latest version (2.4.1)

We didn't initially upgrade because it started to (incorrectly) see
files as strict mode and chokes on things that then would be syntax
errors - but we're starting to fall behind a bit, so I'd rather put
these files on the ignore list instead.
Linus Groh пре 3 година
родитељ
комит
f538df7572
3 измењених фајлова са 8 додато и 5 уклоњено
  1. 1 1
      .github/workflows/cmake.yml
  2. 5 0
      .prettierignore
  3. 2 4
      Base/res/js/Spreadsheet/runtime.js

+ 1 - 1
.github/workflows/cmake.yml

@@ -49,7 +49,7 @@ jobs:
           sudo apt-get update
           sudo apt-get install libmpfr-dev libmpc-dev ninja-build e2fsprogs qemu-utils qemu-system-i386 ccache unzip
       - name: Install JS dependencies
-        run: sudo npm install -g prettier@2.2.1
+        run: sudo npm install -g prettier@2.4.1
       - name: Install Python dependencies
         # The setup-python action set default python to python3.x. Note that we are not using system python here.
         run: |

+ 5 - 0
.prettierignore

@@ -1,3 +1,8 @@
 Base/home/anon/Source/js
+Userland/Libraries/LibJS/Tests/builtins/Object/Object.prototype.toString.js
 Userland/Libraries/LibJS/Tests/eval-aliasing.js
+Userland/Libraries/LibJS/Tests/if-statement-function-declaration.js
+Userland/Libraries/LibJS/Tests/invalid-lhs-in-assignment.js
+Userland/Libraries/LibJS/Tests/operators/delete-global-variable.js
+Userland/Libraries/LibJS/Tests/operators/delete-local-variable.js
 Userland/Libraries/LibJS/Tests/unicode-identifier-escape.js

+ 2 - 4
Base/res/js/Spreadsheet/runtime.js

@@ -479,8 +479,7 @@ sumIf.__documentation = JSON.stringify({
     name: "sumIf",
     argc: 2,
     argnames: ["condition", "cell names"],
-    doc:
-        "Calculates the sum of cells the value of which evaluates to true when passed to `condition`",
+    doc: "Calculates the sum of cells the value of which evaluates to true when passed to `condition`",
     examples: {
         'sumIf(x => x instanceof Number, range("A1", "C4"))':
             "Calculates the sum of all numbers within A1:C4",
@@ -524,8 +523,7 @@ averageIf.__documentation = JSON.stringify({
     name: "averageIf",
     argc: 2,
     argnames: ["condition", "cell names"],
-    doc:
-        "Calculates the average of cells the value of which evaluates to true when passed to `condition`",
+    doc: "Calculates the average of cells the value of which evaluates to true when passed to `condition`",
     examples: {
         'averageIf(x => x > 4, range("A1", "C4"))':
             "Calculate the sum of all numbers larger then 4 within A1:C4",