Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(GUI): Tauri / Svelte migration #39

Draft
wants to merge 8 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
138 changes: 69 additions & 69 deletions .github/workflows/build_and_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ env:

jobs:
release_cli:
if: github.event.pull_request.head.ref !~ 'dependabot/.*'
if: "!startsWith(github.event.pull_request.head.ref, 'dependabot')"
strategy:
matrix:
platform:
Expand Down Expand Up @@ -80,7 +80,7 @@ jobs:
# TODO: Change author to houseabsolute if/when PR https://github.com/houseabsolute/actions-rust-release/pull/2
# is merged. Don't forget below one too
- name: Publish artifacts and release
uses: houseabsolute/actions-rust-release@v3
uses: houseabsolute/actions-rust-release@v0
with:
working-directory: .
executable-name: ${{ matrix.platform.cli_bin_no_ext || matrix.platform.cli_bin }}
Expand All @@ -91,75 +91,75 @@ jobs:
README.md
Justfile

release_gui:
if: github.event.pull_request.head.ref !~ 'dependabot/.*'
# Copy of the above strategy
strategy:
matrix:
platform:
- target: x86_64-unknown-linux-gnu
cli_bin: rustbee
gui_bin: rustbee-gui
daemon_bin: rustbee-daemon
os_name: Linux-x86_64
os: ubuntu-latest
- target: x86_64-pc-windows-gnu
cli_bin: rustbee.exe
cli_bin_no_ext: rustbee
gui_bin: rustbee-gui.exe
gui_bin_no_ext: rustbee-gui
daemon_bin: rustbee-daemon.exe
os_name: Windows-x86_64
os: windows-latest

runs-on: ${{ matrix.platform.os }}

steps:
- uses: actions/checkout@v4
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
target: ${{ matrix.platform.target }}
override: true

- name: Cache cargo & target directories
uses: Swatinem/rust-cache@v2

- name: Install dependencies
if: ${{ matrix.platform.os == 'ubuntu-latest' }}
run: |
sudo apt install libdbus-1-dev pkg-config

- name: Build GUI
uses: houseabsolute/actions-rust-cross@v0
with:
working-directory: ./rustbee-gui
command: build
target: ${{ matrix.platform.target }}
args: "--locked --release"

- name: Build Daemon
uses: houseabsolute/actions-rust-cross@v0
with:
working-directory: ./rustbee-daemon
command: build
target: ${{ matrix.platform.target }}
args: "--locked --release"

- name: Publish artifacts and release
uses: houseabsolute/actions-rust-release@v3
with:
working-directory: ./rustbee-gui
executable-name: ${{ matrix.platform.gui_bin_no_ext || matrix.platform.gui_bin }}
changes-file: ../CHANGELOG.md
target: ${{ matrix.platform.target }}
extra-files: |
../rustbee-daemon/target/${{ matrix.platform.target }}/release/${{ matrix.platform.daemon_bin }}
../README.md
../Justfile
# release_gui:
# if: "!startsWith(github.event.pull_request.head.ref, 'dependabot')"
# # Copy of the above strategy
# strategy:
# matrix:
# platform:
# - target: x86_64-unknown-linux-gnu
# cli_bin: rustbee
# gui_bin: rustbee-gui
# daemon_bin: rustbee-daemon
# os_name: Linux-x86_64
# os: ubuntu-latest
# - target: x86_64-pc-windows-gnu
# cli_bin: rustbee.exe
# cli_bin_no_ext: rustbee
# gui_bin: rustbee-gui.exe
# gui_bin_no_ext: rustbee-gui
# daemon_bin: rustbee-daemon.exe
# os_name: Windows-x86_64
# os: windows-latest
#
# runs-on: ${{ matrix.platform.os }}
#
# steps:
# - uses: actions/checkout@v4
# - uses: actions-rs/toolchain@v1
# with:
# toolchain: stable
# target: ${{ matrix.platform.target }}
# override: true
#
# - name: Cache cargo & target directories
# uses: Swatinem/rust-cache@v2
#
# - name: Install dependencies
# if: ${{ matrix.platform.os == 'ubuntu-latest' }}
# run: |
# sudo apt install libdbus-1-dev pkg-config
#
# - name: Build GUI
# uses: houseabsolute/actions-rust-cross@v0
# with:
# working-directory: ./rustbee-gui
# command: build
# target: ${{ matrix.platform.target }}
# args: "--locked --release"
#
# - name: Build Daemon
# uses: houseabsolute/actions-rust-cross@v0
# with:
# working-directory: ./rustbee-daemon
# command: build
# target: ${{ matrix.platform.target }}
# args: "--locked --release"
#
# - name: Publish artifacts and release
# uses: houseabsolute/actions-rust-release@v0
# with:
# working-directory: ./rustbee-gui
# executable-name: ${{ matrix.platform.gui_bin_no_ext || matrix.platform.gui_bin }}
# changes-file: ../CHANGELOG.md
# target: ${{ matrix.platform.target }}
# extra-files: |
# ../rustbee-daemon/target/${{ matrix.platform.target }}/release/${{ matrix.platform.daemon_bin }}
# ../README.md
# ../Justfile

release_c_lib:
if: github.event.pull_request.head.ref !~ 'dependabot/.*'
if: "!startsWith(github.event.pull_request.head.ref, 'dependabot')"
# Copy of the above strategy
strategy:
matrix:
Expand Down
20 changes: 18 additions & 2 deletions .github/workflows/clippy_lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
- path: .
- path: ./rustbee-common
- path: ./rustbee-daemon
- path: ./rustbee-gui
- path: ./rustbee-gui/src-tauri

runs-on: ubuntu-latest

Expand All @@ -38,7 +38,23 @@ jobs:

- name: Install dependencies
run: |
sudo apt install libdbus-1-dev pkg-config
sudo apt update
sudo apt install -y libdbus-1-dev pkg-config

- name: Install dependencies for Tauri
if: matrix.directories.path == './rustbee-gui/src-tauri'
run: |
sudo apt install -y \
libglib2.0-dev \
libwebkit2gtk-4.1-dev \
build-essential \
curl \
wget \
file \
libxdo-dev \
libssl-dev \
libayatana-appindicator3-dev \
librsvg2-dev

- name: Lint and Check every Rust dir with Clippy
working-directory: ${{ matrix.directories.path }}
Expand Down
19 changes: 19 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,21 @@
target/
*.log
.zig-cache/
zig-out/

# GUI
.DS_Store
node_modules/
build/
.svelte-kit/
package/
.env
.env.*
!.env.example
vite.config.js.timestamp-*
vite.config.ts.timestamp-*
.pnpm-store/

# Generated by Tauri
# will have schema files for capabilities auto-completion
gen/schemas/
2 changes: 2 additions & 0 deletions .ignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
.git/
target/
.pnpm-store/
.zig-cache/
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,11 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/)

## [Unreleased]

### Changed

- [lib] Breaking changes:
- - set_colors is now taking responsability of the bit scaling, it will only require `x` and `y` as `f32`

## [v0.1.0] - 2024-11-18

### Changed
Expand Down
Loading
Loading