File: disable-prettier.patch

package info (click to toggle)
jupyterlab 4.0.11%2Bds1%2B~cs11.25.27-8
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 43,508 kB
  • sloc: javascript: 18,395; python: 8,932; sh: 399; makefile: 95; perl: 33; xml: 1
file content (60 lines) | stat: -rw-r--r-- 1,881 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
From: Yadd <yadd@debian.org>
Date: Wed, 5 Jun 2024 15:52:53 +0200
Subject: disable prettier

Forwarded: not-needed
Last-Update: 2023-09-02
---
 buildutils/src/ensure-package.ts | 6 ++----
 packages/lsp/schema.js           | 7 +------
 2 files changed, 3 insertions(+), 10 deletions(-)

diff --git a/buildutils/src/ensure-package.ts b/buildutils/src/ensure-package.ts
index 0522ff5..add5ed4 100644
--- a/buildutils/src/ensure-package.ts
+++ b/buildutils/src/ensure-package.ts
@@ -7,7 +7,6 @@ import * as fs from 'fs-extra';
 import * as glob from 'glob';
 import * as minimatch from 'minimatch';
 import * as path from 'path';
-import * as prettier from 'prettier';
 import * as ts from 'typescript';
 import { getDependency } from './get-dependency';
 import * as utils from './utils';
@@ -893,9 +892,8 @@ async function ensureFile(
   }
 
   // (maybe) run the newly generated contents through prettier before comparing
-  let formatted = prettify
-    ? await prettier.format(contents, { filepath: fpath, singleQuote: true })
-    : contents;
+  // DEBIAN HOOK: prettier disabled
+  let formatted = contents;
 
   const prev = fs.readFileSync(fpath, { encoding: 'utf8' });
   if (prev.indexOf('\r') !== -1) {
diff --git a/packages/lsp/schema.js b/packages/lsp/schema.js
index 4a430c4..d5acb9c 100644
--- a/packages/lsp/schema.js
+++ b/packages/lsp/schema.js
@@ -4,7 +4,6 @@
 const childProcess = require('child_process');
 const json2ts = require('json-schema-to-typescript');
 const fs = require('fs');
-const prettier = require('prettier');
 
 const SCHEMA_PATH = 'src/schema.ts';
 const PLUGIN_PATH = 'src/plugin.ts';
@@ -27,11 +26,7 @@ async function generateInterface(schemaPath, filepath) {
     }
   });
 
-  const formatted = prettier.format(content, {
-    ...prettierConfig,
-    filepath
-  });
-  return formatted;
+  return content;
 }
 
 function getSchemaPath() {