-
-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathjustfile
More file actions
82 lines (63 loc) · 1.84 KB
/
Copy pathjustfile
File metadata and controls
82 lines (63 loc) · 1.84 KB
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
# Justfile for Glyphana
# Default recipe
default:
@just --list
# Build the project in release mode
build:
cargo build --release
# Run the application
run:
cargo run
# Run tests
test:
cargo test
# Format code
fmt:
cargo fmt
# Run clippy
lint:
cargo clippy --fix --allow-dirty
# Clean build artifacts
clean:
cargo clean
# Package for the current platform using cargo-packager
package:
#!/usr/bin/env sh
set -e
echo "Building packages using cargo-packager..."
# Install cargo-packager if not installed
if ! command -v cargo-packager &> /dev/null; then
echo "Installing cargo-packager..."
cargo install cargo-packager --locked
fi
# Run cargo-packager (it will detect the current platform automatically)
cargo packager --release
echo "Packages created successfully!"
echo "Output location: dist/"
# Show created packages
if [ -d "dist" ]; then
echo "Created packages:"
ls -la dist/
else
echo "Warning: dist directory not found"
fi
# Install packaging tools
install-packager:
cargo install cargo-packager --locked
# Package with verbose output for debugging
package-verbose:
cargo packager --release --verbose
# Package only specific formats (e.g., just package-deb, package-dmg, package-msi)
package-deb:
cargo packager --release --formats deb
package-dmg:
cargo packager --release --formats dmg
package-msi:
cargo packager --release --formats msi
package-appimage:
cargo packager --release --formats appimage
# Create source distribution
dist:
@echo "Creating source distribution..."
git archive --format=tar.gz --prefix=glyphana-$(shell cargo pkgid | cut -d# -f2)/ HEAD > glyphana-$(shell cargo pkgid | cut -d# -f2).tar.gz
@echo "Source distribution created: glyphana-$(shell cargo pkgid | cut -d# -f2).tar.gz"