-
Notifications
You must be signed in to change notification settings - Fork 30
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #746 from aws/dev
ci: doc generator step was failing to push if there are no changes
- Loading branch information
Showing
1 changed file
with
9 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -40,7 +40,16 @@ jobs: | |
run: | | ||
cd ./src/AWS.Deploy.DocGenerator | ||
dotnet run --project ./AWS.Deploy.DocGenerator.csproj | ||
- name: Check For Git Untracked Changes | ||
id: gitcheck | ||
shell: pwsh | ||
run: | | ||
$newFiles=$(git ls-files --others --exclude-standard | wc -l) | ||
$modifiedFiles=$(git diff --name-only | wc -l) | ||
"newFiles=$newFiles" >> $env:GITHUB_OUTPUT | ||
"modifiedFiles=$modifiedFiles" >> $env:GITHUB_OUTPUT | ||
- name: Commit and Push next version | ||
if: steps.gitcheck.outputs.newFiles != 0 || steps.gitcheck.outputs.modifiedFiles != 0 | ||
id: commit-push | ||
run: | | ||
git config --global user.email "[email protected]" | ||
|