File tree Expand file tree Collapse file tree 1 file changed +9
-6
lines changed
Expand file tree Collapse file tree 1 file changed +9
-6
lines changed Original file line number Diff line number Diff line change @@ -132,26 +132,29 @@ jobs:
132132 echo "Debug: Package name: $PACKAGE_NAME"
133133 ls -la
134134
135- # Move the packaged file to the target directory using variables
136- mkdir -p dify-plugins/${{ steps.get_basic_info.outputs.org_name }}/${{ steps.get_basic_info.outputs.plugin_name }}
137- mv "$PACKAGE_NAME" dify-plugins/${{ steps.get_basic_info.outputs.org_name }}/${{ steps.get_basic_info.outputs.plugin_name }}/
138-
139- # Enter the target repository directory
135+ # Enter the target repository directory first
140136 cd dify-plugins
141137
142138 # Configure git
143139 git config user.name "GitHub Actions"
144140 git config user.email "[email protected] " 145141
146- # Ensure we are on the latest main branch
142+ # Ensure we are on the latest main branch and clean working directory
147143 git fetch origin main
148144 git checkout main
149145 git pull origin main
146+
147+ # Clean any untracked files that might conflict
148+ git clean -fd
150149
151150 # Create and switch to a new branch using variables and new naming convention
152151 BRANCH_NAME="bump-${{ steps.get_basic_info.outputs.plugin_name }}-plugin-${{ steps.get_basic_info.outputs.version }}"
153152 git checkout -b "$BRANCH_NAME"
154153
154+ # Now move the packaged file to the target directory using variables
155+ mkdir -p ${{ steps.get_basic_info.outputs.org_name }}/${{ steps.get_basic_info.outputs.plugin_name }}
156+ mv "../$PACKAGE_NAME" ${{ steps.get_basic_info.outputs.org_name }}/${{ steps.get_basic_info.outputs.plugin_name }}/
157+
155158 # Add and commit changes (using git add .)
156159 git add .
157160 git status # for debugging
You can’t perform that action at this time.
0 commit comments