Skip to content

Navigation Menu

Sign in
Sign up
Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Repository files navigation

actions.diy

A GitHub Action to let you custom your action logic. It's like you can't do anything with it directly but you can do anything with it.(For me, I often use it to verify my prototype, then pub a official version if prototype works.)

Usage

You can use this action after any other action. Here is an example setup of this action:

  1. Create a .github/workflows/diy.yml file in your GitHub repo.
  2. Add the following code to the diy.yml file.
on: push
name: Do it yourself action
jobs:
 DIY:
 name: Start
 runs-on: ubuntu-latest
 steps:
 - uses: actions/checkout@v2
 
 - name: Do it yourself
 uses: echoings/actions.diy@v0.1.0
  1. Create a .echo.actions.diy.js file in your root project, and export an async function which's definition as follow, then You can handle action logic yourself
module.exports = async function DIY(
 options: {
 envs: process.env,
 ctx: github.context
 },
 utils: {
 axios: 'axios',
 core: '@actions/core',
 github: '@actions/github',
 exec: '@actions/exec',
 cache: '@actions/cache',
 artifact: '@actions/artifact',
 glob: '@actions/glob',
 io: '@actions/io',
 toolCache: '@actions/tool-cache'
 }
): {
 code?: number,
 data?: any,
 msg: string
}

Tips: If you need more extra dependency package, please do and use ncc to bundle them together.

About

DIY actions logic

Resources

Contributing

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages

AltStyle によって変換されたページ (->オリジナル) /