From 6128d671a9cf400d008b77d7a650ff1c1f43befb Mon Sep 17 00:00:00 2001 From: gregorycottone Cottone Date: Fri, 17 May 2024 11:48:05 +0000 Subject: [PATCH] exercise 5 --- .github/actions/greeting/action.yaml | 15 +++++++++++++++ .github/workflows/exercise_5.yaml | 17 +++++++++++++++++ exercise_5_extra/exercise_5.yaml | 0 3 files changed, 32 insertions(+) create mode 100644 .github/actions/greeting/action.yaml create mode 100644 .github/workflows/exercise_5.yaml create mode 100644 exercise_5_extra/exercise_5.yaml diff --git a/.github/actions/greeting/action.yaml b/.github/actions/greeting/action.yaml new file mode 100644 index 0000000..2a69fdd --- /dev/null +++ b/.github/actions/greeting/action.yaml @@ -0,0 +1,15 @@ +name: Hello World Action + +description: A custom action that prints a hello message + +inputs: + message: + description: The message to print + required: true + +runs: + using: "composite" + steps: + - name: Set Greeting + run: echo "Hello $INPUT_WHO_TO_GREET." + shell: bash \ No newline at end of file diff --git a/.github/workflows/exercise_5.yaml b/.github/workflows/exercise_5.yaml new file mode 100644 index 0000000..3ae691b --- /dev/null +++ b/.github/workflows/exercise_5.yaml @@ -0,0 +1,17 @@ +name: Hello World + +on: + push: + branches: + - master + schedule: + - cron: 0 */5 * * * * + +jobs: + hello-world: + runs-on: ubuntu-latest + steps: + - name: Print Hello World + uses: ./.github/actions/greeting/action@v1 + with: + message: "Hello, ${{ github.event.pull_request.title }}" \ No newline at end of file diff --git a/exercise_5_extra/exercise_5.yaml b/exercise_5_extra/exercise_5.yaml new file mode 100644 index 0000000..e69de29