From 2a38fee224e8eddf00444831df58648aa5ddc330 Mon Sep 17 00:00:00 2001 From: Alexander Sehr Date: Mon, 29 Jan 2024 17:53:48 +0100 Subject: [PATCH] [Utilities] Ported updated reference resolution from AVM (#4468) * Updated script * Update to latest --- modules/analysis-services/server/README.md | 4 ++-- modules/cache/redis/README.md | 4 ++-- modules/compute/disk/README.md | 4 ++-- modules/compute/image/README.md | 4 ++-- modules/consumption/budget/README.md | 4 ++-- modules/data-protection/backup-vault/README.md | 4 ++-- modules/databricks/access-connector/README.md | 4 ++-- modules/databricks/workspace/README.md | 4 ++-- modules/db-for-my-sql/flexible-server/README.md | 4 ++-- modules/health-bot/health-bot/README.md | 4 ++-- modules/net-app/net-app-account/README.md | 4 ++-- utilities/tools/Get-CrossReferencedModuleList.ps1 | 6 +++++- 12 files changed, 27 insertions(+), 23 deletions(-) diff --git a/modules/analysis-services/server/README.md b/modules/analysis-services/server/README.md index f81baf1b78..14c36419b1 100644 --- a/modules/analysis-services/server/README.md +++ b/modules/analysis-services/server/README.md @@ -1,9 +1,9 @@ # Analysis Services Servers `[Microsoft.AnalysisServices/servers]` -This module deploys an Analysis Services Server. - > This module has already been migrated to [AVM](https://github.com/Azure/bicep-registry-modules/tree/main/avm/res). Only the AVM version is expected to receive updates / new features. Please do not work on improving this module in [CARML](https://aka.ms/carml). +This module deploys an Analysis Services Server. + ## Navigation - [Resource Types](#Resource-Types) diff --git a/modules/cache/redis/README.md b/modules/cache/redis/README.md index 6eb97d5f73..dd04c79c43 100644 --- a/modules/cache/redis/README.md +++ b/modules/cache/redis/README.md @@ -1,9 +1,9 @@ # Redis Cache `[Microsoft.Cache/redis]` -This module deploys a Redis Cache. - > This module has already been migrated to [AVM](https://github.com/Azure/bicep-registry-modules/tree/main/avm/res). Only the AVM version is expected to receive updates / new features. Please do not work on improving this module in [CARML](https://aka.ms/carml). +This module deploys a Redis Cache. + ## Navigation - [Resource Types](#Resource-Types) diff --git a/modules/compute/disk/README.md b/modules/compute/disk/README.md index 27c35f709b..078ef7e2fd 100644 --- a/modules/compute/disk/README.md +++ b/modules/compute/disk/README.md @@ -1,9 +1,9 @@ # Compute Disks `[Microsoft.Compute/disks]` -This module deploys a Compute Disk. - > This module has already been migrated to [AVM](https://github.com/Azure/bicep-registry-modules/tree/main/avm/res). Only the AVM version is expected to receive updates / new features. Please do not work on improving this module in [CARML](https://aka.ms/carml). +This module deploys a Compute Disk + ## Navigation - [Resource Types](#Resource-Types) diff --git a/modules/compute/image/README.md b/modules/compute/image/README.md index 0c75030d3d..62ec79e0aa 100644 --- a/modules/compute/image/README.md +++ b/modules/compute/image/README.md @@ -1,9 +1,9 @@ # Images `[Microsoft.Compute/images]` -This module deploys a Compute Image. - > This module has already been migrated to [AVM](https://github.com/Azure/bicep-registry-modules/tree/main/avm/res). Only the AVM version is expected to receive updates / new features. Please do not work on improving this module in [CARML](https://aka.ms/carml). +This module deploys a Compute Image. + ## Navigation - [Resource Types](#Resource-Types) diff --git a/modules/consumption/budget/README.md b/modules/consumption/budget/README.md index 7d193c6b03..5d97a98433 100644 --- a/modules/consumption/budget/README.md +++ b/modules/consumption/budget/README.md @@ -1,9 +1,9 @@ # Consumption Budgets `[Microsoft.Consumption/budgets]` -This module deploys a Consumption Budget for Subscriptions. - > This module has already been migrated to [AVM](https://github.com/Azure/bicep-registry-modules/tree/main/avm/res). Only the AVM version is expected to receive updates / new features. Please do not work on improving this module in [CARML](https://aka.ms/carml). +This module deploys a Consumption Budget for Subscriptions. + ## Navigation - [Resource Types](#Resource-Types) diff --git a/modules/data-protection/backup-vault/README.md b/modules/data-protection/backup-vault/README.md index 8ea8e8f56e..d250385d99 100644 --- a/modules/data-protection/backup-vault/README.md +++ b/modules/data-protection/backup-vault/README.md @@ -1,9 +1,9 @@ # Data Protection Backup Vaults `[Microsoft.DataProtection/backupVaults]` -This module deploys a Data Protection Backup Vault. - > This module has already been migrated to [AVM](https://github.com/Azure/bicep-registry-modules/tree/main/avm/res). Only the AVM version is expected to receive updates / new features. Please do not work on improving this module in [CARML](https://aka.ms/carml). +This module deploys a Data Protection Backup Vault. + ## Navigation - [Resource Types](#Resource-Types) diff --git a/modules/databricks/access-connector/README.md b/modules/databricks/access-connector/README.md index 7b9b5997fc..fd2adfea71 100644 --- a/modules/databricks/access-connector/README.md +++ b/modules/databricks/access-connector/README.md @@ -1,9 +1,9 @@ # Azure Databricks Access Connectors `[Microsoft.Databricks/accessConnectors]` -This module deploys an Azure Databricks Access Connector. - > This module has already been migrated to [AVM](https://github.com/Azure/bicep-registry-modules/tree/main/avm/res). Only the AVM version is expected to receive updates / new features. Please do not work on improving this module in [CARML](https://aka.ms/carml). +This module deploys an Azure Databricks Access Connector. + ## Navigation - [Resource Types](#Resource-Types) diff --git a/modules/databricks/workspace/README.md b/modules/databricks/workspace/README.md index 7ecc69a38a..8591909a40 100644 --- a/modules/databricks/workspace/README.md +++ b/modules/databricks/workspace/README.md @@ -1,9 +1,9 @@ # Azure Databricks Workspaces `[Microsoft.Databricks/workspaces]` -This module deploys an Azure Databricks Workspace. - > This module has already been migrated to [AVM](https://github.com/Azure/bicep-registry-modules/tree/main/avm/res). Only the AVM version is expected to receive updates / new features. Please do not work on improving this module in [CARML](https://aka.ms/carml). +This module deploys an Azure Databricks Workspace. + ## Navigation - [Resource Types](#Resource-Types) diff --git a/modules/db-for-my-sql/flexible-server/README.md b/modules/db-for-my-sql/flexible-server/README.md index ba87654f9d..db86ab4811 100644 --- a/modules/db-for-my-sql/flexible-server/README.md +++ b/modules/db-for-my-sql/flexible-server/README.md @@ -1,9 +1,9 @@ # DBforMySQL Flexible Servers `[Microsoft.DBforMySQL/flexibleServers]` -This module deploys a DBforMySQL Flexible Server. - > This module has already been migrated to [AVM](https://github.com/Azure/bicep-registry-modules/tree/main/avm/res). Only the AVM version is expected to receive updates / new features. Please do not work on improving this module in [CARML](https://aka.ms/carml). +This module deploys a DBforMySQL Flexible Server. + ## Navigation - [Resource Types](#Resource-Types) diff --git a/modules/health-bot/health-bot/README.md b/modules/health-bot/health-bot/README.md index b3792bf2f6..5a48c03307 100644 --- a/modules/health-bot/health-bot/README.md +++ b/modules/health-bot/health-bot/README.md @@ -1,9 +1,9 @@ # Azure Health Bots `[Microsoft.HealthBot/healthBots]` -This module deploys an Azure Health Bot. - > This module has already been migrated to [AVM](https://github.com/Azure/bicep-registry-modules/tree/main/avm/res). Only the AVM version is expected to receive updates / new features. Please do not work on improving this module in [CARML](https://aka.ms/carml). +This module deploys an Azure Health Bot. + ## Navigation - [Resource Types](#Resource-Types) diff --git a/modules/net-app/net-app-account/README.md b/modules/net-app/net-app-account/README.md index 66ae04e1b7..c2bc9668f6 100644 --- a/modules/net-app/net-app-account/README.md +++ b/modules/net-app/net-app-account/README.md @@ -1,9 +1,9 @@ # Azure NetApp Files `[Microsoft.NetApp/netAppAccounts]` -This module deploys an Azure NetApp File. - > This module has already been migrated to [AVM](https://github.com/Azure/bicep-registry-modules/tree/main/avm/res). Only the AVM version is expected to receive updates / new features. Please do not work on improving this module in [CARML](https://aka.ms/carml). +This module deploys an Azure NetApp File. + ## Navigation - [Resource Types](#Resource-Types) diff --git a/utilities/tools/Get-CrossReferencedModuleList.ps1 b/utilities/tools/Get-CrossReferencedModuleList.ps1 index 5971dd9dc9..ef13dd7ddc 100644 --- a/utilities/tools/Get-CrossReferencedModuleList.ps1 +++ b/utilities/tools/Get-CrossReferencedModuleList.ps1 @@ -156,7 +156,11 @@ function Get-CrossReferencedModuleList { $resultSet = [ordered]@{} # Collect data - $moduleTemplatePaths = (Get-ChildItem -Path $path -Recurse -File -Filter 'main.bicep').FullName + $moduleTemplatePaths = (Get-ChildItem -Path $path -Recurse -File -Filter '*.bicep').FullName | Where-Object { + # No files in the [/utilities/tools/] folder and none in the [/tests/] folder + $_ -notmatch '.*[\\|\/]tools[\\|\/].*|.*[\\|\/]tests[\\|\/].*' + } | Sort-Object + $templateMap = @{} foreach ($moduleTemplatePath in $moduleTemplatePaths) { $templateMap[$moduleTemplatePath] = Get-Content -Path $moduleTemplatePath