This commit is contained in:
Michel Roegl-Brunner 2025-03-18 09:39:44 +01:00
parent 13c0067181
commit 739fc91bea

View File

@ -68,12 +68,25 @@ jobs:
install_file="install/${script_name}-install.sh"
json_file="frontend/public/json/${script_name}.json"
if [[ -f "$ct_file" && -f "$install_file" && -f "$json_file" ]]; then
echo "All required files found."
echo "files_found=true" >> $GITHUB_OUTPUT
//check each file seperately
if [[ -f "$ct_file" ]]; then
echo "ct file found."
else
echo "Not all required files were found."
echo "ct file not found."
echo "files_found=false" >> $GITHUB_OUTPUT
echo "missing=$ct_file" >> $GITHUB_OUTPUT
fi
if [[ -f "$install_file" ]]; then
echo "install file found."
else
echo "files_found=false" >> $GITHUB_OUTPUT
echo "missing=$install_file" >> $GITHUB_OUTPUT
fi
if [[ -f "$json_file" ]]; then
echo "json file found."
else
echo "files_found=false" >> $GITHUB_OUTPUT
echo "missing=$json_file" >> $GITHUB_OUTPUT
fi
- name: Comment if not all Files found
@ -82,7 +95,7 @@ jobs:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
script_name="${{ steps.list_issues.outputs.script_name }}"
gh issue comment ${{ steps.list_issues.outputs.issue_nr }} --body "Not all required files were found for $script_name. Please check the files and try again. Must include ct/$script_name.sh, install/$script_name-install.sh, and frontend/public/json/$script_name.json."
gh issue comment ${{ steps.list_issues.outputs.issue_nr }} --body "Not all required files were found for $script_name. Please check the files and try again. Missing: ${{ steps.check_files.outputs.missing }}."
exit 1
- name: Get GitHub App User ID