generated from openmcp-project/repository-template
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathTaskfile.yaml
61 lines (57 loc) · 2.55 KB
/
Taskfile.yaml
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
version: 3
# vars: # cannot be specified here due to https://github.com/go-task/task/issues/2108
# NESTED_MODULES: api
# API_DIRS: '{{.ROOT_DIR}}/api/core/v1alpha1/...'
# MANIFEST_OUT: '{{.ROOT_DIR}}/api/crds/manifests'
# CODE_DIRS: '{{.ROOT_DIR}}/cmd/... {{.ROOT_DIR}}/internal/... {{.ROOT_DIR}}/test/... {{.ROOT_DIR}}/api/constants/... {{.ROOT_DIR}}/api/errors/... {{.ROOT_DIR}}/api/install/... {{.ROOT_DIR}}/api/v1alpha1/... {{.ROOT_DIR}}/api/core/v1alpha1/...'
# COMPONENTS: 'mcp-operator'
# REPO_URL: 'https://github.com/openmcp-project/mcp-operator'
# GENERATE_DOCS_INDEX: "true"
includes:
shared:
taskfile: hack/common/Taskfile_controller.yaml
flatten: true
excludes: # put task names in here which are overwritten in this file
- generate:code
vars:
NESTED_MODULES: api
API_DIRS: '{{.ROOT_DIR}}/api/core/v1alpha1/...'
MANIFEST_OUT: '{{.ROOT_DIR}}/api/crds/manifests'
CODE_DIRS: '{{.ROOT_DIR}}/cmd/... {{.ROOT_DIR}}/internal/... {{.ROOT_DIR}}/test/... {{.ROOT_DIR}}/api/constants/... {{.ROOT_DIR}}/api/errors/... {{.ROOT_DIR}}/api/install/... {{.ROOT_DIR}}/api/v1alpha1/... {{.ROOT_DIR}}/api/core/v1alpha1/...'
COMPONENTS: 'mcp-operator'
REPO_URL: 'https://github.com/openmcp-project/mcp-operator'
GENERATE_DOCS_INDEX: "true"
ENVTEST_REQUIRED: "true"
common: # imported a second time so that overwriting task definitions can call the overwritten task with a 'c:' prefix
taskfile: hack/common/Taskfile_controller.yaml
internal: true
aliases:
- c
vars:
NESTED_MODULES: api
API_DIRS: '{{.ROOT_DIR}}/api/core/v1alpha1/...'
MANIFEST_OUT: '{{.ROOT_DIR}}/api/crds/manifests'
CODE_DIRS: '{{.ROOT_DIR}}/cmd/... {{.ROOT_DIR}}/internal/... {{.ROOT_DIR}}/test/... {{.ROOT_DIR}}/api/constants/... {{.ROOT_DIR}}/api/errors/... {{.ROOT_DIR}}/api/install/... {{.ROOT_DIR}}/api/v1alpha1/... {{.ROOT_DIR}}/api/core/v1alpha1/...'
COMPONENTS: 'mcp-operator'
REPO_URL: 'https://github.com/openmcp-project/mcp-operator'
GENERATE_DOCS_INDEX: "true"
ENVTEST_REQUIRED: "true"
tasks:
generate:code: # overwrites shared code task to add external API fetching
desc: " Generate code (mainly DeepCopy functions) and fetches external APIs."
aliases:
- gen:code
- g:code
run: once
cmds:
- task: external-apis
- task: c:generate:code
external-apis:
desc: " Fetch external APIs."
run: once
method: checksum
sources:
- hack/external-apis/*
cmds:
- 'go run {{.ROOT_DIR}}/hack/external-apis/main.go'
internal: true