mirror of
https://github.com/spacedriveapp/spacedrive.git
synced 2026-04-23 07:59:59 -04:00
* Introducing location online/offline checks and location relink * Some initial drafts for location watchers * Location metadata relink and add library * Many improvements at job system Now using prisma batching at identifier job Removing blocking I/O from extension subcrate Implementing lazy generation of thumbnails New current directory identifier job to be used on light rescans * Some optimizations on identifier and object validator jobs * merge jamie's identifier PR * fully repaired identifier job * properly hooked up object kind * inspector fix * fix video badge * small improvements to libraries settings * identifier and inspector improvements * fix feature flags and hook up context menu location utilities * BETTER CONTEXT MENU x100 * test-files * style tweaks * new icon designs * manifest * fix thumbnails on web * media data * New Location Watcher and some minor fixes * disable broken media_data extractor, wip * wip * function name fix * Fixing pnpm prep and some warnings * Solving a race condition beetween indexer job and FS event handlerSome other minor warnings * Generating thumbnails on watcher * Remove event handler on watcher * Some initial works on modify events and other small fixes * File update event * Trying to be more generic with used events and some tests to validate our assumptions * Turning on location metadata file * Introducing core unit tests on CI pipeline * Submiting new unit test assumptions to validate on windows CI * Fixing unit tests * Fixing unit tests again * Fixing unit tests * Fixing unit tests for macos * Fixing unit tests for macos again * New structure for platform dependent event handling Implementing event handlers for Linux and MacOS * minor fixes + rustfmt + clippy * Windows event handling * Introducing a feature gate to only use location watching on desktop app for now * Putting more stuff behind feature gates to avoid warnings * Adding feature to cargo test on CI * Changing some debug logs to trace logs and removing Jamie specific stuff * Make location removal from manager less async * fix build when "location-watcher" feature disabled * fix types + clippy * make location manager non-static * remove uses of `to_string_lossy` * more invalidate_query calls * Expose `library_ctx` directly to avoid needless clones * New materialized_path handling for directories * Removing cascade delete between file_path and object - Some other minor stuff * remove unused `CurrentDirFileIdentifierJob` Co-authored-by: Jamie Pine <ijamespine@me.com> Co-authored-by: Oscar Beaumont <oscar@otbeaumont.me>
176 lines
4.3 KiB
YAML
176 lines
4.3 KiB
YAML
name: CI
|
|
|
|
on:
|
|
pull_request:
|
|
push:
|
|
branches:
|
|
- main
|
|
paths-ignore:
|
|
- '**/.md'
|
|
workflow_dispatch:
|
|
|
|
env:
|
|
SPACEDRIVE_CUSTOM_APT_FLAGS: --no-install-recommends
|
|
|
|
jobs:
|
|
typescript:
|
|
name: TypeScript
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Install pnpm
|
|
uses: pnpm/action-setup@v2.2.2
|
|
with:
|
|
version: 7.x.x
|
|
|
|
- name: Install Node.js
|
|
uses: actions/setup-node@v3
|
|
with:
|
|
node-version: 18
|
|
cache: 'pnpm'
|
|
|
|
- name: Install pnpm dependencies
|
|
run: pnpm i --frozen-lockfile
|
|
|
|
- name: Perform typechecks
|
|
run: pnpm typecheck
|
|
|
|
rustfmt:
|
|
name: rustfmt
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v2
|
|
|
|
- name: Install Rust
|
|
uses: actions-rs/toolchain@v1
|
|
with:
|
|
toolchain: stable
|
|
components: rustfmt
|
|
|
|
- name: Cache Rust dependencies
|
|
uses: ./.github/actions/cache-rust-deps
|
|
|
|
- name: Generate Prisma client
|
|
uses: ./.github/actions/generate-prisma-client
|
|
|
|
- name: Run rustfmt
|
|
run: cargo fmt --all -- --check
|
|
|
|
clippy_check:
|
|
name: Clippy
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v2
|
|
|
|
- name: Install Rust
|
|
uses: actions-rs/toolchain@v1
|
|
with:
|
|
toolchain: stable
|
|
profile: minimal
|
|
override: true
|
|
components: clippy
|
|
|
|
- name: Cache Rust dependencies
|
|
uses: ./.github/actions/cache-rust-deps
|
|
|
|
- name: Install Node.js
|
|
uses: actions/setup-node@v3
|
|
with:
|
|
node-version: 18
|
|
|
|
- name: Install pnpm
|
|
uses: pnpm/action-setup@v2.0.1
|
|
with:
|
|
version: 7
|
|
run_install: false
|
|
|
|
- name: Run 'setup-system.sh' script
|
|
run: ./.github/scripts/setup-system.sh
|
|
|
|
- name: Generate Prisma client
|
|
uses: ./.github/actions/generate-prisma-client
|
|
|
|
- name: Run Clippy
|
|
uses: actions-rs/clippy-check@v1
|
|
with:
|
|
token: ${{ secrets.GITHUB_TOKEN }}
|
|
args: --all-features --release
|
|
|
|
build-and-publish:
|
|
name: Build and Publish (${{ matrix.platform }})
|
|
runs-on: ${{ matrix.platform }}
|
|
strategy:
|
|
fail-fast: true
|
|
matrix:
|
|
platform: [ubuntu-latest, macos-latest, windows-latest]
|
|
steps:
|
|
- name: Log in to the Container registry
|
|
if: matrix.platform == 'ubuntu-latest' && github.event_name != 'pull_request'
|
|
uses: docker/login-action@v1
|
|
with:
|
|
registry: ghcr.io
|
|
username: ${{ github.repository_owner }}
|
|
password: ${{ secrets.GITHUB_TOKEN }}
|
|
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Install Rust stable
|
|
uses: actions-rs/toolchain@v1
|
|
with:
|
|
toolchain: stable
|
|
profile: minimal
|
|
override: true
|
|
components: rustfmt, rust-src
|
|
|
|
- name: Cache Rust dependencies
|
|
uses: ./.github/actions/cache-rust-deps
|
|
|
|
- name: Install pnpm
|
|
uses: pnpm/action-setup@v2.2.2
|
|
with:
|
|
version: 7.x.x
|
|
|
|
- name: Install Node.js
|
|
uses: actions/setup-node@v3
|
|
with:
|
|
node-version: 18
|
|
cache: 'pnpm'
|
|
|
|
- name: Install pnpm dependencies
|
|
run: pnpm i --frozen-lockfile
|
|
|
|
- name: Run 'setup-system.sh' script
|
|
if: matrix.platform == 'ubuntu-latest' || matrix.platform == 'macos-latest'
|
|
run: ./.github/scripts/setup-system.sh
|
|
|
|
- name: Run 'setup-system.ps1' script
|
|
if: matrix.platform == 'windows-latest'
|
|
run: ./.github/scripts/setup-system.ps1 -ci
|
|
|
|
- name: Generate Prisma client
|
|
uses: ./.github/actions/generate-prisma-client
|
|
|
|
- name: Cargo fetch
|
|
run: cargo fetch
|
|
|
|
- name: Cargo test core
|
|
run: cargo test -p sd-core -F location-watcher
|
|
|
|
- name: Check core
|
|
run: cargo check -p sd-core --release
|
|
|
|
- name: Bundle Desktop
|
|
run: pnpm desktop tauri build
|
|
|
|
- name: Publish server Docker image
|
|
if: matrix.platform == 'ubuntu-latest' && github.event_name != 'pull_request'
|
|
uses: ./.github/actions/publish-server-image
|
|
|
|
- name: Publish artifacts
|
|
uses: ./.github/actions/publish-artifacts
|