-
Notifications
You must be signed in to change notification settings - Fork 22
Expand file tree
/
Copy pathTaskfile.yaml
More file actions
140 lines (124 loc) · 3.7 KB
/
Taskfile.yaml
File metadata and controls
140 lines (124 loc) · 3.7 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
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
version: '3'
vars:
PLUGINS_DIR: "../plugins"
ADAPTERS_DIR: "../adapters"
PULL_JOBS: 30
PNPM_JOBS: 10
PLUGINS:
- "adminforth-audit-log"
- "adminforth-email-password-reset"
- "adminforth-foreign-inline-list"
- "adminforth-i18n"
- "adminforth-import-export"
- "adminforth-text-complete"
- "adminforth-open-signup"
- "adminforth-rich-editor"
- "adminforth-two-factors-auth"
- "adminforth-upload"
- "adminforth-oauth"
- "adminforth-list-in-place-edit"
- "adminforth-inline-create"
- "adminforth-markdown"
- "adminforth-foreign-inline-show"
- "adminforth-email-invite"
- "adminforth-bulk-ai-flow"
- "adminforth-universal-search"
- "adminforth-login-captcha"
- "adminforth-user-soft-delete"
- "adminforth-clone-row"
- "adminforth-quick-filters"
- "adminforth-many2many"
- "adminforth-background-jobs"
- "adminforth-auto-remove"
ADAPTERS:
- "adminforth-completion-adapter-open-ai-chat-gpt"
- "adminforth-email-adapter-aws-ses"
- "adminforth-email-adapter-mailgun"
- "adminforth-oauth-adapter-google"
- "adminforth-oauth-adapter-github"
- "adminforth-oauth-adapter-facebook"
- "adminforth-oauth-adapter-keycloak"
- "adminforth-oauth-adapter-microsoft"
- "adminforth-oauth-adapter-twitch"
- "adminforth-image-generation-adapter-openai"
- "adminforth-storage-adapter-amazon-s3"
- "adminforth-storage-adapter-local"
- "adminforth-image-vision-adapter-openai"
- "adminforth-key-value-adapter-ram"
- "adminforth-login-captcha-adapter-cloudflare"
- "adminforth-login-captcha-adapter-recaptcha"
- "adminforth-completion-adapter-google-gemini"
- "adminforth-key-value-adapter-redis"
- "adminforth-key-value-adapter-leveldb"
- "adminforth-image-generation-adapter-nano-banana"
tasks:
pull_repos:
internal: true
cmds:
- |
set -euo pipefail
mkdir -p "{{.DIR}}"
cd "{{.DIR}}"
repos=({{range .REPOS}}{{.}} {{end}})
printf '%s\n' "${repos[@]}" | xargs -n1 -P"{{.PULL_JOBS}}" -I{} bash -c '
set -euo pipefail
repo="$1"
repo_url="https://github.com/devforth/${repo}.git"
name="$(basename "${repo}" .git)"
if [ -d "${name}" ]; then
echo "Pulling ${name}"
(cd "${name}" && git pull || echo "Failed to pull ${name}")
else
echo "Cloning ${name}"
git clone "${repo_url}" "${name}"
fi
' _ {}
pnpm_repos:
internal: true
cmds:
- |
set -euo pipefail
cd "{{.DIR}}"
repos=({{range .REPOS}}{{.}} {{end}})
printf '%s\n' "${repos[@]}" | xargs -n1 -P"{{.PNPM_JOBS}}" -I{} bash -c '
set -euo pipefail
name="$1"
if [ -d "${name}" ]; then
echo "Installing dependencies for ${name}"
(cd "${name}" && pnpm install)
else
echo "Directory ${name} does not exist, skipping"
fi
' _ {}
pull_plugins:
desc: Pull plugin repositories
cmds:
- task: pull_repos
vars:
DIR: "{{.PLUGINS_DIR}}"
REPOS:
ref: .PLUGINS
pull_adapters:
desc: Pull adapter repositories
cmds:
- task: pull_repos
vars:
DIR: "{{.ADAPTERS_DIR}}"
REPOS:
ref: .ADAPTERS
pnpm_plugins:
desc: Install plugin dependencies
cmds:
- task: pnpm_repos
vars:
DIR: "{{.PLUGINS_DIR}}"
REPOS:
ref: .PLUGINS
pnpm_adapters:
desc: Install adapter dependencies
cmds:
- task: pnpm_repos
vars:
DIR: "{{.ADAPTERS_DIR}}"
REPOS:
ref: .ADAPTERS