filelist-utils
Advanced tools
Comparing version 1.11.0 to 1.11.1
@@ -1,2 +0,1 @@ | ||
import fetch from 'cross-fetch'; | ||
import { CachedFileCollectionItem, } from './CachedFileCollectionItem'; | ||
@@ -3,0 +2,0 @@ import { FileCollection } from './FileCollection'; |
@@ -1,4 +0,3 @@ | ||
/// <reference types="node" /> | ||
import { FileCollectionItem } from './FileCollectionItem'; | ||
export declare function ungzipStream(file: FileCollectionItem): import("stream/web").ReadableStream<any>; | ||
//# sourceMappingURL=ungzipStream.d.ts.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.fileCollectionFromFileList = void 0; | ||
exports.fileCollectionFromFileList = fileCollectionFromFileList; | ||
const FileCollection_1 = require("./FileCollection"); | ||
@@ -35,3 +35,2 @@ const expandAndFilter_1 = require("./utilities/expand/expandAndFilter"); | ||
} | ||
exports.fileCollectionFromFileList = fileCollectionFromFileList; | ||
//# sourceMappingURL=fileCollectionFromFileList.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.fileCollectionFromFiles = void 0; | ||
exports.fileCollectionFromFiles = fileCollectionFromFiles; | ||
const FileCollection_1 = require("./FileCollection"); | ||
@@ -33,3 +33,2 @@ const expandAndFilter_1 = require("./utilities/expand/expandAndFilter"); | ||
} | ||
exports.fileCollectionFromFiles = fileCollectionFromFiles; | ||
//# sourceMappingURL=fileCollectionFromFiles.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.fileCollectionFromPath = void 0; | ||
exports.fileCollectionFromPath = fileCollectionFromPath; | ||
function fileCollectionFromPath() { | ||
throw new Error('This method is not available in the browser'); | ||
} | ||
exports.fileCollectionFromPath = fileCollectionFromPath; | ||
//# sourceMappingURL=fileCollectionFromPath.browser.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.fileCollectionFromPath = void 0; | ||
exports.fileCollectionFromPath = fileCollectionFromPath; | ||
const fileCollectionFromPaths_1 = require("./fileCollectionFromPaths"); | ||
@@ -14,3 +14,2 @@ /** | ||
} | ||
exports.fileCollectionFromPath = fileCollectionFromPath; | ||
//# sourceMappingURL=fileCollectionFromPath.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.fileCollectionFromPaths = void 0; | ||
exports.fileCollectionFromPaths = fileCollectionFromPaths; | ||
function fileCollectionFromPaths() { | ||
throw new Error('This method is not available in the browser'); | ||
} | ||
exports.fileCollectionFromPaths = fileCollectionFromPaths; | ||
//# sourceMappingURL=fileCollectionFromPaths.browser.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.fileCollectionFromPaths = void 0; | ||
exports.fileCollectionFromPaths = fileCollectionFromPaths; | ||
const node_fs_1 = require("node:fs"); | ||
@@ -39,3 +39,2 @@ const promises_1 = require("node:fs/promises"); | ||
} | ||
exports.fileCollectionFromPaths = fileCollectionFromPaths; | ||
async function appendFiles(fileCollection, currentDir, base, options = {}) { | ||
@@ -42,0 +41,0 @@ const entries = await (0, promises_1.readdir)(currentDir); |
"use strict"; | ||
var __importDefault = (this && this.__importDefault) || function (mod) { | ||
return (mod && mod.__esModule) ? mod : { "default": mod }; | ||
}; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.fileCollectionFromWebSource = void 0; | ||
const cross_fetch_1 = __importDefault(require("cross-fetch")); | ||
exports.fileCollectionFromWebSource = fileCollectionFromWebSource; | ||
const CachedFileCollectionItem_1 = require("./CachedFileCollectionItem"); | ||
@@ -59,7 +55,7 @@ const FileCollection_1 = require("./FileCollection"); | ||
text: async () => { | ||
const response = await (0, cross_fetch_1.default)(fileURL); | ||
const response = await fetch(fileURL); | ||
return response.text(); | ||
}, | ||
arrayBuffer: async () => { | ||
const response = await (0, cross_fetch_1.default)(fileURL); | ||
const response = await fetch(fileURL); | ||
return response.arrayBuffer(); | ||
@@ -83,3 +79,2 @@ }, | ||
} | ||
exports.fileCollectionFromWebSource = fileCollectionFromWebSource; | ||
//# sourceMappingURL=fileCollectionFromWebSource.js.map |
@@ -6,3 +6,4 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.fileCollectionItemsFromZip = exports.fileCollectionFromZip = void 0; | ||
exports.fileCollectionFromZip = fileCollectionFromZip; | ||
exports.fileCollectionItemsFromZip = fileCollectionItemsFromZip; | ||
const jszip_1 = __importDefault(require("jszip")); | ||
@@ -20,3 +21,2 @@ const FileCollection_1 = require("./FileCollection"); | ||
} | ||
exports.fileCollectionFromZip = fileCollectionFromZip; | ||
async function fileCollectionItemsFromZip(zipContent, options = {}) { | ||
@@ -59,3 +59,2 @@ const jsZip = new jszip_1.default(); | ||
} | ||
exports.fileCollectionItemsFromZip = fileCollectionItemsFromZip; | ||
//# sourceMappingURL=fileCollectionFromZip.js.map |
@@ -6,3 +6,3 @@ "use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.fileCollectionToZip = void 0; | ||
exports.fileCollectionToZip = fileCollectionToZip; | ||
const jszip_1 = __importDefault(require("jszip")); | ||
@@ -21,3 +21,2 @@ /** | ||
} | ||
exports.fileCollectionToZip = fileCollectionToZip; | ||
//# sourceMappingURL=fileCollectionToZip.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.groupFiles = void 0; | ||
exports.groupFiles = groupFiles; | ||
const FileCollection_1 = require("./FileCollection"); | ||
@@ -26,3 +26,2 @@ function groupFiles(fileCollection, options = {}) { | ||
} | ||
exports.groupFiles = groupFiles; | ||
function getMeta(key, meta) { | ||
@@ -29,0 +28,0 @@ if (!meta) |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.ungzipStream = void 0; | ||
exports.ungzipStream = ungzipStream; | ||
const pako_1 = require("pako"); | ||
@@ -18,3 +18,2 @@ function ungzipStream(file) { | ||
} | ||
exports.ungzipStream = ungzipStream; | ||
//# sourceMappingURL=ungzipStream.browser.js.map |
@@ -1,4 +0,3 @@ | ||
/// <reference types="node" /> | ||
import { FileCollectionItem } from './FileCollectionItem'; | ||
export declare function ungzipStream(file: FileCollectionItem): import("stream/web").ReadableStream<any>; | ||
//# sourceMappingURL=ungzipStream.d.ts.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.ungzipStream = void 0; | ||
exports.ungzipStream = ungzipStream; | ||
const fs_1 = require("fs"); | ||
@@ -14,3 +14,2 @@ const zlib_1 = require("zlib"); | ||
} | ||
exports.ungzipStream = ungzipStream; | ||
//# sourceMappingURL=ungzipStream.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.expandAndFilter = void 0; | ||
exports.expandAndFilter = expandAndFilter; | ||
const shouldAddItem_1 = require("../shouldAddItem"); | ||
@@ -22,3 +22,2 @@ const fileCollectionItemUngzip_1 = require("./fileCollectionItemUngzip"); | ||
} | ||
exports.expandAndFilter = expandAndFilter; | ||
//# sourceMappingURL=expandAndFilter.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.fileCollectionItemUngzip = void 0; | ||
exports.fileCollectionItemUngzip = fileCollectionItemUngzip; | ||
const pako_1 = require("pako"); | ||
@@ -50,3 +50,2 @@ const ungzipStream_1 = require("../../ungzipStream"); | ||
} | ||
exports.fileCollectionItemUngzip = fileCollectionItemUngzip; | ||
async function isGzip(file) { | ||
@@ -53,0 +52,0 @@ const buffer = await file.arrayBuffer(); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.fileCollectionItemUnzip = void 0; | ||
exports.fileCollectionItemUnzip = fileCollectionItemUnzip; | ||
const fileCollectionFromZip_1 = require("../../fileCollectionFromZip"); | ||
@@ -44,3 +44,2 @@ const shouldAddItem_1 = require("../shouldAddItem"); | ||
} | ||
exports.fileCollectionItemUnzip = fileCollectionItemUnzip; | ||
function isZip(buffer) { | ||
@@ -47,0 +46,0 @@ if (buffer.byteLength < 5) |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.shouldAddItem = void 0; | ||
exports.shouldAddItem = shouldAddItem; | ||
/** | ||
@@ -18,3 +18,2 @@ * Utility function that allows to filter files from a FileCollection ignore by default the dotFiles | ||
} | ||
exports.shouldAddItem = shouldAddItem; | ||
//# sourceMappingURL=shouldAddItem.js.map |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.sortCollectionItems = void 0; | ||
exports.sortCollectionItems = sortCollectionItems; | ||
function sortCollectionItems(items) { | ||
items.sort((a, b) => a.relativePath < b.relativePath ? -1 : 1); | ||
} | ||
exports.sortCollectionItems = sortCollectionItems; | ||
//# sourceMappingURL=sortCollectionItems.js.map |
{ | ||
"name": "filelist-utils", | ||
"version": "1.11.0", | ||
"version": "1.11.1", | ||
"description": "Create a FileCollection from a path or a zip file", | ||
@@ -48,5 +48,5 @@ "main": "./lib/index.js", | ||
"devDependencies": { | ||
"@babel/plugin-transform-modules-commonjs": "^7.23.3", | ||
"@babel/preset-typescript": "^7.23.3", | ||
"@types/jest": "^29.5.11", | ||
"@babel/plugin-transform-modules-commonjs": "^7.24.8", | ||
"@babel/preset-typescript": "^7.24.7", | ||
"@types/jest": "^29.5.12", | ||
"@types/pako": "^2.0.3", | ||
@@ -56,13 +56,12 @@ "cheminfo-build": "^1.2.0", | ||
"eslint-config-cheminfo-typescript": "^12.1.0", | ||
"fifo-logger": "^0.6.1", | ||
"fifo-logger": "^1.0.0", | ||
"jest": "^29.7.0", | ||
"msw": "^2.1.2", | ||
"prettier": "^3.2.4", | ||
"rimraf": "^5.0.5", | ||
"typescript": "^5.3.3", | ||
"undici": "^6.4.0" | ||
"msw": "^2.3.1", | ||
"prettier": "^3.3.3", | ||
"rimraf": "^6.0.1", | ||
"typescript": "^5.5.3", | ||
"undici": "^6.19.2" | ||
}, | ||
"dependencies": { | ||
"cheminfo-types": "^1.7.2", | ||
"cross-fetch": "^4.0.0", | ||
"cheminfo-types": "^1.7.3", | ||
"jszip": "^3.10.1", | ||
@@ -69,0 +68,0 @@ "pako": "^2.1.0" |
@@ -1,3 +0,1 @@ | ||
import fetch from 'cross-fetch'; | ||
import { | ||
@@ -4,0 +2,0 @@ CacheOptions, |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
3
169469
2743
4
- Removedcross-fetch@^4.0.0
- Removedcross-fetch@4.0.0(transitive)
- Removednode-fetch@2.7.0(transitive)
- Removedtr46@0.0.3(transitive)
- Removedwebidl-conversions@3.0.1(transitive)
- Removedwhatwg-url@5.0.0(transitive)
Updatedcheminfo-types@^1.7.3