Skip to content

A02 Ilia Malakhov #1529

A02 Ilia Malakhov

A02 Ilia Malakhov #1529

Workflow file for this run

name: Regression
on: # [push]
pull_request:
# pull_request_target:
types: [synchronize, opened, reopened, edited]
jobs:
job1:
runs-on: ubuntu-latest
# Map a step output to a job output
steps:
- name: Extract branch name
shell: bash
run: echo "##[set-output name=branch;]$(echo ${GITHUB_REF#refs/heads/})"
id: extract_branch
- uses: actions/checkout@v2
with:
ref: refs/pull/${{ github.event.pull_request.number }}/head
- id: step1
run: |
login=${{ github.event.pull_request.user.login }}
echo "$login"
if [ "${{ github.base_ref }}" != "${{ github.head_ref }}" ]; then
echo "FIASCO: base and head branches differs"
exit 1
fi
wget --quiet -c --retry-connrefused --tries=0 https://drive.usercontent.google.com/download\?id\=1grnb60AaZBCwhBqETeKOGh3tW7ggEWDJ\&export\=download\&authuser\=0\&confirm\=t\&uuid\=34a6d91a-d052-4775-b466-1f8234711b74\&at\=APZUnTXSqc-ZLIRoSD-uYPeQYGfk%3A1707491383232 -O cw-20201.tar.gz
docker load < cw-20201.tar.gz
docker run -d -it --name cw-2021 -v $(pwd):/usr/share/compiler-workout berezun/cw-2021
docker exec -t cw-2021 sh test.sh
echo "All checks have successfully passed"
echo "$login" > gitid.txt
echo ${{ github.base_ref }} > base.txt
branch=${{ github.base_ref }}
if [[ ${branch:1:1} -eq 0 ]]
then
echo ${branch:2:1} > assignment_number.txt
else
echo ${branch:1:2} > assignment_number.txt
fi
- name: Check Deadline
run: |
deadline=2024-02-12T23:59
if [[ $(date +'%Y-%m-%d') > $deadline ]];
then
echo "FIASCO: The deadline has expired"
exit 1
fi
- uses: actions/upload-artifact@v2
with:
name: share_info
path: |
gitid.txt
base.txt
assignment_number.txt