Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

qwer #251

Open
wants to merge 15 commits into
base: main
Choose a base branch
from
6 changes: 3 additions & 3 deletions .github/workflows/custom-action.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
on: [push]

on:
workflow_dispatch:
jobs:
my-job:
runs-on: ubuntu-latest
Expand All @@ -12,4 +12,4 @@ jobs:
name: 'Brown'
# Use the output from the `hello` step
- name: Get the Output
run: echo "The time was ${{ steps.hello.outputs.greeting }}"
run: echo "The time was ${{ steps.hello.outputs.greeting }}"
16 changes: 16 additions & 0 deletions .github/workflows/greetings.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: Greetings

on: [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"
28 changes: 28 additions & 0 deletions .github/workflows/manual-worflow.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: This is to learn the manual dispatch of workflows

on:
workflow_dispatch:
inputs:
script_name:
required: true
description: 'Please choose the name of the .py you want to execute'
default: "hello.py"
type: choice
options:
- "hello.py"
- "hello_1.py"
- "hello_2.py"
- "hello_3.py"


jobs:
manual_dispatch:
runs-on: ubuntu-latest
steps :
- name: Code Checkout
uses: actions/checkout@v4

- name: Run Python script
run : python ${{github.event.inputs.script_name}}


19 changes: 19 additions & 0 deletions .github/workflows/multi-trigger.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: This is a workflow which has multiple triggers

on:
push:
branches:
- main
- Multi-Trigger_Branch
pull_request:

jobs:
job_name:
runs-on: ubuntu-latest
steps:
- name: Code Checkout
uses: actions/checkout@v4

- name: Checking a few commands
run: |
echo "The job id is $GITHUB_JOB"
15 changes: 15 additions & 0 deletions .github/workflows/repo-dispatch.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: Repo-Dispatch-Testing

on:
repository_dispatch:
types: [my-event]

jobs:
new-job:
runs-on: ubuntu-latest
steps:
- name: Checking out the code
uses: actions/checkout@v4

- name: Checking Which Event
run: echo " The Event is ${{github.event.action}} "
16 changes: 16 additions & 0 deletions .github/workflows/scheduled_jobs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: Practise workflow to learn about cron jobs

on:
schedule:
- cron: "*/5 * * * *"

jobs:
check_workflow:
runs-on: ubuntu-latest
steps:
- name: Code Checkout
uses: actions/checkout@v4

- name: Printing the date after every 5 minutes
run: echo " The date at which this workflow is running is ${date}"

1 change: 1 addition & 0 deletions hello.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
print("hello world")
1 change: 1 addition & 0 deletions hello_2.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
print("This is to print hello 2")