W
{{ define "__get_channel_for_code_owner" -}}
{{- if eq . "platform-team" -}}
platform-alerts
с чем тут сравнивается platform-team ?
где вообще дока про это живёт?
Size: a a a
W
{{ define "__get_channel_for_code_owner" -}}
{{- if eq . "platform-team" -}}
platform-alerts
AD
{{ define "__get_channel_for_code_owner" -}}
{{- if eq . "platform-team" -}}
platform-alerts
.
здесь это контекст (аргумент?), который передали в макрос (функцию?){{ template "__get_channel_for_code_owner" .CommonLabels.code_owner }}
. Где .CommonLabels.code_owner
и есть контекстAN
AN
W
TF
TF
AN
W
AN
Templates are executed by applying them to a data structure. Annotations in the template refer to elements of the data structure (typically a field of a struct or a key in a map) to control execution and derive values to be displayed. Execution of the template walks the structure and sets the cursor, represented by a period '.' and called "dot", to the value at the current location in the structure as execution proceeds.
W
A
.
С
A
С
A
С
VS
Debian GNU/Linux 9
TF
Debian GNU/Linux 9