Spacedrive is an open source cross-platform file explorer, powered by a virtual distributed filesystem written in Rust.
Go to file
2022-03-31 18:20:35 -07:00
.vscode add Cargo workspace & fix Prisma 2022-03-30 16:14:50 +08:00
apps restructure project files layout 2022-03-31 17:41:17 -07:00
core fix codegen script 2022-03-31 18:20:35 -07:00
docs restructure project files layout 2022-03-31 17:41:17 -07:00
packages restructure project files layout 2022-03-31 17:41:17 -07:00
.gitignore feat: force use of pnpm 2022-03-30 18:35:57 +08:00
.prettierrc icons! 2021-12-31 03:19:09 -08:00
.rustfmt.toml add Cargo workspace & fix Prisma 2022-03-30 16:14:50 +08:00
Cargo.lock restructure project files layout 2022-03-31 17:41:17 -07:00
Cargo.toml restructure project files layout 2022-03-31 17:41:17 -07:00
LICENCE licence & client event type fix 2021-12-29 00:50:33 -08:00
package.json remove codegen'd files + update dev docs 2022-03-31 18:10:56 -07:00
pnpm-lock.yaml restructure project files layout 2022-03-31 17:41:17 -07:00
pnpm-workspace.yaml restructure project files layout 2022-03-31 17:41:17 -07:00
README.md remove codegen'd files + update dev docs 2022-03-31 18:10:56 -07:00

Logo

Spacedrive

The universal file manager.
spacedrive.app »

Download for macOS · Windows · Linux · iOS · watchOS · Android

Spacedrive is an open source cross-platform file manager, powered by a virtual distributed filesystem (VDFS) written in Rust. Learn more »

Organize files across many devices in one place. From cloud services to offline hard drives, Spacedrive combines the storage capacity and processing power of your devices into one personal distributed cloud, that is both secure and intuitive to use.

For independent creatives, hoarders and those that want to own their digital footprint. Spacedrive provides a file management experience like no other, and its completely free.

Logo

Features

NOTE: Spacedrive is under active development, most of the listed features are still experimental and subject to change.

Complete: (in testing)

  • File discovery - Scan devices, drives and cloud accounts to build a virtual, realtime updating, "yellow pages" directory of all files with metadata.
  • Preview generation - Auto generate lower resolution stand-ins for image and video.
  • Statistics - Statistics such as total capacity, index size, preview media size, free space etc.

In progress:

  • File Explorer - Browse online/offline storage locations, view files with metadata, perform basic crud.
  • Realtime synchronization - Database synchronizes in realtime between devices, prioritizing peer-to-peer LAN connections (WiFi sync).

To be developed:

  • Photos - Photo and video albums similar to Apple/Google photos, but owned by you and infinite in size.
  • Search - Search deep into your filesystem, including offline devices, with a custom keybind.
  • Cloud compatibility - Index & backup to Apple Photos, Google Drive, Dropbox, OneDrive & Mega + easy API for the community to add more.
  • Tags - Define routines on custom tags to automate workflows, easily tag files individually, in bulk and automatically via rules.
  • Encrypted vault(s) - Effortlessly manage & encrypt sensitive files, built on top of VeraCrypt. Encrypt individual files or create flexible-size vaults.
  • Key manager - View, mount, dismount and hide keys. Mounted keys automatically unlock respective areas of your filesystem.
  • Redundancy - Ensure a specific amount of copies exist for your important data, discover at-risk files and monitor device/drive health.
  • Timeline - View a linear timeline of content, travel to any time and see media represented visually.
  • Extensions - Build tools on top of Spacedrive, extend functionality and integrate third party services. Extension directory on spacedrive.app/extensions.
  • Media encoder - Encode video and audio into various formats, use Tags to automate.
  • Workers - Utilize the compute power of your devices in unison to encode and perform tasks at insane speeds.
  • Self host - Spacedrive can be deployed as a service, behaving as just another device powering your personal cloud.
  • Spacedrive Cloud - We'll host an always-on cloud device for you, with pay-as-you-go plans for storage.

Motivation

We depend on cloud services like Google Photos and iCloud, but are locked in with a limited capacity. Many of us have multiple cloud accounts, drives that arent backed up and data at risk of loss. But why be tied to any one cloud provider? Photo albums shouldnt be suck in a device ecosystem, or harvested for advertising data. It should be OS agnostic, permanent and personally owned.

Open source technology is the solution to this, Spacedrive is a universal experience to manage files, across all platforms, devices and clouds.

What is VDFS?

A VDFS (virtual distributed filesystem) is a concept first outlined in a UC Berkeley paper by Haoyuan Li. Simplified, it can be thought of to provide a single UNIX-like interface to a virtualized filesystem above a variety of storage layers. Due to being distributed in nature it has infinite expansion potential, while maintaining a consistent API. This paper describes its use for cloud computing, however the underlying concepts can be translated to open consumer software. Spacedrive is an alternate implementation

Architecture

This project is using what I'm calling the "PRRTT" stack (Prisma, Rust, React, TypeScript, Tauri).

  • Prisma on the front-end? 🤯 Made possible thanks to prisma-client-rust, developed by Brendonovich. Gives us access to the powerful migration CLI in development, along with the Prisma syntax for our schema. The application bundles with the Prisma query engine and codegen for a beautiful Rust API. Our lightweight migration runner is custom built for a desktop app context.
  • Tauri allows us to create a pure Rust native OS webview, without the overhead of your average Electron app. This brings the bundle size and average memory usage down dramatically. It also contributes to a more native feel, especially on macOS due to Safari's close integration with the OS.
  • ...

Spacedrive's core (sdcore) is written in pure Rust, using the Tauri framework to embed a React app in a native browser window for UI. The mobile app is React Native, with sdcore embedded as a native binary.

Apps

Packages

All TypeScript packages are compiled automatically using Turborepo.

  • core: the Rust core logic library, referred to internally as sdcore
  • state: the TypeScript core logic library
  • ui: a React Native / RNW component library
  • config: eslint configurations (includes eslint-config-next, eslint-config-prettier and all tsconfig.json configs used throughout the monorepo
  • macos: a Swift native binary
  • native-ios: a Swift native binary
  • native-windows: a C# native binary
  • native-android: a Kotlin native binary

Developer Installation Instructions

This environment uses Cargo and pnpm. Ensure you have them installed before continuing.

  • $ cargo install prisma-client-rust-cli
  • $ git clone https://github.com/spacedriveapp/spacedrive
  • $ cd spacedrive
  • $ pnpm i
  • $ pnpm prepare - This runs all necessary codegen.
  • $ pnpm dev - You must run this once, to build all required dependencies.

To quickly run only the desktop app after prepare you can use:

  • $ pnpm desktop dev

If you are making changes to any TS packages you must run their respective dev environments too, for example:

  • $ pnpm core dev
  • $ pnpm ui dev

Or to run everything specific to desktop app development just run:

  • $ pnpm dev

If you are having issues ensure you are using the following versions of Rust and Node:

  • Rust version: 1.58.1
  • Node version: 17