Code Monkey home page Code Monkey logo

update-issue-body's Introduction

Update issue body

CI GitHub Marketplace

A GitHub action to update issue's body.

This is heavily based on peter-evans/create-or-update-comment.

Usage

Replace issue body

- name: Update Issue Body
  uses: julien-deramond/update-issue-body@v1
  with:
    issue-number: ${{ github.event.issue.number }}
    body: |
      **Edit**: Some new content
    edit-mode: replace

Append content to issue body

- name: Append Issue Body
  uses: julien-deramond/update-issue-body@v1
  with:
    issue-number: ${{ github.event.issue.number }}
    body: |
      **Edit**: Append some new content separated by a space
    edit-mode: append
    append-separator: space

Prepend content to issue body

- name: Prepend Issue Body
  uses: julien-deramond/update-issue-body@v1
  with:
    issue-number: ${{ github.event.issue.number }}
    body: |
      **Edit**: Prepend some new content separated by a space
    edit-mode: prepend
    prepend-separator: space

Action inputs

Name Description Default
token GITHUB_TOKEN (issues: write) or a repo scoped PAT. GITHUB_TOKEN
repository The full name of the repository in which to update the issue body. Current repository
issue-number The number of the issue to be updated.
body The issue body.
edit-mode The mode when updating the issue body, replace, append or prepend. append
append-separator The separator to use when appending to an existing issue body. (newline, space, none) newline
prepend-separator The separator to use when prepending to an existing issue body. (newline, space, none) newline

Accessing issues in other repositories

You can update issue body in another repository by using a PAT instead of GITHUB_TOKEN. The user associated with the PAT must have write access to the repository.

Sponsors

License

MIT

update-issue-body's People

Contributors

julien-deramond avatar

Stargazers

 avatar  avatar

Watchers

 avatar

update-issue-body's Issues

Test issue used by CI

Text prepended with newline separator
Text prepended with space separator Text prepended with newline separator
Text prepended with space separator Entire body replaced by the action Text appended with space separator Text appended with space separator

Implement prepend feature

Hi, good job on this action. I also would like to see a prepend feature to insert new content on top of the issue's body.

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.