From 739fc91beaefaaa96e9a3fddc70c947683123e7a Mon Sep 17 00:00:00 2001 From: Michel Roegl-Brunner Date: Tue, 18 Mar 2025 09:39:44 +0100 Subject: [PATCH] Workflow --- .github/workflows/move-to-main-repo.yaml | 25 ++++++++++++++++++------ 1 file changed, 19 insertions(+), 6 deletions(-) diff --git a/.github/workflows/move-to-main-repo.yaml b/.github/workflows/move-to-main-repo.yaml index aa90b6a..c46a343 100644 --- a/.github/workflows/move-to-main-repo.yaml +++ b/.github/workflows/move-to-main-repo.yaml @@ -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 "files_found=false" >> $GITHUB_OUTPUT + 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