forked from league-curriculum/Python-Apprentice
-
Notifications
You must be signed in to change notification settings - Fork 0
22 lines (17 loc) · 743 Bytes
/
notify.yml
File metadata and controls
22 lines (17 loc) · 743 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
name: Notify Telemetry
on: [push, fork]
jobs:
notify_telemetry:
runs-on: ubuntu-latest
steps:
- name: Tell The League that the student has pushed code
env:
GITHUB_USERNAME: ${{ github.actor }}
REPO_URL: ${{ github.repositoryUrl }}
COMMIT: ${{ github.sha }}
EVENT_TYPE: ${{ github.event_name }}
DATE_TIME: ${{ github.event.head_commit.timestamp }}
run: |
curl -X POST https://student-telem.do.jointheleague.org/github/activity \
-H "Content-Type: application/json" \
-d '{"username": "'"${GITHUB_USERNAME}"'", "date_time": "'"${DATE_TIME}"'", "repo_url": "'"${REPO_URL}"'", "commit": "'"${COMMIT}"'", "event_type": "'"${EVENT_TYPE}"'"}'