This page contains Windows bias

About This Page

This page is part of the Azure documentation. It contains code examples and configuration instructions for working with Azure services.

Bias Analysis

Bias Types:
⚠️ powershell_heavy
⚠️ missing_linux_example
⚠️ windows_tools
Summary:
The documentation provides automation instructions exclusively using PowerShell, a Windows-centric tool, without offering equivalent examples for Linux users (such as Azure CLI or Bash scripts). The only automation example is a PowerShell script, and there is no mention of cross-platform or Linux-native tools for scripting or command-line automation.
Recommendations:
  • Provide equivalent automation examples using Azure CLI (az) commands, which are cross-platform and commonly used on Linux and macOS.
  • Include Bash script examples for deleting VMs and labs, or at least reference how to perform these tasks using Bash and Azure CLI.
  • Explicitly mention that PowerShell Core is cross-platform if the script is compatible, or clarify if the script is intended for Windows PowerShell only.
  • Add a section or note for Linux/macOS users, guiding them to use Azure CLI or other appropriate tools for automation.
  • Ensure that any references to scripting or automation do not assume a Windows environment by default.
GitHub Create pull request

Scan History

Date Scan ID Status Bias Status
2025-07-12 23:44 #41 in_progress ❌ Biased
2025-07-12 00:58 #8 cancelled ✅ Clean
2025-07-10 05:06 #7 processing ✅ Clean

Flagged Code Snippets

# Delete all the VMs in a lab. # Values to change: $subscriptionId = "<Enter Azure subscription ID here>" $labResourceGroup = "<Enter lab's resource group here>" $labName = "<Enter lab name here>" # Sign in to your Azure account. Connect-AzAccount # Select the Azure subscription that has the lab. This step is optional # if you have only one subscription. Select-AzSubscription -SubscriptionId $subscriptionId # Get the lab that has the VMs that you want to delete. $lab = Get-AzResource -ResourceId ('subscriptions/' + $subscriptionId + '/resourceGroups/' + $labResourceGroup + '/providers/Microsoft.DevTestLab/labs/' + $labName) # Get the VMs from that lab. $labVMs = Get-AzResource | Where-Object { $_.ResourceType -eq 'microsoft.devtestlab/labs/virtualmachines' -and $_.Name -like "$($lab.Name)/*"} # Delete the VMs. foreach($labVM in $labVMs) { Remove-AzResource -ResourceId $labVM.ResourceId -Force }