Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions .github/labels.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
area:
- 'bug'
- 'important'

kind:
- 'failing-test'
- 'cleanup'

priority:
- 'low'
- 'high'

tests:
- '**/*.test.ts'

source:
- 'src/**'
31 changes: 31 additions & 0 deletions .github/workflows/issueComment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: "Test issue comments"
on:
issue_comment:
types: [created]

jobs:
execute:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- run: npm install
- run: npm run build
- uses: ./
with:
prow-commands: '/assign
/unassign
/approve
/retitle
/area
/kind
/priority
/remove
/lgtm
/close
/reopen
/lock
/milestone
/hold
/cc
/uncc'
github-token: "${{ secrets.GITHUB_TOKEN }}"
17 changes: 17 additions & 0 deletions .github/workflows/lgtm-merger.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: "Merge on lgtm label"
on:
schedule:
- cron: "*/20 * * * *"

jobs:
execute:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- run: npm install
- run: npm run build
- uses: ./
with:
jobs: 'lgtm'
github-token: "${{ secrets.GITHUB_TOKEN }}"
merge-method: 'squash'
34 changes: 0 additions & 34 deletions .github/workflows/main.yml

This file was deleted.

14 changes: 14 additions & 0 deletions .github/workflows/onPr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: "Run Jobs on PR"
on: pull_request

jobs:
execute:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- run: npm install
- run: npm run build
- uses: ./
with:
jobs: 'lgtm'
github-token: "${{ secrets.GITHUB_TOKEN }}"
12 changes: 12 additions & 0 deletions .github/workflows/prLabeler.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
name: "Label PRs from globs"
on:
- pull_request_target

jobs:
triage:
runs-on: ubuntu-latest
steps:
- uses: actions/labeler@main
with:
repo-token: "${{ secrets.GITHUB_TOKEN }}"
configuration-path: .github/labels.yaml
19 changes: 19 additions & 0 deletions .github/workflows/stale.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Mark stale issues and pull requests

on:
schedule:
- cron: "0 0 * * *"

jobs:
stale:

runs-on: ubuntu-latest

steps:
- uses: actions/stale@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
stale-issue-message: 'Issue is stale'
stale-pr-message: 'Pull req is stale'
stale-issue-label: 'no-issue-activity'
stale-pr-label: 'no-pr-activity'
12 changes: 12 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
name: "Build and test code"
on: [push, pull_request]

jobs:
build-test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- run: |
npm install
npm run build
npm run test
15 changes: 3 additions & 12 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules.
apply plugin: 'com.huawei.ohos.app'
apply plugin: "org.sonarqube"


//For instructions on signature configuration, see https://developer.harmonyos.com/en/docs/documentation/doc-guides/ide_debug_device-0000001053822404#section1112183053510
ohos {
Expand All @@ -19,7 +19,7 @@ buildscript {
dependencies {
classpath 'com.huawei.ohos:hap:3.0.3.4'
classpath 'com.huawei.ohos:decctest:1.2.6.0'
classpath "org.sonarsource.scanner.gradle:sonarqube-gradle-plugin:3.3"

}
}

Expand All @@ -32,13 +32,4 @@ allprojects {
url 'https://developer.huawei.com/repo/'
}
}
sonarqube {
properties {
property "sonar.projectKey", "applibgroup_Buttons"
property "sonar.organization", "applibgroup"
property "sonar.host.url", "https://sonarcloud.io/"
property "sonar.sources", "entry/src"
property "sonar.java.binaries", "entry/build"
}
}
}

51 changes: 50 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1 +1,50 @@
{}
{
"name": "prow-github-actions",
"version": "1.1.3",
"description": "Slash commands, jobs, and chat-ops for Github actions inspired by Kubernetes Prow",
"main": "lib/main.js",
"scripts": {
"build": "tsc",
"format": "prettier --write **/*.ts",
"format-check": "prettier --check **/*.ts",
"lint": "eslint src/**/*.ts",
"pack": "ncc build",
"test": "jest",
"test-all": "npm run build && npm run pack && npm test",
"all": "npm run build && npm run format && npm run lint && npm run pack && npm test"
},
"repository": {
"type": "git",
"url": "git+https://github.com/jpmcb/prow-github-actions.git"
},
"keywords": [
"actions",
"prow"
],
"author": "John McBride",
"license": "MIT",
"dependencies": {
"@actions/core": "^1.2.6",
"@actions/github": "^2.1.1",
"@octokit/webhooks": "^7.2.0",
"minimatch": "^3.0.4"
},
"devDependencies": {
"@types/jest": "^24.0.23",
"@types/js-yaml": "^3.12.3",
"@types/minimatch": "^3.0.3",
"@types/node": "^12.7.12",
"@typescript-eslint/parser": "^2.8.0",
"@zeit/ncc": "^0.20.5",
"eslint": "^5.16.0",
"eslint-plugin-github": "^2.0.0",
"eslint-plugin-jest": "^22.21.0",
"jest": "^26.6.3",
"jest-circus": "^26.6.3",
"js-yaml": "^3.13.1",
"nock": "^12.0.3",
"prettier": "^1.19.1",
"ts-jest": "^26.4.1",
"typescript": "^3.6.4"
}
}