mirror of
https://gitea.com/Lydanne/issues-helper.git
synced 2025-08-19 10:15:59 +08:00
test
This commit is contained in:
53
.gitignore
vendored
Normal file
53
.gitignore
vendored
Normal file
@@ -0,0 +1,53 @@
|
||||
# @source: https://github.com/xrkffgg/gitignore/blob/master/.gitignore
|
||||
|
||||
# production
|
||||
/dist
|
||||
/docs-dist
|
||||
|
||||
# Log file
|
||||
*.log
|
||||
npm-debug.log*
|
||||
yarn-debug.log*
|
||||
yarn-error.log*
|
||||
|
||||
# Private
|
||||
|
||||
# misc
|
||||
.DS_Store
|
||||
|
||||
# dependencies
|
||||
node_modules
|
||||
yarn.lock
|
||||
package-lock.json
|
||||
|
||||
# local env files
|
||||
.env.local
|
||||
.env.*.local
|
||||
|
||||
# Compiled file
|
||||
*.class
|
||||
*.css.map
|
||||
*.sass.map
|
||||
*.scss.map
|
||||
|
||||
# Editor directories and files
|
||||
.idea
|
||||
.vscode
|
||||
*.suo
|
||||
*.ntvs*
|
||||
*.njsproj
|
||||
*.sln
|
||||
*.sw?
|
||||
~$*.*
|
||||
|
||||
# umi
|
||||
.umi
|
||||
.umi-production
|
||||
.umi-test
|
||||
.env.local
|
||||
|
||||
# cache
|
||||
.sass-cache/
|
||||
|
||||
# test
|
||||
coverage
|
13
action.yml
Normal file
13
action.yml
Normal file
@@ -0,0 +1,13 @@
|
||||
name: '🤖 Issue Helper'
|
||||
description: 'Some operations on issue'
|
||||
author: 'xrkffgg'
|
||||
branding:
|
||||
icon: 'message-square'
|
||||
color: 'blue'
|
||||
inputs:
|
||||
github_token:
|
||||
description: 'github_token'
|
||||
default: ${{ github.token }}
|
||||
runs:
|
||||
using: node12
|
||||
main: 'dist/index.js'
|
31
package.json
Normal file
31
package.json
Normal file
@@ -0,0 +1,31 @@
|
||||
{
|
||||
"name": "issue-helper",
|
||||
"version": "0.0.1",
|
||||
"private": true,
|
||||
"description": "Some operations on issue.",
|
||||
"main": "lib/main.js",
|
||||
"scripts": {
|
||||
"build": "tsc",
|
||||
"package": "ncc build --source-map"
|
||||
},
|
||||
"author": "xrkffgg",
|
||||
"license": "MIT",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/actions-cool/issue-helper.git"
|
||||
},
|
||||
"keywords": [
|
||||
"actions",
|
||||
"issue",
|
||||
"helper",
|
||||
"github"
|
||||
],
|
||||
"dependencies": {
|
||||
"@actions/core": "^1.2.6",
|
||||
"@actions/github": "^4.0.0",
|
||||
"@octokit/rest": "^18.0.12"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@vercel/ncc": "^0.25.1"
|
||||
}
|
||||
}
|
28
src/main.js
Normal file
28
src/main.js
Normal file
@@ -0,0 +1,28 @@
|
||||
const core = require("@actions/core");
|
||||
const github = require("@actions/github");
|
||||
const { Octokit } = require('@octokit/rest');
|
||||
|
||||
const REACTION_TYPES = [
|
||||
"+1",
|
||||
"-1",
|
||||
"laugh",
|
||||
"confused",
|
||||
"heart",
|
||||
"hooray",
|
||||
"rocket",
|
||||
"eyes",
|
||||
];
|
||||
|
||||
async function main() {
|
||||
try {
|
||||
const token = core.getInput('token');
|
||||
const owner = github.context.repo.owner;
|
||||
const repo = github.context.repo.repo;
|
||||
console.log(owner, repo)
|
||||
}
|
||||
catch (error) {
|
||||
core.setFailed(error.message);
|
||||
}
|
||||
}
|
||||
|
||||
main();
|
Reference in New Issue
Block a user