Skip to content

Commit

Permalink
Configuration: add global checks (#2)
Browse files Browse the repository at this point in the history
  • Loading branch information
rachelcarmena authored Feb 20, 2020
1 parent eb0661b commit 30e3287
Show file tree
Hide file tree
Showing 2 changed files with 108 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: "Check Build Integration"

on:
push:
branches:
- master

jobs:
check-build-integration:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v1
- name: Check
run: |
git clone https://github.com/arrow-kt/arrow.git arrow
./arrow/scripts/check-build-integration.sh
- name: Prepare environment to create the issue (new package)
if: failure()
id: create-issue
run: |
echo $(git log -1 --pretty=format:%s)
echo ::set-output name=title::$(git log -1 --pretty=format:%s)
echo -e "## Details\n" > issue.log
echo -e "* **Commit hash**: \`$(git log -1 --pretty=format:%h)\`\n" >> issue.log
echo -e "* **Author**: $(git log -1 --pretty=format:%an)\n" >> issue.log
echo -e "* **Committer**: $(git log -1 --pretty=format:%cn)\n" >> issue.log
echo -e "* **More info**: [error log](https://github.com/arrow-kt/arrow-integrations/commit/$GITHUB_SHA/checks)\n" >> issue.log
cat issue.log
rm -rf /home/runner/work/_actions/actions/github-script/0.3.0/node_modules
cd /home/runner/work/_actions/actions/github-script/0.3.0/
npm install
npm install xmlhttprequest
- name: Create the issue
if: failure()
uses: actions/[email protected]
with:
github-token: ${{github.token}}
script: |
var XMLHttpRequest = require("xmlhttprequest").XMLHttpRequest;
function readFile(file) {
var content;
var rawFile = new XMLHttpRequest();
rawFile.open("GET", file, false);
rawFile.onreadystatechange = function () {
content = rawFile.responseText;
}
rawFile.send();
return content;
}
await github.issues.create({...context.repo,
title: "BUILD: error when integrating '${{ steps.create-issue.outputs.title }}' with the rest of Arrow libraries",
body: readFile("file://${{github.workspace}}/issue.log")});
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: "Check Doc Integration"

on:
push:
branches:
- master

jobs:
check-doc-integration:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v1
- name: Check
run: |
git clone https://github.com/arrow-kt/arrow.git arrow
./arrow/scripts/check-doc-integration.sh
- name: Prepare environment to create the issue (new package)
if: failure()
id: create-issue
run: |
echo $(git log -1 --pretty=format:%s)
echo ::set-output name=title::$(git log -1 --pretty=format:%s)
echo -e "## Details\n" > issue.log
echo -e "* **Commit hash**: \`$(git log -1 --pretty=format:%h)\`\n" >> issue.log
echo -e "* **Author**: $(git log -1 --pretty=format:%an)\n" >> issue.log
echo -e "* **Committer**: $(git log -1 --pretty=format:%cn)\n" >> issue.log
echo -e "* **More info**: [error log](https://github.com/arrow-kt/arrow-integrations/commit/$GITHUB_SHA/checks)\n" >> issue.log
cat issue.log
rm -rf /home/runner/work/_actions/actions/github-script/0.3.0/node_modules
cd /home/runner/work/_actions/actions/github-script/0.3.0/
npm install
npm install xmlhttprequest
- name: Create the issue
if: failure()
uses: actions/[email protected]
with:
github-token: ${{github.token}}
script: |
var XMLHttpRequest = require("xmlhttprequest").XMLHttpRequest;
function readFile(file) {
var content;
var rawFile = new XMLHttpRequest();
rawFile.open("GET", file, false);
rawFile.onreadystatechange = function () {
content = rawFile.responseText;
}
rawFile.send();
return content;
}
await github.issues.create({...context.repo,
title: "DOC: error when integrating '${{ steps.create-issue.outputs.title }}' with the rest of Arrow libraries",
body: readFile("file://${{github.workspace}}/issue.log")});

0 comments on commit 30e3287

Please sign in to comment.