@deepnote/convert 2.0.0 → 2.1.0
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/dist/bin.js +1 -9
- package/dist/index.d.ts +11924 -402
- package/dist/index.js +2 -2
- package/dist/{src-CUESP0m8.js → src-oALQkXiP.js} +53 -9
- package/package.json +2 -2
package/dist/bin.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import {
|
|
2
|
+
import { M as convertDeepnoteFileToJupyterFiles, O as convertDeepnoteFileToMarimoFiles, _ as isMarimoContent, a as convertPercentFilesToDeepnoteFile, b as convertDeepnoteFileToQuartoFiles, d as convertMarimoFilesToDeepnoteFile, p as convertIpynbFilesToDeepnoteFile, r as convertQuartoFilesToDeepnoteFile, v as isPercentContent, w as convertDeepnoteFileToPercentFiles } from "./src-oALQkXiP.js";
|
|
3
3
|
import { cli } from "cleye";
|
|
4
4
|
import fs from "node:fs/promises";
|
|
5
5
|
import { basename, extname, resolve } from "node:path";
|
|
@@ -176,14 +176,6 @@ async function convertDeepnoteToFormat(absolutePath, outputFormat, customOutputP
|
|
|
176
176
|
throw error;
|
|
177
177
|
}
|
|
178
178
|
}
|
|
179
|
-
/** Check if file content is Marimo format */
|
|
180
|
-
function isMarimoContent(content) {
|
|
181
|
-
return /^import marimo\b/m.test(content) && /@app\.cell\b/.test(content) && !/^\s*['"]{3}[\s\S]*?import marimo/m.test(content);
|
|
182
|
-
}
|
|
183
|
-
/** Check if file content is percent format */
|
|
184
|
-
function isPercentContent(content) {
|
|
185
|
-
return /^# %%/m.test(content) && !/^\s*['"]{3}[\s\S]*?# %%/m.test(content);
|
|
186
|
-
}
|
|
187
179
|
|
|
188
180
|
//#endregion
|
|
189
181
|
//#region src/bin.ts
|