0.9.1 • Published 12 months ago
@filen/virtual-drive v0.9.1
Attention
The package is still a work in progress. DO NOT USE IT IN PRODUCTION YET. Class names, function names, types, definitions, constants etc. are subject to change until we release a fully tested and stable version.
Installation
- Install using NPM
npm install @filen/virtual-drive@latest
- Initialize the virtual drive
import FilenSDK from "@filen/sdk"
import VirtualDrive from "@filen/virtual-drive"
import path from "path"
import os from "os"
// Initialize a SDK instance (optional)
const filen = new FilenSDK({
metadataCache: true,
connectToSocket: true,
tmpPath: path.join(os.tmpdir(), "filen-sdk")
})
await filen.login({
email: "your@email.com",
password: "supersecret123",
twoFactorCode: "123456"
})
const virtualDrive = new VirtualDrive({
sdk: filen,
mountPoint: "X:" // or /path/to/mount on Linux/macOS
})
await virtualDrive.start()
console.log("Virtual drive started")
License
Distributed under the AGPL-3.0 License. See LICENSE for more information.