Skip to content

Commit

Permalink
update doc and deps and workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
robatipoor committed Feb 12, 2024
1 parent 817ce0a commit 9d60b45
Show file tree
Hide file tree
Showing 11 changed files with 29 additions and 13 deletions.
1 change: 1 addition & 0 deletions .env
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
APP_PROFILE=dev
RUST_BACKTRACE=1
RUST_LOG=info
# This environment variable is only used for SeaORM command line tools.
DATABASE_URL=postgres://username:password@localhost:5432/database_name
4 changes: 3 additions & 1 deletion .github/workflows/build-checker.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
name: build checker

on:
push:
branches: ["main","dev"]
branches:
- '**'

env:
CARGO_TERM_COLOR: always
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/code-linter.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
name: code linter

on:
push:
branches: ["main","dev"]
branches:
- '**'

env:
CARGO_TERM_COLOR: always
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
name: format checker
name: code style checker

on:
push:
branches: ["main","dev"]
branches:
- '**'

env:
CARGO_TERM_COLOR: always
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/security-checker.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
name: security checker

on:
push:
paths:
Expand Down
7 changes: 6 additions & 1 deletion .github/workflows/spell-checker.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
name: spell checker
on: [pull_request]

on:
push:
branches:
- '**'


env:
CARGO_TERM_COLOR: always
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
name: test

on:
push:
branches: ["main","dev"]
branches:
- '**'

env:
CARGO_TERM_COLOR: always
Expand Down
8 changes: 4 additions & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ chrono = { version = "0.4.31", default-features = false, features = [
"clock",
"serde",
] }
config = "0.13.4"
config = "0.14.0"
fake = { version = "2.9.2", features = ["derive", "uuid", "chrono"] }
futures = "0.3.30"
itertools = "0.12.0"
Expand Down Expand Up @@ -75,6 +75,6 @@ utoipa = { version = "4.2.0", features = ["axum_extras", "uuid", "chrono"] }
utoipa-swagger-ui = { version = "6.0.0", features = ["axum"] }
uuid = { version = "1.6.1", features = ["v4", "serde"] }
tokio-tungstenite = "0.21.0"
wiremock = "0.5.22"
garde = "0.17.0"
regex = "1.10.2"
garde = { version = "0.18.0", features = ["full"] }
regex = "1.10.3"
wiremock = "0.6.0"
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,9 @@ export APP_SERVER__PORT=8080
export APP_SERVER__ADDR=127.0.0.1
```
#### Switching profiles
Before running the application, export this variable:
```bash
export APP_PROFILE=prod # switch to production profile
export APP_PROFILE=prod # Switch to production profile
```
### Check code formatting and typo at commit time
```
Expand Down
2 changes: 1 addition & 1 deletion run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@
./scripts/init_redis.sh
./scripts/init_mailhog.sh
./scripts/init_mockserver.sh
export APP_PROFILE=dev
export $(cat .env | xargs)
cargo run --bin app
2 changes: 1 addition & 1 deletion src/entity/role.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,4 @@ pub enum RoleUser {
User,
#[sea_orm(string_value = "System")]
System,
}
}

0 comments on commit 9d60b45

Please sign in to comment.