Giter VIP home page Giter VIP logo

pushoo-action's Introduction

Pushoo Github Action

A GitHub Action with Pushoo.js pushes multiple platform messages.

You also can use Pushoo CLI to push messages on command line.

action license Sourcegraph GitHub repo size latest tag GitHub last commit

Usage

you can use this action in your workflow like this:

name: CI
on:
  push:
    branches:
      - main
    tags:
      - "*"
  pull_request:
    branches: [main]
  workflow_dispatch:
jobs:
  push-message:
    name: Push Message
    runs-on: ubuntu-latest
    steps:
      - name: Checkout
        uses: actions/checkout@v2
      - name: Push Message
        uses: funnyzak/pushoo-action@main
        with:
          platforms: ifttt,wecombot,bark,dingtalk
          tokens: ${{ secrets.PUSH_TOKEN }}
          content: |
            # ${{ github.event.repository.name }} ${{ github.event_name }} Message
            ## trigger: ${{ github.event_name }} at ${{ github.event.head_commit.timestamp }}
            ## commit message: ${{ github.event.head_commit.message }}
            ## commit url: ${{ github.event.head_commit.url }}
            ## commit author: ${{ github.event.head_commit.author.name }}
            ## commit email: ${{ github.event.head_commit.author.email }}
            ## commit id: ${{ github.event.head_commit.id }}
          title: |
            ${{ github.repository }} ${{ github.event_name }} Message
          options: '{"bark": { "url": "https://github.com/${{github.repository}}" }, "dingtalk": {"msgtype": "markdown"}}'
          debug: false

NOTE: You need to set the PUSH_TOKEN secret in your repository settings.

Inputs

Name Type Description
platforms List/CSV List of platforms mapping (e.g., dingtalk,wecom)
tokens List/CSV List of token (e.g., dingtalk_token_string,wecom_token_string)
content String The push content of the Markdown format. If the push platform does not support MarkDown, Pushoo will automatically convert to support formats.
title String Optional, message title, if the push platform does not support message title, it will be spliced in the first line of the text.
options String Optional, For some additional configuration when pushing, Json string.
debug Boolean Enable the debug flag to show detail log.

Contribution

If you have any ideas or opinions, please refer to Issue or PR.

License

MIT License © 2022 funnyzak

pushoo-action's People

Contributors

dependabot[bot] avatar funnyzak avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.