Refactor repo into a non-virtual cargo workspace with a root package.

The old way of using a virtual workspace is incorrect for an application like this.
It also prevents existing bundle tools (cargo-bundle) from working with Moxin because they all expect a root package to be defined.

Technically we don't even need a workspace at all for this repo, but I left it in just for the sake of posterity.
This commit is contained in:
Kevin Boos 2024-06-05 12:51:34 -07:00
parent 547ad1bec6
commit a07e4cc686
90 changed files with 56 additions and 55 deletions

36
Cargo.lock generated
View File

@ -1185,6 +1185,24 @@ dependencies = [
"windows-sys 0.48.0",
]
[[package]]
name = "moxin"
version = "0.1.0"
dependencies = [
"anyhow",
"chrono",
"lipsum",
"makepad-widgets",
"moxin-backend",
"moxin-fake-backend",
"moxin-protocol",
"rand",
"robius-open",
"serde",
"serde_json",
"unicode-segmentation",
]
[[package]]
name = "moxin-backend"
version = "0.1.0"
@ -1212,24 +1230,6 @@ dependencies = [
"moxin-protocol",
]
[[package]]
name = "moxin-frontend"
version = "0.1.0"
dependencies = [
"anyhow",
"chrono",
"lipsum",
"makepad-widgets",
"moxin-backend",
"moxin-fake-backend",
"moxin-protocol",
"rand",
"robius-open",
"serde",
"serde_json",
"unicode-segmentation",
]
[[package]]
name = "moxin-protocol"
version = "0.1.0"

View File

@ -1,10 +1,30 @@
[workspace]
members = [
"moxin-backend",
"moxin-frontend",
"moxin-protocol"
]
resolver = "2"
members = [
"moxin-protocol",
"moxin-backend",
"moxin-fake-backend",
]
[package]
name = "moxin"
version = "0.1.0"
edition = "2021"
[dependencies]
moxin-protocol = { path = "moxin-protocol" }
moxin-backend = { path = "moxin-backend" }
moxin-fake-backend = { path = "moxin-fake-backend" }
makepad-widgets = { git = "https://github.com/makepad/makepad", branch = "rik" }
robius-open = { git = "https://github.com/project-robius/robius-open", rev = "b901523667d4a8bbb0bba3cd1ebcc0b94d33534e" }
chrono = "0.4"
unicode-segmentation = "1.10.1"
anyhow = "1.0"
serde_json = "1.0"
serde = { version = "1.0.197", features = ["derive"] }
lipsum = "0.9"
rand = "0.8.5"

View File

@ -22,12 +22,17 @@ curl -sSf https://raw.githubusercontent.com/WasmEdge/WasmEdge/master/utils/insta
source $HOME/.wasmedge/env
```
Obtain the source code from this repository:
```sh
git clone https://github.com/moxin-org/moxin.git
```
### macOS
Then, on a standard desktop platform (macOS), simply run:
```sh
cd ~/moxin
cd moxin
cargo run
```
@ -50,6 +55,6 @@ sudo apt-get install libxcursor-dev libx11-dev libasound2-dev libpulse-dev
Then, run:
```sh
cd ~/moxin
cd moxin
cargo run
```

View File

@ -6,5 +6,5 @@ edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
moxin-protocol = { path = "../../moxin-protocol" }
moxin-protocol = { path = "../moxin-protocol" }
chrono = "0.4"

View File

@ -1,24 +0,0 @@
[package]
name = "moxin-frontend"
version = "0.1.0"
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[dependencies]
moxin-protocol = { path = "../moxin-protocol" }
moxin-backend = { path = "../moxin-backend" }
moxin-fake-backend = { path = "./moxin-fake-backend", package="moxin-fake-backend" }
makepad-widgets = { git = "https://github.com/makepad/makepad", branch = "rik" }
robius-open = { git = "https://github.com/project-robius/robius-open", rev = "b901523667d4a8bbb0bba3cd1ebcc0b94d33534e" }
chrono = "0.4"
unicode-segmentation = "1.10.1"
anyhow = "1.0"
serde_json = "1.0"
serde = { version = "1.0.197", features = ["derive"] }
lipsum = "0.9"
rand = "0.8.5"

View File

@ -1,3 +0,0 @@
fn main() {
moxin_frontend::app::app_main()
}

View File

Before

Width:  |  Height:  |  Size: 376 B

After

Width:  |  Height:  |  Size: 376 B

View File

Before

Width:  |  Height:  |  Size: 576 B

After

Width:  |  Height:  |  Size: 576 B

View File

Before

Width:  |  Height:  |  Size: 2.3 KiB

After

Width:  |  Height:  |  Size: 2.3 KiB

View File

Before

Width:  |  Height:  |  Size: 219 B

After

Width:  |  Height:  |  Size: 219 B

View File

Before

Width:  |  Height:  |  Size: 577 B

After

Width:  |  Height:  |  Size: 577 B

View File

Before

Width:  |  Height:  |  Size: 902 B

After

Width:  |  Height:  |  Size: 902 B

View File

Before

Width:  |  Height:  |  Size: 740 B

After

Width:  |  Height:  |  Size: 740 B

View File

Before

Width:  |  Height:  |  Size: 2.3 KiB

After

Width:  |  Height:  |  Size: 2.3 KiB

View File

Before

Width:  |  Height:  |  Size: 698 B

After

Width:  |  Height:  |  Size: 698 B

View File

Before

Width:  |  Height:  |  Size: 474 B

After

Width:  |  Height:  |  Size: 474 B

View File

Before

Width:  |  Height:  |  Size: 530 B

After

Width:  |  Height:  |  Size: 530 B

View File

Before

Width:  |  Height:  |  Size: 872 B

After

Width:  |  Height:  |  Size: 872 B

View File

Before

Width:  |  Height:  |  Size: 2.1 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB

View File

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

View File

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 1.9 KiB

View File

Before

Width:  |  Height:  |  Size: 729 B

After

Width:  |  Height:  |  Size: 729 B

View File

Before

Width:  |  Height:  |  Size: 2.1 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB

View File

Before

Width:  |  Height:  |  Size: 174 B

After

Width:  |  Height:  |  Size: 174 B

View File

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

View File

Before

Width:  |  Height:  |  Size: 279 B

After

Width:  |  Height:  |  Size: 279 B

View File

Before

Width:  |  Height:  |  Size: 778 B

After

Width:  |  Height:  |  Size: 778 B

View File

Before

Width:  |  Height:  |  Size: 336 B

After

Width:  |  Height:  |  Size: 336 B

View File

Before

Width:  |  Height:  |  Size: 266 B

After

Width:  |  Height:  |  Size: 266 B

View File

Before

Width:  |  Height:  |  Size: 352 B

After

Width:  |  Height:  |  Size: 352 B

View File

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 1.4 KiB

View File

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

View File

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

View File

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 1.2 KiB

View File

Before

Width:  |  Height:  |  Size: 2.0 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

View File

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

View File

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 1.6 KiB

View File

Before

Width:  |  Height:  |  Size: 1.3 MiB

After

Width:  |  Height:  |  Size: 1.3 MiB

View File

Before

Width:  |  Height:  |  Size: 1.7 KiB

After

Width:  |  Height:  |  Size: 1.7 KiB

3
src/main.rs Normal file
View File

@ -0,0 +1,3 @@
fn main() {
moxin::app::app_main()
}