-
Notifications
You must be signed in to change notification settings - Fork 93
Expand file tree
/
Copy pathjustfile
More file actions
102 lines (79 loc) · 2.67 KB
/
justfile
File metadata and controls
102 lines (79 loc) · 2.67 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
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
set dotenv-load
set export
alias s := ui-serve
alias serve := ui-serve
alias chk := ui-check
alias u := ui-upgrade
alias t := translate-check
# Serve the site for dev usage
ui-serve:
bun run dev
# Build the site for production
ui-build:
bun run build
ui-format:
bun run format
# convert all the images to webp
ui-webp:
bun run webp
# install deps
i:
bun i
# check for outdated deps
ui-outdated:
bun outdated
# check for dependency updates
ui-check:
bun run taze
# upgrade deps
ui-upgrade:
bun run taze latest -u -w && just ui-clean-npm-i
# clear node_modules, bun lock file and reinstall deps
ui-clean-npm-i:
rm -rf node_modules && rm -rf bun.lockb && bun i
# Login to ECR
login:
aws --profile default configure set aws_access_key_id $AWS_ACCESS_KEY_ID
aws --profile default configure set aws_secret_access_key $AWS_SECRET_ACCESS_KEY
aws ecr get-login-password --region $DOCKER_REPO_REGION | docker login --username AWS --password-stdin $DOCKER_REPO
# Build
build:
docker build --platform linux/amd64 -t docs.rocketpool.net:latest .
# Login and deploy to ECR
login-and-deploy:
aws --profile default configure set aws_access_key_id $AWS_ACCESS_KEY_ID
aws --profile default configure set aws_secret_access_key $AWS_SECRET_ACCESS_KEY
aws ecr get-login-password --region $DOCKER_REPO_REGION | docker login --username AWS --password-stdin $DOCKER_REPO
docker build --platform linux/amd64 -t docs.rocketpool.net:latest .
docker tag docs.rocketpool.net:latest $DOCKER_REPO/docs.rocketpool.net:latest
docker push $DOCKER_REPO/docs.rocketpool.net:latest
# Build and deploy to ECR
deploy:
just ui-build
rm doc_build/.DS_Store
docker build --platform linux/amd64 -t docs.rocketpool.net:latest .
docker tag docs.rocketpool.net:latest $DOCKER_REPO/docs.rocketpool.net:latest
docker push $DOCKER_REPO/docs.rocketpool.net:latest
tag-push:
docker tag docs.rocketpool.net:latest $DOCKER_REPO/docs.rocketpool.net:latest
docker push $DOCKER_REPO/docs.rocketpool.net:latest
rmi:
docker rmi $DOCKER_REPO/docs.rocketpool.net:latest
# Check which files need translation
translate-check:
bun scripts/translate.ts check
# Translate all changed files
translate:
bun scripts/translate.ts translate
# Translate changed files for a specific locale
translate-lang locale:
bun scripts/translate.ts translate {{locale}}
# Force re-translate all files
translate-all:
bun scripts/translate.ts translate-all
# Show what would be translated (dry run)
translate-dry:
bun scripts/translate.ts dry-run
# Detect files with untranslated English content
detect-untranslated *args:
bun scripts/detect-untranslated.ts {{args}}