From a327f8c8f40887ae3003cc47f08415d5df16f64c Mon Sep 17 00:00:00 2001 From: stumkan <106744295+stumkan@users.noreply.github.com> Date: Sat, 15 Feb 2025 08:26:07 +0200 Subject: [PATCH 1/6] Create greetings.yml --- .github/workflows/greetings.yml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 .github/workflows/greetings.yml diff --git a/.github/workflows/greetings.yml b/.github/workflows/greetings.yml new file mode 100644 index 00000000..46774343 --- /dev/null +++ b/.github/workflows/greetings.yml @@ -0,0 +1,16 @@ +name: Greetings + +on: [pull_request_target, issues] + +jobs: + greeting: + runs-on: ubuntu-latest + permissions: + issues: write + pull-requests: write + steps: + - uses: actions/first-interaction@v1 + with: + repo-token: ${{ secrets.GITHUB_TOKEN }} + issue-message: "Message that will be displayed on users' first issue" + pr-message: "Message that will be displayed on users' first pull request" From d80ecacccf9db5a8bc155d6ad83eb0467867fea7 Mon Sep 17 00:00:00 2001 From: stumkan <106744295+stumkan@users.noreply.github.com> Date: Sat, 15 Feb 2025 08:55:12 +0200 Subject: [PATCH 2/6] moved greeting workflow to save for later --- .github/workflows/greetings.yml | 16 ---------------- .../templates}/custom-action.yml | 0 github-actions/templates/greetings.yml | 1 - 3 files changed, 17 deletions(-) delete mode 100644 .github/workflows/greetings.yml rename {.github/workflows => github-actions/templates}/custom-action.yml (100%) diff --git a/.github/workflows/greetings.yml b/.github/workflows/greetings.yml deleted file mode 100644 index 46774343..00000000 --- a/.github/workflows/greetings.yml +++ /dev/null @@ -1,16 +0,0 @@ -name: Greetings - -on: [pull_request_target, issues] - -jobs: - greeting: - runs-on: ubuntu-latest - permissions: - issues: write - pull-requests: write - steps: - - uses: actions/first-interaction@v1 - with: - repo-token: ${{ secrets.GITHUB_TOKEN }} - issue-message: "Message that will be displayed on users' first issue" - pr-message: "Message that will be displayed on users' first pull request" diff --git a/.github/workflows/custom-action.yml b/github-actions/templates/custom-action.yml similarity index 100% rename from .github/workflows/custom-action.yml rename to github-actions/templates/custom-action.yml diff --git a/github-actions/templates/greetings.yml b/github-actions/templates/greetings.yml index 996da6bb..46774343 100644 --- a/github-actions/templates/greetings.yml +++ b/github-actions/templates/greetings.yml @@ -9,7 +9,6 @@ jobs: issues: write pull-requests: write steps: - # https://github.com/actions/first-interaction - uses: actions/first-interaction@v1 with: repo-token: ${{ secrets.GITHUB_TOKEN }} From a74dbbb604ba1e85c91beca30d5b80bd33756fe5 Mon Sep 17 00:00:00 2001 From: stumkan <106744295+stumkan@users.noreply.github.com> Date: Sat, 15 Feb 2025 09:36:22 +0200 Subject: [PATCH 3/6] 5 munutes schedulled trigger --- .github/workflows/schedule.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 .github/workflows/schedule.yml diff --git a/.github/workflows/schedule.yml b/.github/workflows/schedule.yml new file mode 100644 index 00000000..69fff6ee --- /dev/null +++ b/.github/workflows/schedule.yml @@ -0,0 +1,11 @@ +name: scheduled trigger every 5 minutes +on: + schedule: + - cron: '*/5 * * * *' + +jobs: + hello_world: + runs-on: ubuntu-latest + steps: + - name: Echo current time + run: echo "The current server time is $(date)" From 09a0d67fc5bd97338788064508934109637e39fb Mon Sep 17 00:00:00 2001 From: stumkan <106744295+stumkan@users.noreply.github.com> Date: Sat, 15 Feb 2025 10:06:16 +0200 Subject: [PATCH 4/6] push trigger from main --- .github/workflows/multi-event.yml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 .github/workflows/multi-event.yml diff --git a/.github/workflows/multi-event.yml b/.github/workflows/multi-event.yml new file mode 100644 index 00000000..a3275be3 --- /dev/null +++ b/.github/workflows/multi-event.yml @@ -0,0 +1,19 @@ +on: + push: + branches: + - main + - dev + pull_request: + branches: + - main + +jobs: + hello_world: + runs-on: ubuntu-latest + steps: + - name: "Echo Basic Information" + run: | + echo "REF: $GITHUB_REF" + echo "Job ID: $GITHUB_JOB" + echo "Action: $GITHUB_ACTION" + echo "Actor: $GITHUB_ACTOR" \ No newline at end of file From 2c7617d0c2539001f42e9e384278ba0b8e117181 Mon Sep 17 00:00:00 2001 From: stumkan <106744295+stumkan@users.noreply.github.com> Date: Sat, 15 Feb 2025 10:10:11 +0200 Subject: [PATCH 5/6] push trigger from dev branch --- .github/workflows/schedule.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/schedule.yml b/.github/workflows/schedule.yml index 69fff6ee..70437850 100644 --- a/.github/workflows/schedule.yml +++ b/.github/workflows/schedule.yml @@ -7,5 +7,5 @@ jobs: hello_world: runs-on: ubuntu-latest steps: - - name: Echo current time + - name: Echo current time. run: echo "The current server time is $(date)" From 581a6331452c563ebbfe53125a6c737a95e30657 Mon Sep 17 00:00:00 2001 From: stumkan <106744295+stumkan@users.noreply.github.com> Date: Sat, 15 Feb 2025 10:26:09 +0200 Subject: [PATCH 6/6] put a full stop in the multi wf from dev --- .github/workflows/multi-event.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/multi-event.yml b/.github/workflows/multi-event.yml index a3275be3..d6f8b29c 100644 --- a/.github/workflows/multi-event.yml +++ b/.github/workflows/multi-event.yml @@ -11,7 +11,7 @@ jobs: hello_world: runs-on: ubuntu-latest steps: - - name: "Echo Basic Information" + - name: "Echo Basic Information." run: | echo "REF: $GITHUB_REF" echo "Job ID: $GITHUB_JOB"