Skip to content

Commit

Permalink
Improvements to dependency graph (#20191)
Browse files Browse the repository at this point in the history
  • Loading branch information
chidozieononiwu authored Feb 5, 2022
1 parent 0c18037 commit 758f0c8
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 7 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Azure SDK for JavaScript

[![Packages](https://img.shields.io/badge/packages-latest-blue.svg)](https://azure.github.io/azure-sdk/releases/latest/js.html) [![Dependencies](https://img.shields.io/badge/dependency-report-blue.svg)](https://azuresdkartifacts.blob.core.windows.net/azure-sdk-for-js/dependencies/dependencies.html) [![DependencyGraph](https://img.shields.io/badge/dependency-graph-blue.svg)](https://azuresdkartifacts.blob.core.windows.net/azure-sdk-for-js/dependencies/InterdependencyGraph.html)
[![Packages](https://img.shields.io/badge/packages-latest-blue.svg)](https://azure.github.io/azure-sdk/releases/latest/js.html) [![Dependencies](https://img.shields.io/badge/dependency-report-blue.svg)](https://azuresdkartifacts.blob.core.windows.net/azure-sdk-for-js/dependencies/dependencies.html) [![DependencyGraph](https://img.shields.io/badge/dependency-graph-blue.svg)](https://azuresdkartifacts.blob.core.windows.net/azure-sdk-for-js/dependencies/dependencyGraph/dagre.html)

This repository is for the Azure SDK for JavaScript (Node.js & Browser). It contains libraries for the breadth of Azure services. Management libraries are packages that you would use to provision and manage Azure resources. Client libraries are packages that you would use to consume these resources and interact with them.

Expand Down Expand Up @@ -58,7 +58,7 @@ Security issues and bugs should be reported privately, via email, to the Microso
For details on contributing to this repository, see the [contributing guide](https://github.com/Azure/azure-sdk-for-js/blob/main/CONTRIBUTING.md).

This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit
https://cla.microsoft.com.
<https://cla.microsoft.com>.

When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repositories using our CLA.

Expand Down
20 changes: 16 additions & 4 deletions eng/pipelines/aggregate-reports.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,23 +45,35 @@ stages:
displayName: 'Install tool dependencies'

- script: |
node index.js --verbose --out "$(Build.ArtifactStagingDirectory)/dependencies.html" --dump "$(Build.ArtifactStagingDirectory)/data.js"
node index.js --verbose --out "$(Build.ArtifactStagingDirectory)/dependencies.html" --dump "$(Build.ArtifactStagingDirectory)"
workingDirectory: '$(Build.SourcesDirectory)/eng/tools/analyze-deps'
displayName: 'Validate dependencies'
- pwsh: |
copy eng/common/InterdependencyGraph.html $(Build.ArtifactStagingDirectory)
displayName: 'Copy static file'
- task: AzureFileCopy@3
displayName: 'Upload dependency report'
- task: AzureFileCopy@4
displayName: 'Upload Dependency Report'
inputs:
sourcePath: '$(Build.ArtifactStagingDirectory)'
sourcePath: '$(Build.ArtifactStagingDirectory)/*'
azureSubscription: 'Azure SDK Artifacts'
destination: AzureBlob
storage: azuresdkartifacts
containerName: 'azure-sdk-for-js'
blobPrefix: dependencies
AdditionalArgumentsForBlobCopy: '--exclude-pattern=*data.js*'

- task: AzureFileCopy@4
displayName: 'Upload Dependency Graph'
inputs:
sourcePath: '$(Build.ArtifactStagingDirectory)/*'
azureSubscription: 'Azure SDK Artifacts'
destination: AzureBlob
storage: azuresdkartifacts
containerName: 'azure-sdk-for-js'
blobPrefix: dependencies/dependencyGraph
AdditionalArgumentsForBlobCopy: '--include-pattern=*data.js*'

- task: PowerShell@2
displayName: "Verify Repository Resource Refs"
Expand Down
3 changes: 2 additions & 1 deletion eng/tools/analyze-deps/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,8 @@ const main = async () => {
for (const pkgId of Object.keys(dumpData)) {
resolveRushPackageDeps(dumpData, internalPackages, pnpmLock, pkgId, args.external);
}
await writeFile(args.dump, "const data = " + JSON.stringify(dumpData) + ";");
await writeFile(`${args.dump}/data.js`, "const data = " + JSON.stringify(dumpData) + ";");
await writeFile(`${args.dump}/arcdata.json`, JSON.stringify(dumpData));
}
}
catch (ex) {
Expand Down

0 comments on commit 758f0c8

Please sign in to comment.