forked from sirius/actions-laba-1
update
This commit is contained in:
@@ -6,20 +6,12 @@ on:
|
||||
|
||||
jobs:
|
||||
second-job:
|
||||
runs-on: docker # docker, sirius или golang
|
||||
runs-on: golang
|
||||
steps:
|
||||
# Клонируем репозиторий для Runnera
|
||||
- name: Checkout rpository
|
||||
uses: actions/checkout@v6
|
||||
- run: |
|
||||
|
||||
# Выводим текстовое сообщение
|
||||
- name: Echo test
|
||||
run: echo "Hello!"
|
||||
|
||||
# Выводим переменные окружения
|
||||
- name: Show environment
|
||||
run: env
|
||||
|
||||
# Выводим контекст Gitea в формате JSON
|
||||
- name: Show Gitea context
|
||||
run: echo "${{ toJson(gitea) }}"
|
||||
if [ ${{ gitea.actor }} == 'wwitchq' ]; then
|
||||
echo "Hello, ${{ gitea.actor }}"
|
||||
else
|
||||
echo "Hello, Violetta"
|
||||
fi
|
||||
29
.gitea/workflows/example-condition.yaml
Normal file
29
.gitea/workflows/example-condition.yaml
Normal file
@@ -0,0 +1,29 @@
|
||||
name: "Example condition"
|
||||
run-name: "deploy all condition"
|
||||
|
||||
on:
|
||||
issues:
|
||||
types:
|
||||
- closed
|
||||
- labeled
|
||||
push:
|
||||
paths:
|
||||
- test.txt
|
||||
- services.txt
|
||||
branches:
|
||||
- main
|
||||
issue_comment:
|
||||
types:
|
||||
- created
|
||||
|
||||
jobs:
|
||||
check-condition:
|
||||
runs-on: golang
|
||||
if: contains(github.event.issue.labels.*.name, 'bug')
|
||||
steps:
|
||||
- name: Echo test
|
||||
run: echo "Этот шаг выполнится только при выполнении условия above"
|
||||
- name: Echo test
|
||||
if: contains(github.event.issue.labels.*.name, 'bug')
|
||||
run: echo "${{ toJson(github.event.issue) }}"
|
||||
|
||||
16
.gitea/workflows/example-new.yaml
Normal file
16
.gitea/workflows/example-new.yaml
Normal file
@@ -0,0 +1,16 @@
|
||||
name: "Example condition"
|
||||
run-name: "condition 2"
|
||||
on:
|
||||
issues:
|
||||
types:
|
||||
- labeled
|
||||
- opened
|
||||
- unlabeled
|
||||
jobs:
|
||||
check-condition:
|
||||
runs-on: golang
|
||||
if: contains(github.event.issue.labels.*.name, 'bug')
|
||||
steps:
|
||||
- name: Echo test
|
||||
if: contains(github.event.issue.labels.*.name, 'bug')
|
||||
run: echo "${{ toJson(github.event.issue) }}"
|
||||
1
services.txt
Normal file
1
services.txt
Normal file
@@ -0,0 +1 @@
|
||||
uraaaaaa
|
||||
Reference in New Issue
Block a user