Skip to content

Releases: sinshutu/upload-to-discord

Upload multiple files

29 Sep 03:28
b96d2d1
Compare
Choose a tag to compare

Changes

These changes were added by @shiipou contribution.

  • Update the action to Github Action V2 (#2, #3)
  • Upload multiple files using wildcards (#2, #3)

Usage

on: push
name: Main workflow
jobs:
  github-action:
    runs-on: ubuntu-latest
    steps:
    - uses: actions/checkout@master
    - name: Send file README.md to discord channel
      uses: sinshutu/upload-to-discord@master
      env:
        DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }}
      with:
        args: README.md

Requirements

You must pass at least one argument, the path to the file you want to attach. You must also include the DISCORD_WEBHOOK secret, otherwise uploading the file will not work.

    - name: Send file README.md to discord channel
      uses: sinshutu/upload-to-discord@master
      env:
        DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }}
      with:
        args: README.md

First release

29 Jan 21:06
Compare
Choose a tag to compare

Upload to Discord

Usage

workflow "Package" {
  on = "release"
  resolves = ["Upload to Discord"]
}

action "Build file" {
  uses = "actions/build/file"
}

action "Upload to Discord" {
  uses = "sinshutu/upload-to-discord@master"
  args = "my-file.pdf"
  secrets = ["DISCORD_WEBHOOK"]
  needs = ["Build file"]
}

Requirements

You must pass at least one argument, the path to the file you want to attach. You must also include the DISCORD_WEBHOOK secret, otherwise uploading the file will not work.

action "Upload to Discord" {
  uses = "sinshutu/upload-to-discord@master"
  args = "my-file.pdf"
  secrets = ["DISCORD_WEBHOOK"]
  needs = ["Build file"]
}