Skip to content
anchor

GitHub Action

My Joke Action

v2.0.0 Latest version

My Joke Action

anchor

My Joke Action

use an external API to retrieve and display a joke

Installation

Copy and paste the following snippet into your .yml file.

              

- name: My Joke Action

uses: mr-ayy/[email protected]

Learn more about this action in mr-ayy/skills-write-javascript-actions

Choose a version

skills-write-javascript-actions

My Joke Action

My Joke Action, created as part of the Microsoft Create Custom GitHub Action Exercice. Original repository this was cloned from can be found on skills/write-javascript-action.

This action provides the following functionality for GitHub Actions users:

  • Provides a joke using the icanhazdadjoke API.
  • Prints and provides the joke as part of output.joke-output

Basic Usage

See action.yml.

steps:
  - id: joke
    name: My Joke Action
    uses: mr-ayy/skills-write-javascript-actions@v2

  - run: echo "${{ steps.joke.outputs.joke-output }}"