Skip to content

Commit

Permalink
refactor: reorganise into workspace
Browse files Browse the repository at this point in the history
  • Loading branch information
sciencefidelity committed Oct 5, 2024
1 parent 7f01c86 commit c92b485
Show file tree
Hide file tree
Showing 15 changed files with 111 additions and 3,401 deletions.
79 changes: 40 additions & 39 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

47 changes: 33 additions & 14 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,15 +1,28 @@
[package]
name = "eroteme"
version.workspace = true
authors.workspace = true
edition.workspace = true
description.workspace = true
readme.workspace = true
repository.workspace = true
license.workspace = true
exclude = ["./scripts"]

[workspace]
members = ["crates/handle-errors", "crates/mock-server"]
resolver = "2"

[workspace.package]
version = "1.0.0"
authors = ["Matt Cook <hello@mattcook.dev>"]
authors = ["Matt Cook <hello@mattcook.dev>"]
edition = "2021"
description = "Q&A API"
readme = "README.md"
repository = "https://github.com/sciencefidelity/eroteme"
license = "MIT or Apache-2.0"
exclude = ["./scripts"]

[lints.clippy]
[workspace.lints.clippy]
enum_glob_use = "deny"
pedantic = { level = "deny", priority = 1 }
nursery = { level = "deny", priority = 2 }
Expand All @@ -24,25 +37,31 @@ strip = "symbols"

[dependencies]
chrono = "0.4"
clap = { version = "4.5.7", features = ["derive"] }
dotenv = "0.15.0"
handle-errors = { path = "handle-errors" }
mock-server = { path ="mock-server" }
clap = { version = "4", features = ["derive"] }
dotenv = "0.15"
futures-util = "0.3"
handle-errors = { path = "crates/handle-errors" }
mock-server = { path = "crates/mock-server" }
openssl = { version = "0.10.32", features = ["vendored"] }
paseto = "2.0"
rand = "0.8.5"
paseto = "2"
rand = "0.8"
reqwest = { version = "0.12", features = ["json"] }
reqwest-middleware = "0.3"
reqwest-retry = "0.5"
rust-argon2 = "2.1"
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
sqlx = { version = "0.7", features = ["runtime-tokio", "tls-rustls", "migrate", "postgres"] }
rust-argon2 = "2"
serde = { version = "1", features = ["derive"] }
serde_json = "1"
sqlx = { version = "0.7", features = [
"runtime-tokio",
"tls-rustls",
"migrate",
"postgres",
] }
tokio = { version = "1", features = ["full"] }
tracing = { version = "0.1", features = ["log"] }
tracing-subscriber = { version = "0.3", features = ["env-filter"] }
uuid = { version = "0.8", features = ["v4"] }
warp = "0.3"

[build-dependencies]
platforms = "2.0.0"
platforms = "2"
File renamed without changes.
18 changes: 18 additions & 0 deletions crates/handle-errors/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
[package]
name = "handle-errors"
version.workspace = true
authors.workspace = true
edition.workspace = true
repository.workspace = true
license.workspace = true

[lints]
workspace = true

[dependencies]
reqwest = "0.12"
reqwest-middleware = "0.3"
rust-argon2 = "2.1"
sqlx = { version = "0.7", features = ["postgres"] }
tracing = { version = "0.1", features = ["log"] }
warp = "0.3"
File renamed without changes.
File renamed without changes.
16 changes: 16 additions & 0 deletions crates/mock-server/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
[package]
name = "mock-server"
version.workspace = true
authors.workspace = true
edition.workspace = true
repository.workspace = true
license.workspace = true

[lints]
workspace = true

[dependencies]
bytes = "1"
serde_json = "1.0"
tokio = { version = "1", features = ["full"] }
warp = "0.3"
File renamed without changes.
2 changes: 2 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,11 @@
devShells.default = mkShell {
buildInputs = [
docker-client
openssl_3_3
pkg-config
postgresql
sqlx-cli
taplo
(rust-bin.stable.latest.default.override {
extensions = [ "rust-analyzer" "rust-src" ];
})
Expand Down
28 changes: 0 additions & 28 deletions handle-errors/Cargo.toml

This file was deleted.

Loading

0 comments on commit c92b485

Please sign in to comment.