-
Notifications
You must be signed in to change notification settings - Fork 44
/
justfile
32 lines (24 loc) · 1020 Bytes
/
justfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
examples := 'applet application calendar config context-menu cosmic image-button menu multi-window nav-context open-dialog'
clippy_args := '-W clippy::all -W clippy::pedantic'
# Check for errors and linter warnings
check *args: (check-wayland args) (check-winit args) (check-examples args)
check-examples *args:
#!/bin/bash
for project in {{examples}}; do
cargo clippy -p ${project} {{args}} -- {{clippy_args}}
done
check-wayland *args:
cargo clippy --no-deps --features="wayland,tokio,xdg-portal" {{args}} -- {{clippy_args}}
check-winit *args:
cargo clippy --no-deps --features="winit,tokio,xdg-portal" {{args}} -- {{clippy_args}}
# Runs a check with JSON message format for IDE integration
check-json: (check '--message-format=json')
# Remove Cargo build artifacts
clean:
cargo clean
# Also remove .cargo and vendored dependencies
clean-dist: clean
rm -rf .cargo vendor vendor.tar target
# Runs an example of the given {{name}}
run name:
cargo run --release -p {{name}}