#!/bin/bash

set -ex

end_to_end=$1
end_to_end_pr=$2
forgejo=$3
forgejo_ref=$4

cd $end_to_end
date > last-upgrade
organizations=lib/ORGANIZATIONS
if ! test -f $organizations ; then
    echo "$organizations file not found"
    false
fi
#
# do not include forgejo-experimental so that 7.0-test is found
# in forgejo-integration where it was just built instead of
# forgejo-experimental which was published by the previous build
#
echo forgejo forgejo-integration > $organizations
