Files
spacedrive/.github/scripts/setup-system.sh
Utku 8a79b07293 Mobile app (#352)
* Mobile app: Initial Commit!

* Fix monorepo issues and add tailwind.

Fix & Test tailwind.

working ball app

Fix workspace module import

* Mobile app cleanup and structure

* App Icons, Splash screen and eslint config

* More cleanup

* Use SVGs directly in React Native

* Add placeholder files for project structrate

* Cleanup all svg icons and modify metro config to use icons from interface package (temporary)

* Potentially fix types for react & update some packages.

* Onboarding screen + add reanimated & moti

* Finishing touches on Onboarding screen

* Persist onboarding, Button comp and Nav. flow.

* Add mobile info to Contributing.md

* Add .prettierignore for disabling auto import ordering for some files.

* Introducing the new navigation flow

* Change package name

* use the new @sd/assets package

* Add a temp. folder for @sd/assets organization

* Drawer nav bar looks good now.

* Hacky method to get the active route on drawer

* Fix react native types & update few packages.

* Drawer animation

* Add counter

* Collapsible Tags / Locations

* rename Counter and add saveState prop

* Sync counter with desktop version

* Move some screens to BottomTab Nav.

* Add Overview Stats

* [WIP] - Device component

* Upgrade to Expo 46 and fix types.

* Add @sd/core to mobile

* Fix eslint stuff

* placeholder and some notes

* Show folder icons on overview screen

* Fixed android build, style and some screen tweaks

* Add bottom sheet package

* Fix bundler issues and rename landing package.json

* Rename landing package.json

* update all packages to latest React

* Eject expo app

* fix pnpm & expo & monorepo

* monorepo debugging

* cleanup dependencies & static link to shared packages

* cleanup, switch to hermes, pollyfill intl for ios

* Cleanup monorepo

* Fix: Style for FileItem

* Above average app icons

* cleanup ios

* update msrv

* update codeowners for mobile

* fix typecheck

* update lockfile

* fix ffmpeg install

* rename UI to 'SpacedriveInterface' for clarity

* Update codeowners

* Fix eslint config mobile.

* Refactor navigation flow, move types to navigators

Co-authored-by: Utku <74243531+utkubkr@users.noreply.github.com>
Co-authored-by: Oscar Beaumont <oscar@otbeaumont.me>
Co-authored-by: Brendan Allan <brendonovich@outlook.com>
2022-08-08 20:29:14 -07:00

74 lines
3.8 KiB
Bash
Executable File

#!/bin/bash
set -e
echo "Setting up your system for Spacedrive development!"
which cargo &> /dev/null
if [ $? -eq 1 ]; then
echo "Rust was not detected on your system. Ensure the 'rustc' and 'cargo' binaries are in your \$PATH."
exit 1
fi
if [ "${SPACEDRIVE_SKIP_PNPM_CHECK:-}" != "true" ]; then
which pnpm &> /dev/null
if [ $? -eq 1 ]; then
echo "PNPM was not detected on your system. Ensure the 'pnpm' command is in your \$PATH. You are not able to use Yarn or NPM."
exit 1
fi
else
echo "Skipped PNPM check!"
fi
if [[ "$OSTYPE" == "linux-gnu"* ]]; then
if which apt-get &> /dev/null; then
echo "Detected 'apt' based distro!"
if [[ "$(lsb_release -si)" == "Pop" ]]; then
DEBIAN_FFMPEG_DEPS="libavcodec-dev libavdevice-dev libavfilter-dev libavformat-dev libavutil-dev libswscale-dev libswresample-dev ffmpeg" # FFMPEG dependencies
else
DEBIAN_FFMPEG_DEPS="libavcodec-dev libavdevice-dev libavfilter-dev libavformat-dev libavresample-dev libavutil-dev libswscale-dev libswresample-dev ffmpeg" # FFMPEG dependencies
fi
DEBIAN_TAURI_DEPS="libwebkit2gtk-4.0-dev build-essential curl wget libssl-dev libgtk-3-dev libappindicator3-dev librsvg2-dev" # Tauri dependencies
DEBIAN_BINDGEN_DEPS="pkg-config clang" # Bindgen dependencies - it's used by a dependency of Spacedrive
sudo apt-get -y update
sudo apt-get -y install ${SPACEDRIVE_CUSTOM_APT_FLAGS:-} $DEBIAN_TAURI_DEPS $DEBIAN_FFMPEG_DEPS $DEBIAN_BINDGEN_DEPS
elif which pacman &> /dev/null; then
echo "Detected 'pacman' based distro!"
ARCH_TAURI_DEPS="webkit2gtk base-devel curl wget openssl appmenu-gtk-module gtk3 libappindicator-gtk3 librsvg libvips" # Tauri deps https://tauri.studio/guides/getting-started/setup/linux#1-system-dependencies
ARCH_FFMPEG_DEPS="ffmpeg" # FFMPEG dependencies
ARCH_BINDGEN_DEPS="clang" # Bindgen dependencies - it's used by a dependency of Spacedrive
sudo pacman -Syu
sudo pacman -S --needed $ARCH_TAURI_DEPS $ARCH_FFMPEG_DEPS $ARCH_BINDGEN_DEPS
elif which dnf &> /dev/null; then
echo "Detected 'dnf' based distro!"
FEDORA_TAURI_DEPS="webkit2gtk3-devel.x86_64 openssl-devel curl wget libappindicator-gtk3 librsvg2-devel" # Tauri dependencies
FEDORA_FFMPEG_DEPS="ffmpeg ffmpeg-devel" # FFMPEG dependencies
FEDORA_BINDGEN_DEPS="clang" # Bindgen dependencies - it's used by a dependency of Spacedrive
sudo dnf check-update
sudo dnf install $FEDORA_TAURI_DEPS $FEDORA_FFMPEG_DEPS $FEDORA_BINDGEN_DEPS
sudo dnf group install "C Development Tools and Libraries"
else
echo "Your Linux distro '$(lsb_release -s -d)' is not supported by this script. We would welcome a PR or some help adding your OS to this script. https://github.com/spacedriveapp/spacedrive/issues"
exit 1
fi
echo "Your machine has been setup for Spacedrive development!"
elif [[ "$OSTYPE" == "darwin"* ]]; then
if ! brew tap | grep spacedriveapp/deps > /dev/null; then
brew tap-new spacedriveapp/deps > /dev/null
fi
brew extract --force --version 5.0.1 ffmpeg spacedriveapp/deps > /dev/null
brew unlink ffmpeg &> /dev/null || true
brew install spacedriveapp/deps/ffmpeg@5.0.1 &> /dev/null
echo "ffmpeg v5.0.1 has been installed and is now being used on your system."
else
echo "Your OS '$OSTYPE' is not supported by this script. We would welcome a PR or some help adding your OS to this script. https://github.com/spacedriveapp/spacedrive/issues"
exit 1
fi