Skip to content

Commit

Permalink
Add verify cropperJsInterop.min.js file in release.yml (#361)
Browse files Browse the repository at this point in the history
## Target
<!--
  Why are you making this change?
 -->
Add verify cropperJsInterop.min.js file in release.yml
#### Open Questions
<!-- OPTIONAL
- [ ] Use the GitHub checklists to spark discussion on issues that may
arise from your approach. Please tick the box and explain your answer.
-->

## Checklist
<!--
It serves as a gentle reminder for common tasks. Confirm it's done and
check everything that applies.
-->
- [ ] Tests cover new or modified code
- [ ] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the site documentation
- [ ] I have made corresponding changes to the README, NuGet README file
- [ ] My changes generate no new warnings
- [ ] New dependencies added or updated
- [ ] Includes breaking changes
- [ ] Version bumped

## Visuals
<!-- OPTIONAL
Show results both before and after this change. When the output changes,
it can be a screenshot of a trace, metric, or log illustrating the
change.
-->
  • Loading branch information
MaxymGorn authored Aug 4, 2024
2 parents 365eca9 + 0119e2b commit ca5e328
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,21 @@ jobs:
run: dotnet pack -c Release
working-directory: src/Cropper.Blazor/Cropper.Blazor

- name: Verify cropperJsInterop.min.js static web asset
run: |
json_path="src/Cropper.Blazor/Cropper.Blazor/bin/Release/net8.0/Cropper.Blazor.staticwebassets.runtime.json"
if [ -f "$json_path" ]; then
if jq -e '.Root.Children["cropperJsInterop.min.js"]' "$json_path" > /dev/null; then
echo "Key 'cropperJsInterop.min.js' exists."
else
echo "Key 'cropperJsInterop.min.js' does not exist."
exit 1
fi
else
echo "File $json_path does not exist."
exit 1
fi
- name: Push to NuGet Gallery
run: dotnet nuget push bin/Release/*.nupkg --source "https://api.nuget.org/v3/index.json" --api-key ${{secrets.NUGET_API_KEY}} --skip-duplicate
working-directory: src/Cropper.Blazor/Cropper.Blazor
Expand Down

0 comments on commit ca5e328

Please sign in to comment.