Skip to content
18 changes: 18 additions & 0 deletions .github/workflows/issue-comment.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: issue-comment-workflow
on: issue-comment


jobs:
pr-comment:
if: ${{ github.event.issue.pull_request}}
runs-on: ubuntu-latest
steps:
- name: pr comment
run: echo ${{ github.event.issue.pull_request}}

issue-comment:
if: ${{ !github.event.issue.pull_request}}
runs-on: ubuntu-latest
steps:
- name: issue comment
run: echo ${{ github.event.issue.pull_request}}
15 changes: 15 additions & 0 deletions .github/workflows/part1/isuue.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: issue-workflow1
on:
issues:
types: [opened]

jobs:
pull-request-job:
runs-on: ubuntu-latest
steps:
- name: step1
run: echo hello world
- name: step2
run: |
echo hello world
echo Hi Haaland
13 changes: 13 additions & 0 deletions .github/workflows/part1/pull_request.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: pull-request-workflow
on: pull_request

jobs:
pull-request-job:
runs-on: ubuntu-latest
steps:
- name: step1
run: echo hello world
- name: step2
run: |
echo hello world
echo Hi Haaland
13 changes: 13 additions & 0 deletions .github/workflows/part1/push.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: push-workflow-2
on: push

jobs:
push-job:
runs-on: ubuntu-latest
steps:
- name: step1
run: echo hello world
- name: step2
run: |
echo hello world
echo Hi Haaland