lubitest/.forgejo/workflows/demo.yml
lubiana 9615bbc882
All checks were successful
/ build (pull_request) Successful in 22s
test
2024-09-17 20:25:52 +02:00

28 lines
975 B
YAML

on: [pull_request]
jobs:
build:
runs-on: docker
container:
image: git.php.fail/lubiana/container/php:ci
steps:
- name: Manually checkout
env:
REPO: '${{ github.repository }}'
TOKEN: '${{ secrets.GITHUB_TOKEN }}'
GIT_SERVER: 'hannover.ccc.de/gitlab'
run: |
git clone --branch $GITHUB_HEAD_REF https://${TOKEN}@${GIT_SERVER}/${REPO}.git .
git fetch
git checkout $GITHUB_HEAD_REF
- name: lol
run: |
ls -l
pwd
output=$(cat output.txt)
jq -n --arg msg "```$(cat output.txt)```" '{"body": $msg}' > /tmp/git-msg
echo $output
curl -X POST \
-H "Authorization: token ${GITHUB_TOKEN}" \
-H "Content-Type: application/json" \
-d @/tmp/git-msg \
"${{ env.GITHUB_SERVER_URL }}/api/v1/repos/${{ github.repository }}/issues/${{ github.event.pull_request.number }}/comments"