You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
## Support incremental builds
### TODO
- [x] Add release notes
- [x] Add settings docs
- [x] Add end 2 end tests
- [x] Fix existing CI tests
### Use git diff instead of API
In v6.1 and earlier versions, we use the GitHub API to determine last
known good build and determine modified files in the Pull Request. It is
however possible to have done modifications to the main branch after the
last known good build - the changes will not be included in the PR and
this the PR builds will only include the modified files in the PR
together with the last known good build - potentially missing files.
This version locates the SHA, which was used to build the last known
good build and uses git diff to determine all changes from that build
including the changes in the PR to build what's needed.
git diff also supports many more files than the API, is faster and it
doesn't count as API calls against the GitHub limit.
### Changed <workflow>Schedule to workflowSchedule
Instead of using dynamic setting key name - use a workflow specific
setting and deprecate the old keys.
### Add concurrency protection to workflows
Add new workflow specific setting called - workflowConcurrency. It is
used to control concurrency of workflows.
Like with the `WorkflowSchedule` setting, this setting should be applied
in workflow specific settings files or conditional settings. By default,
all workflows allows for concurrency, except for the Create Release
workflow. If you are using incremental builds in CI/CD it is also
recommented to set WorkflowConcurrency to:
```
[
"group: ${{ github.workflow }}-${{ github.ref }}",
"cancel-in-progress: true"
]
```
in order to cancel prior incremental builds on the same branch.
Read more about workflow concurrency
[here](https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/control-the-concurrency-of-workflows-and-jobs).
### Remove warnings that tests doesn't exist if doNotBuildTests is true
No reason to warn about missing test apps if you don't want to build
them anyway
### Remove warnings and error when locating previous builds
Getting rid of warnings like this:

due to DownloadProjectDependencies downloads artifacts double
and errors like:

if there wasn't a successful build in the repo.
### Check whether a package has been delivered to GitHubPackages or
NuGet before delivering
If the package already exists in the current version it has already been
delivered (might be from an earlier build)
---------
Co-authored-by: freddydk <[email protected]>
Co-authored-by: Maria Zhelezova <[email protected]>
Copy file name to clipboardExpand all lines: Actions/AL-Go-TestRepoHelper.ps1
+25-7Lines changed: 25 additions & 7 deletions
Original file line number
Diff line number
Diff line change
@@ -43,6 +43,23 @@ function Test-Shell {
43
43
}
44
44
}
45
45
46
+
functionTest-Deprecations {
47
+
Param(
48
+
[HashTable] $json,
49
+
[string] $settingsDescription
50
+
)
51
+
52
+
# cleanModePreprocessorSymbols is deprecated
53
+
if ($json.Keys-contains'cleanModePreprocessorSymbols') {
54
+
OutputWarning -Message "cleanModePreprocessorSymbols in $settingsDescription is deprecated. See https://aka.ms/algodeprecations#cleanModePreprocessorSymbols"
OutputWarning -Message "$_ in $settingsDescription is deprecated. See https://aka.ms/algodeprecations#_workflow_Schedule. This warning will become an error in the future."
if ($repoSettings.Keys-contains$key-and ($repoSettings."$key")) {
318
+
throw"The $key setting is not allowed in the global repository settings. Please use the workflow specific settings file or conditional settings."
319
+
}
320
+
}
307
321
308
-
# Any workflow (except for the PullRequestHandler and reusable workflows (_*)) can have a RepoSetting called <workflowname>Schedule, which will be used to set the schedule for the workflow
322
+
# Re-read settings and this time include workflow specific settings
# Old Schedule key is deprecated, but still supported
326
+
$oldWorkflowScheduleKey="$($baseName)Schedule"
327
+
if ($repoSettings.Keys-contains$oldWorkflowScheduleKey) {
328
+
# DEPRECATION: REPLACE WITH ERROR AFTER October 1st 2025 --->
329
+
if ($repoSettings.Keys-contains$workflowScheduleKey) {
330
+
OutputWarning "Both $oldWorkflowScheduleKey and $workflowScheduleKey are defined in the settings file. $oldWorkflowScheduleKey will be ignored. This warning will become an error in the future"
331
+
}
332
+
else {
333
+
Trace-DeprecationWarning-Message "$oldWorkflowScheduleKey is deprecated"-DeprecationTag "_workflow_Schedule"-WillBecomeError
334
+
# Convert the old <workflow>Schedule setting to the new WorkflowSchedule setting
0 commit comments