content
stringlengths
1
103k
path
stringlengths
8
216
filename
stringlengths
2
179
language
stringclasses
15 values
size_bytes
int64
2
189k
quality_score
float64
0.5
0.95
complexity
float64
0
1
documentation_ratio
float64
0
1
repository
stringclasses
5 values
stars
int64
0
1k
created_date
stringdate
2023-07-10 19:21:08
2025-07-09 19:11:45
license
stringclasses
4 values
is_test
bool
2 classes
file_hash
stringlengths
32
32
trigger: none\n\nparameters: # parameters are shown up in ADO UI in a build queue time\n - name: 'debug'\n displayName: 'Enable debug output'\n type: boolean\n default: false\n - name: InternalSDKBlobURL\n displayName: URL to the blob having internal .NET SDK\n type: string\n default: ' '\n - name: ReleaseTagVar\n displayName: Release Tag\n type: string\n default: 'fromBranch'\n - name: SKIP_SIGNING\n displayName: Skip Signing\n type: string\n default: 'NO'\n - name: SkipPublish\n displayName: Skip Publishing to GitHub and Nuget\n type: boolean\n default: false\n - name: SkipPSInfraInstallers\n displayName: Skip Copying Archives and Installers to PSInfrastructure Public Location\n type: boolean\n default: false\n\nname: release-$(BUILD.SOURCEBRANCHNAME)-$(Build.BuildId)\n\nvariables:\n - name: CDP_DEFINITION_BUILD_COUNT\n value: $[counter('', 0)]\n - name: system.debug\n value: ${{ parameters.debug }}\n - name: ENABLE_PRS_DELAYSIGN\n value: 1\n - name: ROOT\n value: $(Build.SourcesDirectory)\n - name: REPOROOT\n value: $(Build.SourcesDirectory)\n - name: OUTPUTROOT\n value: $(REPOROOT)\out\n - name: NUGET_XMLDOC_MODE\n value: none\n - name: nugetMultiFeedWarnLevel\n value: none\n - name: NugetSecurityAnalysisWarningLevel\n value: none\n - name: skipNugetSecurityAnalysis\n value: true\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: WindowsContainerImage\n value: 'onebranch.azurecr.io/windows/ltsc2022/vse2022:latest'\n - name: LinuxContainerImage\n value: mcr.microsoft.com/onebranch/cbl-mariner/build:2.0\n - name: ReleaseTagVar\n value: ${{ parameters.ReleaseTagVar }}\n - group: PoolNames\n - group: MSIXSigningProfile\n\nresources:\n repositories:\n - repository: templates\n type: git\n name: OneBranch.Pipelines/GovernedTemplates\n ref: refs/heads/main\n - repository: PSInternalTools\n type: git\n name: PowerShellCore/Internal-PowerShellTeam-Tools\n ref: refs/heads/master\n\n pipelines:\n - pipeline: CoOrdinatedBuildPipeline\n source: 'PowerShell-Coordinated Binaries-Official'\n\n - pipeline: PSPackagesOfficial\n source: 'PowerShell-Packages-Official'\n trigger:\n branches:\n include:\n - master\n - releases/*\n\nextends:\n template: v2/OneBranch.Official.CrossPlat.yml@templates\n parameters:\n release: \n category: NonAzure\n featureFlags:\n WindowsHostVersion:\n Version: 2022\n Network: KS3\n cloudvault:\n enabled: false\n globalSdl:\n disableLegacyManifest: true\n # disabled Armory as we dont have any ARM templates to scan. It fails on some sample ARM templates.\n armory:\n enabled: false\n asyncSdl:\n enabled: true\n tsaOptionsFile: .config/tsaoptions.json\n tsa:\n enabled: true\n credscan:\n enabled: true\n scanFolder: $(Build.SourcesDirectory)\n suppressionsFile: $(Build.SourcesDirectory)\.config\suppress.json\n binskim:\n break: false # always break the build on binskim issues in addition to TSA upload\n policheck:\n break: true # always break the build on policheck issues. You can disable it by setting to 'false'\n # suppression:\n # suppressionFile: $(Build.SourcesDirectory)\.gdn\global.gdnsuppress\n tsaOptionsFile: .config\tsaoptions.json\n\n stages:\n - stage: setReleaseTagAndChangelog\n displayName: 'Set Release Tag and Upload Changelog'\n jobs:\n - template: /.pipelines/templates/release-SetTagAndChangelog.yml@self\n\n - stage: msixbundle\n displayName: 'Create MSIX Bundle'\n dependsOn: []\n jobs:\n - template: /.pipelines/templates/release-create-msix.yml@self\n\n - stage: validateSdk\n displayName: 'Validate SDK'\n dependsOn: []\n jobs:\n - template: /.pipelines/templates/release-validate-sdk.yml@self\n parameters:\n jobName: "windowsSDK"\n displayName: "Windows SDK Validation"\n imageName: PSMMS2019-Secure\n poolName: $(windowsPool)\n\n - template: /.pipelines/templates/release-validate-sdk.yml@self\n parameters:\n jobName: "MacOSSDK"\n displayName: "MacOS SDK Validation"\n imageName: macOS-latest\n poolName: Azure Pipelines\n\n - template: /.pipelines/templates/release-validate-sdk.yml@self\n parameters:\n jobName: "LinuxSDK"\n displayName: "Linux SDK Validation"\n imageName: PSMMSUbuntu20.04-Secure\n poolName: $(ubuntuPool)\n\n - stage: gbltool\n displayName: 'Validate Global tools'\n dependsOn: []\n jobs:\n - template: /.pipelines/templates/release-validate-globaltools.yml@self\n parameters:\n jobName: "WindowsGlobalTools"\n displayName: "Windows Global Tools Validation"\n jobtype: windows\n\n - template: /.pipelines/templates/release-validate-globaltools.yml@self\n parameters:\n jobName: "LinuxGlobalTools"\n displayName: "Linux Global Tools Validation"\n jobtype: linux\n globalToolExeName: 'pwsh'\n globalToolPackageName: 'PowerShell.Linux.x64'\n\n - stage: fxdpackages\n displayName: 'Validate FXD Packages'\n dependsOn: []\n jobs:\n - template: /.pipelines/templates/release-validate-fxdpackages.yml@self\n parameters:\n jobName: 'winfxd'\n displayName: 'Validate Win Fxd Packages'\n jobtype: 'windows'\n artifactName: 'drop_windows_package_package_win_fxdependent'\n packageNamePattern: '**/*win-fxdependent.zip'\n\n - template: /.pipelines/templates/release-validate-fxdpackages.yml@self\n parameters:\n jobName: 'winfxdDesktop'\n displayName: 'Validate WinDesktop Fxd Packages'\n jobtype: 'windows'\n artifactName: 'drop_windows_package_package_win_fxdependentWinDesktop'\n packageNamePattern: '**/*win-fxdependentwinDesktop.zip'\n\n - template: /.pipelines/templates/release-validate-fxdpackages.yml@self\n parameters:\n jobName: 'linuxfxd'\n displayName: 'Validate Linux Fxd Packages'\n jobtype: 'linux'\n artifactName: 'drop_linux_package_fxdependent'\n packageNamePattern: '**/*linux-x64-fxdependent.tar.gz'\n\n - template: /.pipelines/templates/release-validate-fxdpackages.yml@self\n parameters:\n jobName: 'linuxArm64fxd'\n displayName: 'Validate Linux ARM64 Fxd Packages'\n jobtype: 'linux'\n artifactName: 'drop_linux_package_fxdependent'\n # this is really an architecture independent package\n packageNamePattern: '**/*linux-x64-fxdependent.tar.gz'\n arm64: 'yes'\n enableCredScan: false\n\n - stage: validatePackages\n displayName: 'Validate Packages'\n dependsOn: []\n jobs:\n - template: /.pipelines/templates/release-validate-packagenames.yml@self\n\n - stage: ManualValidation\n dependsOn: []\n displayName: Manual Validation\n jobs:\n - template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Validate Windows Packages\n jobName: ValidateWinPkg\n instructions: |\n Validate zip package on windows\n\n - template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Validate OSX Packages\n jobName: ValidateOsxPkg\n instructions: |\n Validate tar.gz package on osx-arm64\n\n - stage: ReleaseAutomation\n dependsOn: []\n displayName: 'Release Automation'\n jobs:\n - template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Start Release Automation\n jobName: StartRA\n instructions: |\n Kick off Release automation build at: https://dev.azure.com/powershell-rel/Release-Automation/_build?definitionId=10&_a=summary\n\n - template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Triage results\n jobName: TriageRA\n dependsOnJob: StartRA\n instructions: |\n Triage ReleaseAutomation results\n\n - template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Signoff Tests\n dependsOnJob: TriageRA\n jobName: SignoffTests\n instructions: |\n Signoff ReleaseAutomation results\n\n - stage: UpdateChangeLog\n displayName: Update the changelog\n dependsOn:\n - ManualValidation\n - ReleaseAutomation\n - validatePackages\n - fxdpackages\n - gbltool\n - validateSdk\n - msixbundle\n\n jobs:\n - template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Make sure the changelog is updated\n jobName: MergeChangeLog\n instructions: |\n Update and merge the changelog for the release.\n This step is required for creating GitHub draft release.\n\n - stage: PublishGitHubReleaseAndNuget\n displayName: Publish GitHub and Nuget Release\n dependsOn: \n - setReleaseTagAndChangelog\n - UpdateChangeLog\n variables:\n ob_release_environment: Production\n jobs:\n - template: /.pipelines/templates/release-githubNuget.yml@self\n parameters:\n skipPublish: ${{ parameters.SkipPublish }}\n\n - stage: PushGitTagAndMakeDraftPublic\n displayName: Push Git Tag and Make Draft Public\n dependsOn: PublishGitHubReleaseAndNuget\n jobs:\n - template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Push Git Tag\n jobName: PushGitTag\n instructions: |\n Push the git tag to upstream \n \n - template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Make Draft Public\n dependsOnJob: PushGitTag\n jobName: DraftPublic\n instructions: |\n Make the GitHub Release Draft Public\n \n - stage: BlobPublic\n displayName: Make Blob Public\n dependsOn: \n - UpdateChangeLog\n - PushGitTagAndMakeDraftPublic\n jobs:\n - template: /.pipelines/templates/release-MakeBlobPublic.yml@self\n parameters:\n SkipPSInfraInstallers: ${{ parameters.SkipPSInfraInstallers }}\n\n - stage: PublishPMC\n displayName: Publish PMC\n dependsOn: PushGitTagAndMakeDraftPublic\n jobs:\n - template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Publish to PMC\n jobName: ReleaseToPMC\n instructions: |\n Run PowerShell-Release-Official-Azure.yml pipeline to publish to PMC\n\n - stage: ReleaseDocker\n dependsOn: PushGitTagAndMakeDraftPublic\n displayName: 'Docker Release'\n jobs:\n - template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Start Docker Release\n jobName: StartDockerRelease\n instructions: |\n Kickoff docker release\n\n - stage: UpdateDotnetDocker\n dependsOn: PushGitTagAndMakeDraftPublic\n displayName: Update DotNet SDK Docker images\n jobs:\n - template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Update .NET SDK docker images\n jobName: DotnetDocker\n instructions: |\n Create PR for updating dotnet-docker images to use latest PowerShell version.\n 1. Fork and clone https://github.com/dotnet/dotnet-docker.git\n 2. git checkout upstream/nightly -b updatePS\n 3. dotnet run --project .\eng\update-dependencies\ -- <dotnetversion> --product-version powershell=<powershellversion> --compute-shas\n 4. create PR targeting nightly branch\n\n - stage: UpdateWinGet\n dependsOn: PushGitTagAndMakeDraftPublic\n displayName: Add manifest entry to winget\n jobs:\n - template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Add manifest entry to winget\n jobName: UpdateWinGet\n instructions: |\n This is typically done by the community 1-2 days after the release.\n\n - stage: PublishMsix\n dependsOn: PushGitTagAndMakeDraftPublic\n displayName: Publish MSIX to store\n jobs:\n - template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Publish the MSIX Bundle package to store\n jobName: PublishMsix\n instructions: |\n Ask Steve to release MSIX bundle package to Store\n\n - stage: PublishVPack\n dependsOn: PushGitTagAndMakeDraftPublic\n displayName: Release vPack\n jobs:\n - template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Start vPack Release pipeline\n jobName: PublishVPack\n instructions: |\n Kick off vPack release pipeline\n\n # Need to verify if the Az PS / CLI team still uses this. Skippinng for this release.\n # - stage: ReleaseDeps\n # dependsOn: GitHubTasks\n # displayName: Update pwsh.deps.json links\n # jobs:\n # - template: templates/release-UpdateDepsJson.yml\n\n - stage: UploadBuildInfoJson\n dependsOn: PushGitTagAndMakeDraftPublic\n displayName: Upload BuildInfo.json\n jobs:\n - template: /.pipelines/templates/release-upload-buildinfo.yml@self\n\n - stage: ReleaseSymbols\n dependsOn: PushGitTagAndMakeDraftPublic\n displayName: Release Symbols\n jobs:\n - template: /.pipelines/templates/release-symbols.yml@self\n\n - stage: ChangesToMaster\n displayName: Ensure changes are in GH master\n dependsOn: \n - PublishPMC\n jobs:\n - template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Make sure changes are in master\n jobName: MergeToMaster\n instructions: |\n Make sure that changes README.md and metadata.json are merged into master on GitHub.\n\n - stage: ReleaseToMU\n displayName: Release to MU\n dependsOn: PushGitTagAndMakeDraftPublic # This only needs the blob to be available\n jobs:\n - template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Release to MU\n instructions: |\n Notify the PM team to start the process of releasing to MU.\n\n - stage: ReleaseClose\n displayName: Finish Release\n dependsOn: \n - ReleaseToMU\n - ReleaseSymbols\n jobs:\n - template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Retain Build\n jobName: RetainBuild\n instructions: |\n Retain the build\n\n - template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Delete release branch\n jobName: DeleteBranch\n instructions: |\n Delete release\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\PowerShell-Release-Official.yml
PowerShell-Release-Official.yml
YAML
15,083
0.95
0.011013
0.024331
python-kit
165
2024-12-30T02:31:29.460605
BSD-3-Clause
false
b9439d794b99f09a4dbf2dec2ebca6b7
trigger: none\n\nparameters: # parameters are shown up in ADO UI in a build queue time\n- name: 'createVPack'\n displayName: 'Create and Submit VPack'\n type: boolean\n default: true\n- name: 'debug'\n displayName: 'Enable debug output'\n type: boolean\n default: false\n- name: 'architecture'\n type: string\n displayName: 'Select the vpack architecture:'\n values:\n - x64\n - x86\n - arm64\n default: x64\n- name: 'VPackPublishOverride'\n type: string\n displayName: 'VPack Publish Override Version (can leave blank):'\n default: ' '\n- name: 'ReleaseTagVar'\n type: string\n displayName: 'Release Tag Var:'\n default: 'fromBranch'\n\nname: vPack_${{ parameters.architecture }}_$(date:yyMM).$(date:dd)$(rev:rrr)\n\nvariables:\n - name: CDP_DEFINITION_BUILD_COUNT\n value: $[counter('', 0)]\n - name: system.debug\n value: ${{ parameters.debug }}\n - name: BuildSolution\n value: $(Build.SourcesDirectory)\dirs.proj\n - name: BuildConfiguration\n value: Release\n - name: WindowsContainerImage\n value: 'onebranch.azurecr.io/windows/ltsc2019/vse2022:latest'\n - name: Codeql.Enabled\n value: false # pipeline is not building artifacts; it repackages existing artifacts into a vpack\n - name: DOTNET_CLI_TELEMETRY_OPTOUT\n value: 1\n - name: POWERSHELL_TELEMETRY_OPTOUT\n value: 1\n - name: nugetMultiFeedWarnLevel\n value: none\n - name: ReleaseTagVar\n value: ${{ parameters.ReleaseTagVar }}\n - group: Azure Blob variable group\n - group: certificate_logical_to_actual # used within signing task\n\nresources:\n repositories:\n - repository: templates\n type: git\n name: OneBranch.Pipelines/GovernedTemplates\n ref: refs/heads/main\n\n pipelines:\n - pipeline: PSPackagesOfficial\n source: 'PowerShell-Packages-Official'\n trigger:\n branches:\n include:\n - master\n - releases/*\n\nextends:\n template: v2/Microsoft.Official.yml@templates\n parameters:\n platform:\n name: 'windows_undocked' # windows undocked\n\n cloudvault:\n enabled: false\n\n globalSdl:\n useCustomPolicy: true # for signing code\n disableLegacyManifest: true\n # disabled Armory as we dont have any ARM templates to scan. It fails on some sample ARM templates.\n armory:\n enabled: false\n sbom:\n enabled: true\n compiled:\n enabled: false\n credscan:\n enabled: true\n scanFolder: $(Build.SourcesDirectory)\n suppressionsFile: $(Build.SourcesDirectory)\.config\suppress.json\n binskim:\n enabled: false\n # APIScan requires a non-Ready-To-Run build\n apiscan:\n enabled: false\n asyncSDL:\n enabled: false\n tsaOptionsFile: .config/tsaoptions.json\n stages:\n - stage: main\n jobs:\n - job: main\n pool:\n type: windows\n\n variables:\n ob_outputDirectory: '$(BUILD.SOURCESDIRECTORY)\out'\n ob_createvpack_enabled: ${{ parameters.createVPack }}\n ob_createvpack_packagename: 'PowerShell.${{ parameters.architecture }}'\n ob_createvpack_description: PowerShell ${{ parameters.architecture }} $(version)\n ob_createvpack_owneralias: tplunk\n ob_createvpack_versionAs: string\n ob_createvpack_version: '$(version)'\n ob_createvpack_propsFile: true\n ob_createvpack_verbose: true\n\n steps:\n - template: tools/releaseBuild/azureDevOps/templates/SetVersionVariables.yml@self\n parameters:\n ReleaseTagVar: $(ReleaseTagVar)\n CreateJson: yes\n UseJson: no\n\n - pwsh: |\n if($env:RELEASETAGVAR -match '-') {\n throw "Don't release a preview build without coordinating with Windows Engineering Build Tools Team"\n }\n displayName: Stop any preview release\n\n - task: UseDotNet@2\n displayName: 'Use .NET Core sdk'\n inputs:\n packageType: sdk\n version: 3.1.x\n installationPath: $(Agent.ToolsDirectory)/dotnet\n\n - pwsh: |\n $packageArtifactName = 'drop_windows_package_package_win_${{ parameters.architecture }}'\n $vstsCommandString = "vso[task.setvariable variable=PackageArtifactName]$packageArtifactName"\n Write-Host "sending " + $vstsCommandString\n Write-Host "##$vstsCommandString"\n\n $packageArtifactPath = '$(Pipeline.Workspace)\PSPackagesOfficial'\n $vstsCommandString = "vso[task.setvariable variable=PackageArtifactPath]$packageArtifactPath"\n Write-Host "sending " + $vstsCommandString\n Write-Host "##$vstsCommandString"\n displayName: 'Set package artifact variables'\n\n - download: PSPackagesOfficial\n artifact: $(PackageArtifactName)\n displayName: Download package\n\n - pwsh: 'Get-ChildItem $(PackageArtifactPath)\* -recurse | Select-Object -ExpandProperty Name'\n displayName: 'Capture Artifact Listing'\n\n - pwsh: |\n $message = @()\n $packages = Get-ChildItem $(PackageArtifactPath)\* -recurse -include *.zip, *.msi\n\n if($packages.count -eq 0) {throw "No packages found in $(PackageArtifactPath)"}\n\n $packages | ForEach-Object {\n if($_.Name -notmatch 'PowerShell-\d+\.\d+\.\d+\-([a-z]*.\d+\-)?win\-(fxdependent|x64|arm64|x86|fxdependentWinDesktop)\.(msi|zip){1}')\n {\n $messageInstance = "$($_.Name) is not a valid package name"\n $message += $messageInstance\n Write-Warning $messageInstance\n }\n }\n\n if($message.count -gt 0){throw ($message | out-string)}\n displayName: 'Validate Zip and MSI Package Names'\n\n - pwsh: |\n Get-ChildItem $(PackageArtifactPath)\* -recurse -include *.zip | ForEach-Object {\n if($_.Name -match 'PowerShell-\d+\.\d+\.\d+\-([a-z]*.\d+\-)?win\-(${{ parameters.architecture }})\.(zip){1}')\n {\n Expand-Archive -Path $_.FullName -DestinationPath $(ob_outputDirectory)\n }\n }\n displayName: 'Extract Zip to ob_outputDirectory'\n\n - pwsh: |\n Write-Verbose "VPack Version: $(ob_createvpack_version)" -Verbose\n Get-ChildItem -Path $(ob_outputDirectory)\* -Recurse\n Get-Content $(ob_outputdirectory)\preview.json -ErrorAction SilentlyContinue | Write-Host\n displayName: Debug Output Directory and Version\n condition: succeededOrFailed()\n\n - pwsh: |\n Write-Host "Using VPackPublishOverride variable"\n $vpackVersion = '${{ parameters.VPackPublishOverride }}'\n $vstsCommandString = "vso[task.setvariable variable=ob_createvpack_version]$vpackVersion"\n Write-Host "sending " + $vstsCommandString\n Write-Host "##$vstsCommandString"\n condition: ne('${{ parameters.VPackPublishOverride }}', ' ')\n displayName: 'Set ob_createvpack_version with VPackPublishOverride'\n\n - pwsh: |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture Environment\n condition: succeededOrFailed()\n\n - pwsh: |\n Write-Verbose "VPack Version: $(ob_createvpack_version)" -Verbose\n $vpackFiles = Get-ChildItem -Path $(ob_outputDirectory)\* -Recurse\n if($vpackFiles.Count -eq 0) {\n throw "No files found in $(ob_outputDirectory)"\n }\n $vpackFiles\n displayName: Debug Output Directory and Version\n condition: succeededOrFailed()\n\n - task: onebranch.pipeline.signing@1\n displayName: 'Onebranch Signing'\n inputs:\n command: 'sign'\n signing_environment: 'azure-ado'\n cp_code: $(windows_build_tools_cert_id)\n files_to_sign: '**/*.exe;**/System.Management.Automation.dll'\n search_root: $(ob_outputDirectory)\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\PowerShell-vPack-Official.yml
PowerShell-vPack-Official.yml
YAML
8,209
0.95
0.03125
0.010101
vue-tools
325
2023-10-04T07:30:18.658950
BSD-3-Clause
false
17742fcefc48754b8cfe58811576b064
parameters:\n - name: displayName\n type: string\n - name: instructions\n type: string\n - name: jobName\n type: string\n default: approval\n - name: timeoutInMinutes\n type: number\n # 2 days\n default: 2880\n - name: onTimeout\n type: string\n default: 'reject'\n values:\n - resume\n - reject\n - name: dependsOnJob\n type: string\n default: ''\n\njobs:\n - job: ${{ parameters.jobName }}\n dependsOn: ${{ parameters.dependsOnJob }}\n displayName: ${{ parameters.displayName }}\n pool:\n type: agentless\n timeoutInMinutes: 4320 # job times out in 3 days\n steps:\n - task: ManualValidation@0\n displayName: ${{ parameters.displayName }}\n timeoutInMinutes: ${{ parameters.timeoutInMinutes }}\n inputs:\n instructions: ${{ parameters.instructions }}\n onTimeout: ${{ parameters.onTimeout }}\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\approvalJob.yml
approvalJob.yml
YAML
868
0.8
0
0.028571
react-lib
90
2025-02-09T18:56:43.302855
GPL-3.0
false
0fd799c387c5d5ff8dd908d818529a58
jobs:\n- job: DeleteBlob\n variables:\n - group: Azure Blob variable group\n - group: AzureBlobServiceConnection\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT/BuildJson'\n - name: ob_sdl_sbom_enabled\n value: false\n - name: ob_sdl_codeSignValidation_enabled\n value: false\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n - name: ob_sdl_codeql_compiled_enabled\n value: false\n\n displayName: Delete blob is exists\n pool:\n type: windows\n steps:\n - checkout: self\n clean: true\n env:\n ob_restore_phase: true # This ensures checkout is done at the beginning of the restore phase\n\n - template: /.pipelines/templates/SetVersionVariables.yml@self\n parameters:\n ReleaseTagVar: $(ReleaseTagVar)\n CreateJson: yes\n UseJson: no\n\n - template: /.pipelines/templates/cloneToOfficialPath.yml@self\n\n - template: /.pipelines/templates/insert-nuget-config-azfeed.yml@self\n parameters:\n repoRoot: $(PowerShellRoot)\n\n - pwsh: |\n if (-not (Test-Path -Path $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json)) {\n Get-ChildItem -Path $(Build.SourcesDirectory) -Recurse\n throw 'tsaoptions.json not found'\n }\n displayName: 'Check tsaoptions.json'\n\n - pwsh: |\n if (-not (Test-Path -Path $(Build.SourcesDirectory)\PowerShell\.config\suppress.json)) {\n Get-ChildItem -Path $(Build.SourcesDirectory) -Recurse\n throw 'suppress.json not found'\n }\n displayName: 'Check suppress.json'\n\n - task: AzurePowerShell@5\n displayName: Check if blob exists and delete if specified\n inputs:\n azureSubscription: az-blob-cicd-infra\n scriptType: inlineScript\n azurePowerShellVersion: LatestVersion\n pwsh: true\n inline: |\n $containersToDelete = @('$(AzureVersion)', '$(AzureVersion)-private', '$(AzureVersion)-nuget', '$(AzureVersion)-gc')\n\n $containersToDelete | ForEach-Object {\n $containerName = $_\n try {\n $container = Get-AzStorageContainer -Container $containerName -Context (New-AzStorageContext -StorageAccountName '$(StorageAccount)') -ErrorAction Stop\n if ($container -ne $null -and '$(ForceAzureBlobDelete)' -eq 'false') {\n throw "Azure blob container $containerName already exists. To overwrite, use ForceAzureBlobDelete parameter"\n }\n elseif ($container -ne $null -and '$(ForceAzureBlobDelete)' -eq 'true') {\n Write-Verbose -Verbose "Removing container $containerName due to ForceAzureBlobDelete parameter"\n Remove-AzStorageContainer -Name $containerName -Context (New-AzStorageContext -StorageAccountName '$(StorageAccount)') -Force\n }\n }\n catch {\n if ($_.FullyQualifiedErrorId -eq 'ResourceNotFoundException,Microsoft.WindowsAzure.Commands.Storage.Blob.Cmdlet.GetAzureStorageContainerCommand') {\n Write-Verbose -Verbose "Container $containerName does not exists."\n }\n else {\n throw $_\n }\n }\n }\n - template: /.pipelines/templates/step/finalize.yml@self\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\checkAzureContainer.yml
checkAzureContainer.yml
YAML
3,356
0.8
0.094118
0
python-kit
768
2024-11-23T03:35:22.556476
Apache-2.0
false
ca850b7a089261df9a4c6b6c0f2c757e
parameters:\n nativePathRoot: ''\n\nsteps:\n- powershell: |\n $dirSeparatorChar = [system.io.path]::DirectorySeparatorChar\n $nativePath = "${{parameters.nativePathRoot }}${dirSeparatorChar}PowerShell"\n Write-Host "##vso[task.setvariable variable=PowerShellRoot]$nativePath"\n if ((Test-Path "$nativePath")) {\n Remove-Item -Path "$nativePath" -Force -Recurse -Verbose -ErrorAction ignore\n }\n else {\n Write-Verbose -Verbose -Message "No cleanup required."\n }\n git clone --quiet $env:REPOROOT $nativePath\n displayName: Clone PowerShell Repo to /PowerShell\n errorActionPreference: silentlycontinue\n env:\n ob_restore_phase: true # This ensures checkout is done at the beginning of the restore phase\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\cloneToOfficialPath.yml
cloneToOfficialPath.yml
YAML
729
0.95
0.052632
0
react-lib
357
2024-07-27T13:33:58.533231
GPL-3.0
false
f5cfe878fcc995eedc51733cb6a581d3
parameters:\n- name: "repoRoot"\n default: $(REPOROOT)\n- name: "ob_restore_phase"\n type: boolean\n default: true\n\nsteps:\n- task: NuGetAuthenticate@1\n displayName: Install Azure Artifacts Credential Provider\n inputs:\n forceReinstallCredentialProvider: true\n\n- pwsh: |\n try {\n $configPath = "${env:NugetConfigDir}/nuget.config"\n Import-Module ${{ parameters.repoRoot }}/build.psm1 -Force\n\n Write-Verbose -Verbose "Running: Switch-PSNugetConfig -Source Private -UserName '$(AzDevopsFeedUserNameKVPAT)' -ClearTextPAT '$(powershellPackageReadPat)'"\n Switch-PSNugetConfig -Source Private -UserName '$(AzDevopsFeedUserNameKVPAT)' -ClearTextPAT '$(powershellPackageReadPat)'\n\n if(-not (Test-Path $configPath))\n {\n throw "nuget.config is not created"\n }\n }\n catch {\n Get-Error\n throw\n }\n displayName: 'Switch to production Azure DevOps feed for all nuget.configs'\n condition: and(succeededOrFailed(), ne(variables['UseAzDevOpsFeed'], ''))\n env:\n NugetConfigDir: ${{ parameters.repoRoot }}/src/Modules\n ob_restore_phase: ${{ parameters.ob_restore_phase }}\n\n- pwsh: |\n Get-ChildItem ${{ parameters.repoRoot }}/nuget.config -Recurse | Foreach-Object {\n Write-Verbose -Verbose "--- START $($_.fullname) ---"\n get-content $_.fullname | Out-String -width 9999 -Stream | write-Verbose -Verbose\n Write-Verbose -Verbose "--- END $($_.fullname) ---"\n }\n displayName: 'Capture all nuget.config files'\n condition: and(succeededOrFailed(), ne(variables['UseAzDevOpsFeed'], ''))\n env:\n ob_restore_phase: ${{ parameters.ob_restore_phase }}\n\n- pwsh: |\n Get-ChildItem -Path env:VSS* | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture VSS* Environment\n condition: and(succeededOrFailed(), ne(variables['UseAzDevOpsFeed'], ''))\n env:\n ob_restore_phase: ${{ parameters.ob_restore_phase }}\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\insert-nuget-config-azfeed.yml
insert-nuget-config-azfeed.yml
YAML
1,906
0.7
0.075472
0
vue-tools
69
2023-09-22T02:20:40.672911
BSD-3-Clause
false
c401c8aa9f0cc3d1ddf544b8c28a8f94
parameters:\n unsignedDrop: 'drop_linux_build_linux_x64'\n signedeDrop: 'drop_linux_sign_linux_x64'\n packageType: deb\n jobName: 'deb'\n signingProfile: 'CP-450779-pgpdetached'\n\njobs:\n- job: ${{ parameters.jobName }}\n displayName: Package linux ${{ parameters.packageType }}\n condition: succeeded()\n pool:\n type: linux\n\n variables:\n - name: runCodesignValidationInjection\n value: false\n - name: nugetMultiFeedWarnLevel\n value: none\n - name: NugetSecurityAnalysisWarningLevel\n value: none\n - name: skipNugetSecurityAnalysis\n value: true\n - group: DotNetPrivateBuildAccess\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: ob_sdl_binskim_enabled\n value: true\n - name: PackageType\n value: ${{ parameters.packageType }}\n - name: signedDrop\n value: ${{ parameters.signedDrop }}\n - name: unsignedDrop\n value: ${{ parameters.unsignedDrop }}\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)/PowerShell/.config/tsaoptions.json\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)/PowerShell/.config/suppress.json\n - name: SigningProfile\n value: ${{ parameters.signingProfile }}\n\n steps:\n - checkout: self\n clean: true\n env:\n ob_restore_phase: true # This ensures checkout is done at the beginning of the restore phase\n\n - pwsh: |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture environment\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n - template: SetVersionVariables.yml@self\n parameters:\n ReleaseTagVar: $(ReleaseTagVar)\n CreateJson: yes\n UseJson: no\n\n - template: shouldSign.yml\n\n - template: cloneToOfficialPath.yml\n parameters:\n nativePathRoot: '$(Agent.TempDirectory)'\n\n - download: CoOrdinatedBuildPipeline\n artifact: ${{ parameters.unsignedDrop }}\n displayName: 'Download unsigned artifacts'\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n - download: CoOrdinatedBuildPipeline\n artifact: ${{ parameters.signedDrop }}\n displayName: 'Download signed artifacts'\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n - pwsh: |\n Write-Verbose -Verbose "Unsigned artifacts"\n Get-ChildItem "$(Pipeline.Workspace)/CoOrdinatedBuildPipeline/${{ parameters.unsignedDrop }}" -Recurse\n\n Write-Verbose -Verbose "Signed artifacts"\n Get-ChildItem "$(Pipeline.Workspace)/CoOrdinatedBuildPipeline/${{ parameters.signedDrop }}" -Recurse\n displayName: 'Capture Downloaded Artifacts'\n # Diagnostics is not critical it passes every time it runs\n continueOnError: true\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n - pwsh: |\n $packageType = '$(PackageType)'\n Write-Verbose -Verbose "packageType = $packageType"\n\n $signedDrop = '$(signedDrop)'\n Write-Verbose -Verbose "signedDrop = $signedDrop"\n\n $unsignedDrop = '$(unsignedDrop)'\n Write-Verbose -Verbose "unsignedDrop = $unsignedDrop"\n\n Write-Verbose -Message "Init..." -Verbose\n\n $repoRoot = "$env:REPOROOT"\n Import-Module "$repoRoot/build.psm1"\n Import-Module "$repoRoot/tools/packaging"\n\n Start-PSBootstrap -Scenario Package\n\n $psOptionsPath = "$(Pipeline.Workspace)/CoOrdinatedBuildPipeline/${unsignedDrop}/psoptions/psoptions.json"\n\n if (-not (Test-Path $psOptionsPath)) {\n throw "psOptionsPath file not found at $psOptionsPath"\n }\n\n Restore-PSOptions $psOptionsPath\n Write-Verbose -Message "Restoring PSOptions from $psoptionsFilePath" -Verbose\n Get-PSOptions | Write-Verbose -Verbose\n\n $signedFolder, $pkgFilter = switch ($packageType) {\n 'tar-arm' { 'Signed-linux-arm', 'powershell*.tar.gz' }\n 'tar-arm64' { 'Signed-linux-arm64', 'powershell*.tar.gz' }\n 'tar-alpine' { 'Signed-linux-musl-x64', 'powershell*.tar.gz' }\n 'fxdependent' { 'Signed-fxdependent', 'powershell*.tar.gz' }\n 'tar' { 'Signed-linux-x64', 'powershell*.tar.gz' }\n 'tar-alpine-fxdependent' { 'Signed-fxdependent-noopt-linux-musl-x64', 'powershell*.tar.gz' }\n 'deb' { 'Signed-linux-x64', 'powershell*.deb' }\n 'rpm-fxdependent' { 'Signed-fxdependent-linux-x64', 'powershell*.rpm' }\n 'rpm-fxdependent-arm64' { 'Signed-fxdependent-linux-arm64', 'powershell*.rpm' }\n 'rpm' { 'Signed-linux-x64', 'powershell*.rpm' }\n 'min-size' { 'Signed-linux-x64', 'powershell*.tar.gz' }\n }\n\n $signedFilesPath = "$(Pipeline.Workspace)/CoOrdinatedBuildPipeline/${signedDrop}/${signedFolder}"\n Write-Verbose -Verbose "signedFilesPath: $signedFilesPath"\n\n Write-Verbose -Message "checking pwsh exists in $signedFilesPath" -Verbose\n if (-not (Test-Path "$signedFilesPath/pwsh")) {\n throw "pwsh not found in $signedFilesPath"\n }\n\n $metadata = Get-Content "$repoRoot/tools/metadata.json" -Raw | ConvertFrom-Json\n $LTS = $metadata.LTSRelease.Package\n\n if ($LTS) {\n Write-Verbose -Message "LTS Release: $LTS"\n }\n\n if (-not (Test-Path $(ob_outputDirectory))) {\n New-Item -ItemType Directory -Path $(ob_outputDirectory) -Force\n }\n\n $packageType = '$(PackageType)'\n Write-Verbose -Verbose "packageType = $packageType"\n\n Start-PSPackage -Type $packageType -ReleaseTag $(ReleaseTagVar) -PackageBinPath $signedFilesPath\n\n $vstsCommandString = "vso[task.setvariable variable=PackageFilter]$pkgFilter"\n Write-Host ("sending " + $vstsCommandString)\n Write-Host "##$vstsCommandString"\n displayName: 'Package ${{ parameters.packageType}}'\n env:\n __DOTNET_RUNTIME_FEED_KEY: $(RUNTIME_SOURCEFEED_KEY)\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n - task: onebranch.pipeline.signing@1\n displayName: Sign deb and rpm packages\n inputs:\n command: 'sign'\n signing_profile: '$(SigningProfile)'\n files_to_sign: '**/*.rpm;**/*.deb'\n search_root: '$(Pipeline.Workspace)'\n\n - pwsh: |\n $pkgFilter = '$(PackageFilter)'\n Write-Verbose -Verbose "pkgFilter: $pkgFilter"\n\n $pkgPath = Get-ChildItem -Path $(Pipeline.Workspace) -Filter $pkgFilter -Recurse -File | Select-Object -ExpandProperty FullName\n Write-Verbose -Verbose "pkgPath: $pkgPath"\n Copy-Item -Path $pkgPath -Destination '$(ob_outputDirectory)' -Force -Verbose\n displayName: 'Copy artifacts to output directory'\n env:\n __DOTNET_RUNTIME_FEED_KEY: $(RUNTIME_SOURCEFEED_KEY)\n\n - pwsh: |\n Get-ChildItem -Path $(ob_outputDirectory) -Recurse\n displayName: 'List artifacts'\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\linux-package-build.yml
linux-package-build.yml
YAML
6,893
0.8
0.027027
0.006579
awesome-app
908
2025-02-22T00:35:47.514792
Apache-2.0
false
e0a1d8c32910be26ed7cda91377e63f4
parameters:\n Runtime: 'linux-x64'\n BuildConfiguration: 'release'\n JobName: 'build_linux'\n\njobs:\n- job: build_${{ parameters.JobName }}\n displayName: Build_Linux_${{ parameters.Runtime }}_${{ parameters.BuildConfiguration }}\n condition: succeeded()\n pool:\n type: linux\n variables:\n - name: runCodesignValidationInjection\n value: false\n - name: NugetSecurityAnalysisWarningLevel\n value: none\n - name: DOTNET_SKIP_FIRST_TIME_EXPERIENCE\n value: 1\n - group: DotNetPrivateBuildAccess\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: ob_sdl_codeSignValidation_enabled\n value: false\n - name: ob_sdl_binskim_enabled\n value: true\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n - name: BUILDCONFIGURATION\n value: ${{ parameters.BuildConfiguration }}\n - name: Runtime\n value: ${{ parameters.Runtime }}\n - name: ob_sdl_sbom_packageName\n value: 'Microsoft.Powershell.Linux.${{ parameters.Runtime }}'\n # We add this manually, so we need it disabled the OneBranch auto-injected one.\n - name: ob_sdl_codeql_compiled_enabled\n value: false\n\n steps:\n - checkout: self\n clean: true\n env:\n ob_restore_phase: true # This ensures checkout is done at the beginning of the restore phase\n\n - template: /.pipelines/templates/SetVersionVariables.yml@self\n parameters:\n ReleaseTagVar: $(ReleaseTagVar)\n\n - template: /.pipelines/templates/cloneToOfficialPath.yml@self\n\n - template: /.pipelines/templates/insert-nuget-config-azfeed.yml@self\n parameters:\n repoRoot: $(PowerShellRoot)\n\n - task: CodeQL3000Init@0 # Add CodeQL Init task right before your 'Build' step.\n condition: eq(variables['CODEQL_ENABLED'], 'true')\n env:\n ob_restore_phase: true # Set ob_restore_phase to run this step before '🔒 Setup Signing' step.\n inputs:\n Enabled: true\n # AnalyzeInPipeline: false = upload results\n # AnalyzeInPipeline: true = do not upload results\n AnalyzeInPipeline: false\n Language: csharp\n\n - task: UseDotNet@2\n inputs:\n useGlobalJson: true\n workingDirectory: $(PowerShellRoot)\n env:\n ob_restore_phase: true\n\n - pwsh: |\n $runtime = $env:RUNTIME\n\n $params = @{}\n if ($env:BUILDCONFIGURATION -eq 'minSize') {\n Write-Verbose -Message "Building for minimal size"\n $params['ForMinimalSize'] = $true\n }\n\n Write-Verbose -Message "Building PowerShell with Runtime: $runtime"\n Import-Module -Name $(PowerShellRoot)/build.psm1 -Force\n $buildWithSymbolsPath = New-Item -ItemType Directory -Path $(Pipeline.Workspace)/Symbols_$(Runtime) -Force\n\n $null = New-Item -ItemType Directory -Path $buildWithSymbolsPath -Force -Verbose\n\n $ReleaseTagParam = @{}\n\n if ($env:RELEASETAGVAR) {\n $ReleaseTagParam['ReleaseTag'] = $env:RELEASETAGVAR\n }\n\n Start-PSBuild -Runtime $runtime -Configuration Release -Output $buildWithSymbolsPath @params -Clean -PSModuleRestore @ReleaseTagParam\n\n $outputPath = Join-Path '$(ob_outputDirectory)' 'psoptions'\n $null = New-Item -ItemType Directory -Path $outputPath -Force\n $psOptPath = "$outputPath/psoptions.json"\n Save-PSOptions -PSOptionsPath $psOptPath\n\n Write-Verbose -Verbose "Verifying pdbs exist in build folder"\n $pdbs = Get-ChildItem -Path $buildWithSymbolsPath -Recurse -Filter *.pdb\n if ($pdbs.Count -eq 0) {\n Write-Error -Message "No pdbs found in build folder"\n }\n else {\n Write-Verbose -Verbose "Found $($pdbs.Count) pdbs in build folder"\n $pdbs | ForEach-Object {\n Write-Verbose -Verbose "Pdb: $($_.FullName)"\n }\n }\n\n Write-Verbose -Verbose "Completed building PowerShell for '$env:BUILDCONFIGURATION' configuration"\n displayName: 'Build Linux - $(Runtime)'\n env:\n __DOTNET_RUNTIME_FEED_KEY: $(RUNTIME_SOURCEFEED_KEY)\n ob_restore_phase: true # Set ob_restore_phase to run this step before '🔒 Setup Signing' step.\n\n - task: CodeQL3000Finalize@0 # Add CodeQL Finalize task right after your 'Build' step.\n condition: eq(variables['CODEQL_ENABLED'], 'true')\n env:\n ob_restore_phase: true # Set ob_restore_phase to run this step before '🔒 Setup Signing' step.\n\n - pwsh: |\n $platform = 'linux'\n $vstsCommandString = "vso[task.setvariable variable=ArtifactPlatform]$platform"\n Write-Host ("sending " + $vstsCommandString)\n Write-Host "##$vstsCommandString"\n displayName: Set artifact platform\n\n - pwsh: |\n $pathForUpload = New-Item -ItemType Directory -Path '$(ob_outputDirectory)/Unsigned-$(Runtime)' -Force\n Write-Verbose -Verbose -Message "pathForUpload: $pathForUpload"\n Copy-Item -Path '$(Pipeline.Workspace)/Symbols_$(Runtime)/*' -Destination $pathForUpload -Recurse -Force -Verbose\n displayName: Copy unsigned files for upload\n\n - template: /.pipelines/templates/step/finalize.yml@self\n\n- job: sign_${{ parameters.JobName }}\n displayName: Sign_Linux_${{ parameters.Runtime }}_${{ parameters.BuildConfiguration }}\n condition: succeeded()\n dependsOn: build_${{ parameters.JobName }}\n pool:\n type: windows\n variables:\n - name: runCodesignValidationInjection\n value: false\n - name: NugetSecurityAnalysisWarningLevel\n value: none\n - name: DOTNET_SKIP_FIRST_TIME_EXPERIENCE\n value: 1\n - group: DotNetPrivateBuildAccess\n - group: certificate_logical_to_actual\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: ob_sdl_codeSignValidation_enabled\n value: false\n - name: ob_sdl_binskim_enabled\n value: false\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n - name: BuildConfiguration\n value: ${{ parameters.BuildConfiguration }}\n - name: Runtime\n value: ${{ parameters.Runtime }}\n - name: ob_sdl_codeql_compiled_enabled\n value: false\n\n steps:\n - checkout: self\n clean: true\n env:\n ob_restore_phase: true # This ensures checkout is done at the beginning of the restore phase\n\n - template: /.pipelines/templates/SetVersionVariables.yml@self\n parameters:\n ReleaseTagVar: $(ReleaseTagVar)\n\n - template: /.pipelines/templates/cloneToOfficialPath.yml@self\n\n - task: DownloadPipelineArtifact@2\n inputs:\n artifact: drop_linux_build_${{ parameters.JobName }}\n path: $(Pipeline.Workspace)/drop_linux_build\n displayName: Download build\n\n - pwsh: |\n Get-ChildItem -Path $(Pipeline.Workspace)/drop_linux_build -Recurse\n displayName: Capture downloaded files\n\n - pwsh: |\n $pwshPath = Get-ChildItem -Path $(Pipeline.Workspace)/drop_linux_build -File -Recurse | Where-Object { $_.Name -eq 'pwsh' }\n $rootPath = Split-Path -Path $pwshPath.FullName -Parent\n Write-Verbose -Verbose "Setting vso[task.setvariable variable=DropRootPath]$rootPath"\n Write-Host "##vso[task.setvariable variable=DropRootPath]$rootPath"\n displayName: Set drop root path\n\n - template: /.pipelines/templates/obp-file-signing.yml@self\n parameters:\n binPath: $(DropRootPath)\n\n - template: /.pipelines/templates/step/finalize.yml@self\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\linux.yml
linux.yml
YAML
7,438
0.8
0.029268
0.017143
python-kit
885
2025-06-21T04:41:44.725212
Apache-2.0
false
73112eda32c510b0e8f266528eeff0f1
parameters:\n parentJob: ''\n buildArchitecture: x64\n\njobs:\n- job: package_macOS_${{ parameters.buildArchitecture }}\n displayName: Package macOS ${{ parameters.buildArchitecture }}\n condition: succeeded()\n pool:\n type: linux\n isCustom: true\n name: Azure Pipelines\n vmImage: 'macOS-latest'\n\n variables:\n - name: HOMEBREW_NO_ANALYTICS\n value: 1\n - name: runCodesignValidationInjection\n value: false\n - name: nugetMultiFeedWarnLevel\n value: none\n - name: NugetSecurityAnalysisWarningLevel\n value: none\n - name: skipNugetSecurityAnalysis\n value: true\n - group: DotNetPrivateBuildAccess\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: ob_sdl_binskim_enabled\n value: true\n - name: ob_sdl_credscan_suppressionsfileforartifacts\n value: $(Build.SourcesDirectory)/PowerShell/.config/suppress.json\n - name: BuildArch\n value: ${{ parameters.buildArchitecture }}\n\n steps:\n - checkout: self\n clean: true\n\n - pwsh: |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture environment\n\n - pwsh: |\n # create folder\n sudo mkdir "$(Agent.TempDirectory)/PowerShell"\n\n # make the current user the owner\n sudo chown $env:USER "$(Agent.TempDirectory)/PowerShell"\n displayName: 'Create $(Agent.TempDirectory)/PowerShell'\n\n - template: SetVersionVariables.yml@self\n parameters:\n ReleaseTagVar: $(ReleaseTagVar)\n CreateJson: yes\n UseJson: no\n\n - template: shouldSign.yml\n\n - template: cloneToOfficialPath.yml\n parameters:\n nativePathRoot: '$(Agent.TempDirectory)'\n\n - download: CoOrdinatedBuildPipeline\n artifact: macosBinResults-${{ parameters.buildArchitecture }}\n\n - download: CoOrdinatedBuildPipeline\n artifact: drop_macos_sign_${{ parameters.buildArchitecture }}\n\n - pwsh: |\n Write-Verbose -Verbose "unsigned artifacts"\n Get-ChildItem "$(Pipeline.Workspace)/CoOrdinatedBuildPipeline/macosBinResults-${{ parameters.buildArchitecture }}" -Recurse\n\n Write-Verbose -Verbose "unsigned artifacts"\n Get-ChildItem "$(Pipeline.Workspace)/CoOrdinatedBuildPipeline/drop_macos_sign_${{ parameters.buildArchitecture }}" -Recurse\n displayName: 'Capture Downloaded Artifacts'\n # Diagnostics is not critical it passes every time it runs\n continueOnError: true\n\n - pwsh: |\n # Add -SkipReleaseChecks as a mitigation to unblock release.\n # macos-10.15 does not allow creating a folder under root. Hence, moving the folder.\n\n $buildArch = '${{ parameters.buildArchitecture }}'\n\n Write-Verbose -Message "Init..." -Verbose\n $repoRoot = $env:REPOROOT\n Set-Location $repoRoot\n Import-Module "$repoRoot/build.psm1"\n Import-Module "$repoRoot/tools/packaging"\n\n $unsignedFilesPath = "$(Pipeline.Workspace)/CoOrdinatedBuildPipeline/macosBinResults-$buildArch"\n $signedFilesPath = "$(Pipeline.Workspace)/CoOrdinatedBuildPipeline/drop_macos_sign_$buildArch/Signed-$buildArch"\n\n Write-Verbose -Message "checking pwsh exists in $signedFilesPath" -Verbose\n if (-not (Test-Path $signedFilesPath/pwsh)) {\n throw "pwsh not found in $signedFilesPath"\n }\n\n $psoptionsPath = Get-ChildItem -Path $unsignedFilesPath -Filter 'psoptions.json' -Recurse -File | Select-Object -ExpandProperty FullName\n Write-Verbose -Message "Restoring PSOptions from $psoptionsPath" -Verbose\n\n Restore-PSOptions -PSOptionsPath "$psoptionsPath"\n Get-PSOptions | Write-Verbose -Verbose\n\n $metadata = Get-Content "$repoRoot/tools/metadata.json" -Raw | ConvertFrom-Json\n $LTS = $metadata.LTSRelease.Package\n\n if ($LTS) {\n Write-Verbose -Message "LTS Release: $LTS"\n }\n\n Start-PSBootstrap -Scenario Package\n\n $macosRuntime = "osx-$buildArch"\n\n Start-PSPackage -Type osxpkg -SkipReleaseChecks -MacOSRuntime $macosRuntime -ReleaseTag $(ReleaseTagVar) -PackageBinPath $signedFilesPath -LTS:$LTS\n $pkgNameFilter = "powershell-*$macosRuntime.pkg"\n $pkgPath = Get-ChildItem -Path $(Pipeline.Workspace) -Filter $pkgNameFilter -Recurse -File | Select-Object -ExpandProperty FullName\n Write-Host "##vso[artifact.upload containerfolder=macos-pkgs;artifactname=macos-pkgs]$pkgPath"\n\n Start-PSPackage -Type tar -SkipReleaseChecks -MacOSRuntime $macosRuntime -ReleaseTag $(ReleaseTagVar) -PackageBinPath $signedFilesPath -LTS:$LTS\n $tarPkgNameFilter = "powershell-*$macosRuntime.tar.gz"\n $tarPkgPath = Get-ChildItem -Path $(Pipeline.Workspace) -Filter $tarPkgNameFilter -Recurse -File | Select-Object -ExpandProperty FullName\n Write-Host "##vso[artifact.upload containerfolder=macos-pkgs;artifactname=macos-pkgs]$tarPkgPath"\n\n displayName: 'Package ${{ parameters.buildArchitecture}}'\n env:\n __DOTNET_RUNTIME_FEED_KEY: $(RUNTIME_SOURCEFEED_KEY)\n\n- job: sign_package_macOS_${{ parameters.buildArchitecture }}\n displayName: Sign Package macOS ${{ parameters.buildArchitecture }}\n dependsOn: package_macOS_${{ parameters.buildArchitecture }}\n condition: succeeded()\n pool:\n type: windows\n\n variables:\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: ob_sdl_binskim_enabled\n value: true\n - name: ob_sdl_credscan_suppressionsfileforartifacts\n value: $(Build.SourcesDirectory)/PowerShell/.config/suppress.json\n - name: BuildArch\n value: ${{ parameters.buildArchitecture }}\n - group: mscodehub-macos-package-signing\n\n steps:\n - download: current\n artifact: macos-pkgs\n\n - pwsh: |\n $buildArch = '${{ parameters.buildArchitecture }}'\n $macosRuntime = "osx-$buildArch"\n $pkgNameFilter = "powershell-*$macosRuntime.pkg"\n $pkgPath = Get-ChildItem -Path $(Pipeline.Workspace) -Filter $pkgNameFilter -Recurse -File\n\n if ($pkgPath.Count -eq 0) {\n throw "No package found for $macosRuntime"\n }\n\n foreach($p in $pkgPath) {\n $file = $p.FullName\n $fileName = $p.BaseName\n Write-Verbose -verbose "Compressing $file"\n $zipFile = "$(Pipeline.Workspace)\${fileName}.zip"\n Write-Verbose -Verbose "Zip file: $zipFile"\n Compress-Archive -Path $file -Destination $zipFile\n }\n\n Write-Verbose -Verbose "Compressed files:"\n Get-ChildItem -Path $(Pipeline.Workspace) -Filter "*.zip" -File | Write-Verbose -Verbose\n displayName: Compress package files for signing\n\n - task: onebranch.pipeline.signing@1\n displayName: 'OneBranch CodeSigning Package'\n inputs:\n command: 'sign'\n files_to_sign: '**/*-osx-*.zip'\n search_root: '$(Pipeline.Workspace)'\n inline_operation: |\n [\n {\n "KeyCode": "$(KeyCode)",\n "OperationCode": "MacAppDeveloperSign",\n "ToolName": "sign",\n "ToolVersion": "1.0",\n "Parameters": {\n "Hardening": "Enable",\n "OpusInfo": "http://microsoft.com"\n }\n }\n ]\n\n - pwsh: |\n $signedPkg = Get-ChildItem -Path $(Pipeline.Workspace) -Filter "*osx*.zip" -File\n \n $signedPkg | ForEach-Object {\n Write-Verbose -Verbose "Signed package zip: $_"\n \n if (-not (Test-Path $_)) {\n throw "Package not found: $_"\n }\n \n if (-not (Test-Path $(ob_outputDirectory))) {\n $null = New-Item -Path $(ob_outputDirectory) -ItemType Directory\n }\n\n Expand-Archive -Path $_ -DestinationPath $(ob_outputDirectory) -Verbose\n }\n\n Write-Verbose -Verbose "Expanded pkg file:"\n Get-ChildItem -Path $(ob_outputDirectory) | Write-Verbose -Verbose\n displayName: Expand signed file\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\mac-package-build.yml
mac-package-build.yml
YAML
7,727
0.8
0.032558
0.028736
vue-tools
158
2023-08-12T16:48:04.965906
BSD-3-Clause
false
942b1aa38f8a925f3bc281159fdbcd85
parameters:\n buildArchitecture: 'x64'\njobs:\n- job: build_macOS_${{ parameters.buildArchitecture }}\n displayName: Build macOS ${{ parameters.buildArchitecture }}\n condition: succeeded()\n pool:\n type: linux\n isCustom: true\n name: Azure Pipelines\n vmImage: 'macOS-latest'\n\n variables:\n - name: HOMEBREW_NO_ANALYTICS\n value: 1\n - name: runCodesignValidationInjection\n value: false\n - name: NugetSecurityAnalysisWarningLevel\n value: none\n - group: DotNetPrivateBuildAccess\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: PowerShellRoot\n value: $(Build.SourcesDirectory)\n\n steps:\n - checkout: self\n clean: true\n env:\n ob_restore_phase: true # This ensures checkout is done at the beginning of the restore phase\n\n - template: /.pipelines/templates/SetVersionVariables.yml@self\n parameters:\n ReleaseTagVar: $(ReleaseTagVar)\n - pwsh: |\n # create folder\n sudo mkdir "$(Agent.TempDirectory)/PowerShell"\n # make the current user the owner\n sudo chown $env:USER "$(Agent.TempDirectory)/PowerShell"\n displayName: 'Create $(Agent.TempDirectory)/PowerShell'\n\n - task: UseDotNet@2\n displayName: 'Use .NET Core sdk'\n inputs:\n useGlobalJson: true\n packageType: 'sdk'\n workingDirectory: $(PowerShellRoot)\n\n - pwsh: |\n Import-Module $(PowerShellRoot)/build.psm1 -Force\n Start-PSBootstrap -Scenario Package\n displayName: 'Bootstrap VM'\n env:\n __DOTNET_RUNTIME_FEED_KEY: $(RUNTIME_SOURCEFEED_KEY)\n\n - template: /.pipelines/templates/insert-nuget-config-azfeed.yml@self\n parameters:\n repoRoot: $(PowerShellRoot)\n - pwsh: |\n $env:AzDevOpsFeedPAT2 = '$(powershellPackageReadPat)'\n # Add -SkipReleaseChecks as a mitigation to unblock release.\n # macos-10.15 does not allow creating a folder under root. Hence, moving the folder.\n\n Import-Module ./build.psm1 -Force\n\n $ReleaseTagParam = @{}\n\n if ($env:RELEASETAGVAR) {\n $ReleaseTagParam['ReleaseTag'] = $env:RELEASETAGVAR\n }\n\n Start-PSBuild -Runtime 'osx-${{ parameters.buildArchitecture }}' -Configuration Release -PSModuleRestore -Clean -Output $(OB_OUTPUTDIRECTORY) @ReleaseTagParam\n $artifactName = "macosBinResults-${{ parameters.buildArchitecture }}"\n\n $psOptPath = "$(OB_OUTPUTDIRECTORY)/psoptions.json"\n Save-PSOptions -PSOptionsPath $psOptPath\n\n # Since we are using custom pool for macOS, we need to use artifact.upload to publish the artifacts\n Write-Host "##vso[artifact.upload containerfolder=$artifactName;artifactname=$artifactName]$(OB_OUTPUTDIRECTORY)"\n\n $env:AzDevOpsFeedPAT2 = $null\n displayName: 'Build'\n env:\n __DOTNET_RUNTIME_FEED_KEY: $(RUNTIME_SOURCEFEED_KEY)\n\n - template: /.pipelines/templates/step/finalize.yml@self\n\n- job: sign_${{ parameters.buildArchitecture }}\n displayName: Sign_macOS_${{ parameters.buildArchitecture }}\n condition: succeeded()\n dependsOn: build_macOS_${{ parameters.buildArchitecture }}\n pool:\n type: windows\n variables:\n - name: NugetSecurityAnalysisWarningLevel\n value: none\n - group: DotNetPrivateBuildAccess\n - group: certificate_logical_to_actual\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: ob_sdl_codeSignValidation_enabled\n value: true\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n - name: BuildArchitecture\n value: ${{ parameters.buildArchitecture }}\n - name: ob_sdl_codeql_compiled_enabled\n value: false\n - name: ob_sdl_sbom_packageName\n value: 'Microsoft.Powershell.MacOS.${{parameters.buildArchitecture}}'\n\n steps:\n - checkout: self\n clean: true\n env:\n ob_restore_phase: true # This ensures checkout is done at the beginning of the restore phase\n\n - template: /.pipelines/templates/SetVersionVariables.yml@self\n parameters:\n ReleaseTagVar: $(ReleaseTagVar)\n\n - template: /.pipelines/templates/cloneToOfficialPath.yml@self\n\n - task: DownloadPipelineArtifact@2\n inputs:\n artifact: 'macosBinResults-$(BuildArchitecture)'\n path: '$(Pipeline.Workspace)\Symbols'\n displayName: Download build\n\n - pwsh: |\n Get-ChildItem "$(Pipeline.Workspace)\*" -Recurse\n displayName: 'Capture Downloaded Artifacts'\n # Diagnostics is not critical it passes every time it runs\n continueOnError: true\n\n - pwsh: |\n $runtime = '$(BuildArchitecture)'\n Write-Host "sending.. vso[task.setvariable variable=Runtime]$runtime"\n Write-Host "##vso[task.setvariable variable=Runtime]$runtime"\n\n $rootPath = "$(Pipeline.Workspace)\Symbols"\n Write-Verbose -Verbose "Setting vso[task.setvariable variable=DropRootPath]$rootPath"\n Write-Host "##vso[task.setvariable variable=DropRootPath]$rootPath"\n displayName: Expand symbols zip\n\n - template: /.pipelines/templates/obp-file-signing.yml@self\n parameters:\n binPath: $(DropRootPath)\n\n - template: /.pipelines/templates/step/finalize.yml@self\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\mac.yml
mac.yml
YAML
5,177
0.8
0.013158
0.046875
react-lib
367
2024-01-12T16:21:10.242235
MIT
false
2a6c11fb9daceff6e9936ac4cd67307f
jobs:\n- job: build_nupkg\n displayName: Package NuPkgs\n condition: succeeded()\n pool:\n type: windows\n\n variables:\n - name: runCodesignValidationInjection\n value: false\n - name: nugetMultiFeedWarnLevel\n value: none\n - name: NugetSecurityAnalysisWarningLevel\n value: none\n - name: skipNugetSecurityAnalysis\n value: true\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)\ONEBRANCH_ARTIFACT'\n - name: ob_sdl_binskim_enabled\n value: true\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n - group: mscodehub-feed-read-general\n - group: mscodehub-feed-read-akv\n - group: DotNetPrivateBuildAccess\n\n steps:\n - checkout: self\n clean: true\n env:\n ob_restore_phase: true # This ensures checkout is done at the beginning of the restore phase\n\n - pwsh: |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture environment\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n - template: SetVersionVariables.yml@self\n parameters:\n ReleaseTagVar: $(ReleaseTagVar)\n CreateJson: yes\n UseJson: no\n\n - template: shouldSign.yml\n\n - template: cloneToOfficialPath.yml\n parameters:\n nativePathRoot: '$(Agent.TempDirectory)'\n\n - download: CoOrdinatedBuildPipeline\n artifact: drop_windows_build_windows_fxdependent_release\n displayName: 'Download drop_windows_build_windows_fxdependent_release'\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n - download: CoOrdinatedBuildPipeline\n artifact: drop_windows_build_windows_fxdependentWinDesktop_release\n displayName: 'Download drop_windows_build_windows_fxdependentWinDesktop_release'\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n - download: CoOrdinatedBuildPipeline\n artifact: drop_linux_sign_linux_fxd\n displayName: 'Download drop_linux_sign_linux_fxd'\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n - download: CoOrdinatedBuildPipeline\n artifact: drop_linux_sign_linux_fxd_x64_alpine\n displayName: 'Download drop_linux_sign_linux_fxd_x64_alpine'\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n - pwsh: |\n Write-Verbose -Verbose "drop_windows_build_windows_fxdependent_release"\n Get-ChildItem -Path $(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_windows_build_windows_fxdependent_release -Recurse | Out-String | Write-Verbose -Verbose\n\n Write-Verbose -Verbose "drop_windows_build_windows_fxdependentWinDesktop_release"\n Get-ChildItem -Path $(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_windows_build_windows_fxdependentWinDesktop_release -Recurse | Out-String | Write-Verbose -Verbose\n\n Write-Verbose -Verbose "drop_linux_sign_linux_fxd"\n Get-ChildItem -Path $(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_linux_sign_linux_fxd -Recurse | Out-String | Write-Verbose -Verbose\n\n Write-Verbose -Verbose "drop_linux_sign_linux_fxd_x64_alpine"\n Get-ChildItem -Path $(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_linux_sign_linux_fxd_x64_alpine -Recurse | Out-String | Write-Verbose -Verbose\n displayName: 'Capture download artifacts'\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n - template: /.pipelines/templates/insert-nuget-config-azfeed.yml@self\n parameters:\n repoRoot: $(PowerShellRoot)\n\n - task: NuGetToolInstaller@1\n displayName: 'Install NuGet.exe'\n\n - task: UseDotNet@2\n displayName: 'Use .NET Core sdk'\n inputs:\n useGlobalJson: true\n packageType: 'sdk'\n workingDirectory: '$(PowerShellRoot)'\n\n - pwsh: |\n Set-Location -Path '$(PowerShellRoot)'\n Import-Module "$(PowerShellRoot)/build.psm1" -Force\n\n $sharedModules = @('Microsoft.PowerShell.Commands.Management',\n 'Microsoft.PowerShell.Commands.Utility',\n 'Microsoft.PowerShell.ConsoleHost',\n 'Microsoft.PowerShell.Security',\n 'System.Management.Automation'\n )\n\n $winOnlyModules = @('Microsoft.Management.Infrastructure.CimCmdlets',\n 'Microsoft.PowerShell.Commands.Diagnostics',\n 'Microsoft.PowerShell.CoreCLR.Eventing',\n 'Microsoft.WSMan.Management',\n 'Microsoft.WSMan.Runtime'\n )\n\n $refAssemblyFolder = Join-Path '$(System.ArtifactsDirectory)' 'RefAssembly'\n $null = New-Item -Path $refAssemblyFolder -Force -Verbose -Type Directory\n\n Start-PSBuild -Clean -Runtime linux-x64 -Configuration Release -ReleaseTag $(ReleaseTagVar)\n\n $sharedModules | Foreach-Object {\n $refFile = Get-ChildItem -Path "$(PowerShellRoot)\src\$_\obj\Release\net10.0\refint\$_.dll"\n Write-Verbose -Verbose "RefAssembly: $refFile"\n Copy-Item -Path $refFile -Destination "$refAssemblyFolder\$_.dll" -Verbose\n $refDoc = "$(PowerShellRoot)\src\$_\bin\Release\net10.0\$_.xml"\n if (-not (Test-Path $refDoc)) {\n Write-Warning "$refDoc not found"\n Get-ChildItem -Path "$(PowerShellRoot)\src\$_\bin\Release\net10.0\" | Out-String | Write-Verbose -Verbose\n }\n else {\n Copy-Item -Path $refDoc -Destination "$refAssemblyFolder\$_.xml" -Verbose\n }\n }\n\n Start-PSBuild -Clean -Runtime win7-x64 -Configuration Release -ReleaseTag $(ReleaseTagVar)\n\n $winOnlyModules | Foreach-Object {\n $refFile = Get-ChildItem -Path "$(PowerShellRoot)\src\$_\obj\Release\net10.0\refint\*.dll"\n Write-Verbose -Verbose 'RefAssembly: $refFile'\n Copy-Item -Path $refFile -Destination "$refAssemblyFolder\$_.dll" -Verbose\n $refDoc = "$(PowerShellRoot)\src\$_\bin\Release\net10.0\$_.xml"\n if (-not (Test-Path $refDoc)) {\n Write-Warning "$refDoc not found"\n Get-ChildItem -Path "$(PowerShellRoot)\src\$_\bin\Release\net10.0" | Out-String | Write-Verbose -Verbose\n }\n else {\n Copy-Item -Path $refDoc -Destination "$refAssemblyFolder\$_.xml" -Verbose\n }\n }\n\n Get-ChildItem $refAssemblyFolder -Recurse | Out-String | Write-Verbose -Verbose\n\n # Set RefAssemblyPath path variable\n $vstsCommandString = "vso[task.setvariable variable=RefAssemblyPath]${refAssemblyFolder}"\n Write-Host "sending " + $vstsCommandString\n Write-Host "##$vstsCommandString"\n displayName: Build reference assemblies\n env:\n __DOTNET_RUNTIME_FEED_KEY: $(RUNTIME_SOURCEFEED_KEY)\n\n - task: onebranch.pipeline.signing@1\n displayName: Sign ref assemblies\n inputs:\n command: 'sign'\n signing_profile: external_distribution\n files_to_sign: '**\*.dll'\n search_root: '$(System.ArtifactsDirectory)\RefAssembly'\n\n - pwsh: |\n $files = @(\n "Microsoft.Management.Infrastructure.CimCmdlets.dll"\n "Microsoft.PowerShell.Commands.Diagnostics.dll"\n "Microsoft.PowerShell.Commands.Management.dll"\n "Microsoft.PowerShell.Commands.Utility.dll"\n "Microsoft.PowerShell.ConsoleHost.dll"\n "Microsoft.PowerShell.CoreCLR.Eventing.dll"\n "Microsoft.PowerShell.Security.dll"\n "Microsoft.PowerShell.SDK.dll"\n "Microsoft.WSMan.Management.dll"\n "Microsoft.WSMan.Runtime.dll"\n "System.Management.Automation.dll"\n )\n\n Import-Module -Name '$(PowerShellRoot)\build.psm1'\n Import-Module -Name '$(PowerShellRoot)\tools\packaging'\n Find-DotNet\n\n Write-Verbose -Verbose "Version == $(Version)"\n\n $winFxdPath = "$(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_windows_build_windows_fxdependent_release\Signed-fxdependent"\n Write-Verbose -Verbose "winFxdPath == $winFxdPath"\n\n $linuxFxdPath = "$(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_linux_sign_linux_fxd\Signed-fxdependent"\n Write-Verbose -Verbose "linuxFxdPath == $linuxFxdPath"\n\n $nupkgOutputPath = Join-Path -Path '$(Pipeline.Workspace)' -ChildPath 'nupkg'\n New-Item -Path $nupkgOutputPath -ItemType Directory -Force\n\n $files | Foreach-Object {\n $FileBaseName = [System.IO.Path]::GetFileNameWithoutExtension($_)\n $FilePackagePath = Join-Path -Path $nupkgOutputPath -ChildPath $FileBaseName\n Write-Verbose -Verbose "FileName to package: $_"\n Write-Verbose -Verbose "FilePackage path: $FilePackagePath"\n New-ILNugetPackageSource -File $_ -PackagePath $FilePackagePath -PackageVersion '$(Version)' -WinFxdBinPath $winFxdPath -LinuxFxdBinPath $linuxFxdPath -RefAssemblyPath $(RefAssemblyPath)\n New-ILNugetPackageFromSource -FileName $_ -PackageVersion '$(Version)' -PackagePath $FilePackagePath\n }\n displayName: 'Create NuGet Package for single file'\n\n - task: onebranch.pipeline.signing@1\n displayName: Sign nupkg files\n inputs:\n command: 'sign'\n cp_code: 'CP-401405'\n files_to_sign: '**\*.nupkg'\n search_root: '$(Pipeline.Workspace)\nupkg'\n\n ### Create global tools\n\n - pwsh: |\n $winFxdPath = "$(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_windows_build_windows_fxdependent_release\Signed-fxdependent"\n $winDesktopFxdPath = "$(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_windows_build_windows_fxdependentWinDesktop_release\Signed-fxdependent-win-desktop"\n $linuxFxdPath = "$(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_linux_sign_linux_fxd\Signed-fxdependent"\n $alpineFxdPath = "$(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_linux_sign_linux_fxd_x64_alpine\Signed-fxdependent-noopt-linux-musl-x64"\n\n Import-Module -Name '$(PowerShellRoot)\build.psm1'\n Import-Module -Name '$(PowerShellRoot)\tools\packaging'\n\n Start-PrepForGlobalToolNupkg -LinuxBinPath $linuxFxdPath -WindowsBinPath $winFxdPath -WindowsDesktopBinPath $winDesktopFxdPath -AlpineBinPath $alpineFxdPath\n displayName: 'Prepare for global tool packages'\n\n - pwsh: |\n Import-Module -Name '$(PowerShellRoot)\build.psm1'\n Import-Module -Name '$(PowerShellRoot)\tools\packaging'\n Find-DotNet\n\n $gblToolOutputPath = Join-Path -Path '$(Pipeline.Workspace)' -ChildPath 'globaltools'\n New-Item -Path $gblToolOutputPath -ItemType Directory -Force\n\n $winFxdPath = "$(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_windows_build_windows_fxdependent_release\Signed-fxdependent"\n $winDesktopFxdPath = "$(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_windows_build_windows_fxdependentWinDesktop_release\Signed-fxdependent-win-desktop"\n $linuxFxdPath = "$(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_linux_sign_linux_fxd\Signed-fxdependent"\n $alpineFxdPath = "$(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_linux_sign_linux_fxd_x64_alpine\Signed-fxdependent-noopt-linux-musl-x64"\n\n # Build global tools which do not have the shims exe generated in build.\n $packageTypes = @('Unified', 'PowerShell.Linux.Alpine', 'PowerShell.Linux.x64', 'PowerShell.Linux.arm32', 'PowerShell.Linux.arm64')\n\n $packageTypes | Foreach-Object {\n $PackageType = $_\n Write-Verbose -Verbose "PackageType: $PackageType"\n\n New-GlobalToolNupkgSource -PackageType $PackageType -PackageVersion '$(Version)' -LinuxBinPath $linuxFxdPath -WindowsBinPath $winFxdPath -WindowsDesktopBinPath $winDesktopFxdPath -AlpineBinPath $alpineFxdPath -SkipCGManifest\n\n Write-Verbose -Verbose "GlobalToolNuspecSourcePath = $global:GlobalToolNuSpecSourcePath"\n Write-Verbose -Verbose "GlobalToolPkgName = $global:GlobalToolPkgName"\n\n Write-Verbose -Verbose "Starting global tool package creation for $PackageType"\n New-GlobalToolNupkgFromSource -PackageNuSpecPath "$global:GlobalToolNuSpecSourcePath" -PackageName "$global:GlobalToolPkgName" -DestinationPath $gblToolOutputPath\n Write-Verbose -Verbose "Global tool package created for $PackageType"\n $global:GlobalToolNuSpecSourcePath = $null\n $global:GlobalToolPkgName = $null\n }\n displayName: 'Create global tools'\n\n - pwsh: |\n $gblToolOutputPath = Join-Path -Path '$(Pipeline.Workspace)' -ChildPath 'globaltools'\n Get-ChildItem -Path $gblToolOutputPath\n displayName: Capture global tools\n\n - task: onebranch.pipeline.signing@1\n displayName: Sign nupkg files\n inputs:\n command: 'sign'\n cp_code: 'CP-401405'\n files_to_sign: '**\*.nupkg'\n search_root: '$(Pipeline.Workspace)\globaltools'\n\n - pwsh: |\n if (-not (Test-Path '$(ob_outputDirectory)')) {\n New-Item -ItemType Directory -Path '$(ob_outputDirectory)' -Force\n }\n\n Write-Verbose -Verbose "Copying nupkgs to output directory"\n $nupkgOutputPath = Join-Path -Path '$(Pipeline.Workspace)' -ChildPath 'nupkg'\n Get-ChildItem -Path $nupkgOutputPath -Filter *.nupkg -Recurse | Copy-Item -Destination '$(ob_outputDirectory)' -Force -Verbose\n\n # Copy Windows.x86 global tool from build to output directory\n $winX64GlobalTool = "$(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_windows_build_windows_fxdependent_release\globaltool\powershell*.nupkg"\n Write-Verbose -Verbose "Finding Windows.x64 global tool at $winX64GlobalTool"\n $globalToolPath = Get-Item $winX64GlobalTool\n Copy-Item -Path $globalToolPath -Destination '$(ob_outputDirectory)' -Force -Verbose\n\n Write-Verbose -Verbose "Copying global tools to output directory"\n $gblToolOutputPath = Join-Path -Path '$(Pipeline.Workspace)' -ChildPath 'globaltools'\n Get-ChildItem -Path $gblToolOutputPath -Filter *.nupkg -Recurse | Copy-Item -Destination '$(ob_outputDirectory)' -Force -Verbose\n displayName: Copy artifacts to output directory\n\n - pwsh: |\n $nupkgOutputPath = '$(ob_outputDirectory)'\n Get-ChildItem -Path $nupkgOutputPath | Out-String | Write-Verbose -Verbose\n displayName: List artifacts\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\nupkg.yml
nupkg.yml
YAML
14,320
0.8
0.022654
0.015748
react-lib
375
2023-09-23T16:21:08.337797
MIT
false
5389feda5a4e1b70a1b0eeafee0f5590
parameters:\n binPath: '$(ob_outputDirectory)'\n globalTool: 'false'\n\nsteps:\n- pwsh: |\n $fullSymbolsFolder = '${{ parameters.binPath }}'\n Write-Verbose -Verbose "fullSymbolsFolder == $fullSymbolsFolder"\n Get-ChildItem -Recurse $fullSymbolsFolder | Select-Object -ExpandProperty FullName | Write-Verbose -Verbose\n $filesToSignDirectory = "$(Pipeline.Workspace)/toBeSigned"\n if ((Test-Path -Path $filesToSignDirectory)) {\n Remove-Item -Path $filesToSignDirectory -Recurse -Force\n }\n $null = New-Item -ItemType Directory -Path $filesToSignDirectory -Force\n\n $itemsToCopyWithRecurse = @(\n "$($fullSymbolsFolder)/*.ps1"\n "$($fullSymbolsFolder)/Microsoft.PowerShell*.dll"\n )\n $itemsToCopy = @{\n "$($fullSymbolsFolder)/*.ps1" = ""\n "$($fullSymbolsFolder)/Modules/Microsoft.PowerShell.Host/Microsoft.PowerShell.Host.psd1" = "Modules/Microsoft.PowerShell.Host"\n "$($fullSymbolsFolder)/Modules/Microsoft.PowerShell.Management/Microsoft.PowerShell.Management.psd1" = "Modules/Microsoft.PowerShell.Management"\n "$($fullSymbolsFolder)/Modules/Microsoft.PowerShell.Security/Microsoft.PowerShell.Security.psd1" = "Modules/Microsoft.PowerShell.Security"\n "$($fullSymbolsFolder)/Modules/Microsoft.PowerShell.Utility/Microsoft.PowerShell.Utility.psd1" = "Modules/Microsoft.PowerShell.Utility"\n "$($fullSymbolsFolder)/pwsh.dll" = ""\n "$($fullSymbolsFolder)/System.Management.Automation.dll" = ""\n }\n ## Windows only modules\n if('$(ArtifactPlatform)' -eq 'windows') {\n $itemsToCopy += @{\n "$($fullSymbolsFolder)/pwsh.exe" = ""\n "$($fullSymbolsFolder)/Microsoft.Management.Infrastructure.CimCmdlets.dll" = ""\n "$($fullSymbolsFolder)/Microsoft.WSMan.*.dll" = ""\n "$($fullSymbolsFolder)/Modules/CimCmdlets/CimCmdlets.psd1" = "Modules/CimCmdlets"\n "$($fullSymbolsFolder)/Modules/Microsoft.PowerShell.Diagnostics/Diagnostics.format.ps1xml" = "Modules/Microsoft.PowerShell.Diagnostics"\n "$($fullSymbolsFolder)/Modules/Microsoft.PowerShell.Diagnostics/Event.format.ps1xml" = "Modules/Microsoft.PowerShell.Diagnostics"\n "$($fullSymbolsFolder)/Modules/Microsoft.PowerShell.Diagnostics/GetEvent.types.ps1xml" = "Modules/Microsoft.PowerShell.Diagnostics"\n "$($fullSymbolsFolder)/Modules/Microsoft.PowerShell.Security/Security.types.ps1xml" = "Modules/Microsoft.PowerShell.Security"\n "$($fullSymbolsFolder)/Modules/Microsoft.PowerShell.Diagnostics/Microsoft.PowerShell.Diagnostics.psd1" = "Modules/Microsoft.PowerShell.Diagnostics"\n "$($fullSymbolsFolder)/Modules/Microsoft.WSMan.Management/Microsoft.WSMan.Management.psd1" = "Modules/Microsoft.WSMan.Management"\n "$($fullSymbolsFolder)/Modules/Microsoft.WSMan.Management/WSMan.format.ps1xml" = "Modules/Microsoft.WSMan.Management"\n "$($fullSymbolsFolder)/Modules/PSDiagnostics/PSDiagnostics.ps?1" = "Modules/PSDiagnostics"\n }\n }\n\n $itemsToExclude = @(\n # This package is retrieved from https://www.github.com/powershell/MarkdownRender\n "$($fullSymbolsFolder)/Microsoft.PowerShell.MarkdownRender.dll"\n )\n\n if('$(ArtifactPlatform)' -eq 'linux' -or '$(ArtifactPlatform)' -eq 'macos') {\n $itemsToExclude += "$($fullSymbolsFolder)/pwsh"\n }\n\n Write-Verbose -verbose "recursively copying $($itemsToCopyWithRecurse | out-string) to $filesToSignDirectory"\n Copy-Item -Path $itemsToCopyWithRecurse -Destination $filesToSignDirectory -Recurse -verbose -exclude $itemsToExclude\n Write-Verbose -verbose "recursive copy done."\n\n foreach($pattern in $itemsToCopy.Keys) {\n $destinationFolder = Join-Path $filesToSignDirectory -ChildPath $itemsToCopy.$pattern\n $null = New-Item -ItemType Directory -Path $destinationFolder -Force\n Write-Verbose -verbose "copying $pattern to $destinationFolder"\n\n if (-not (Test-Path -Path $pattern)) {\n Write-Verbose -verbose "No files found for pattern $pattern"\n continue\n }\n\n Copy-Item -Path $pattern -Destination $destinationFolder -Recurse -verbose\n }\n\n Write-Verbose -verbose "copying done."\n Write-Verbose -verbose "Files to be signed at: $filesToSignDirectory"\n\n Get-ChildItem -Recurse -File $filesToSignDirectory | Select-Object -Property FullName\n displayName: 'Prepare files to be signed'\n\n- task: onebranch.pipeline.signing@1\n displayName: Sign 1st party files\n inputs:\n command: 'sign'\n signing_profile: external_distribution\n files_to_sign: '**\*.psd1;**\*.psm1;**\*.ps1xml;**\*.ps1;**\*.dll;**\*.exe;**\pwsh'\n search_root: $(Pipeline.Workspace)/toBeSigned\n\n- task: onebranch.pipeline.signing@1\n displayName: Sign pwsh.exe with Windows cert\n inputs:\n command: 'sign'\n cp_code: '203'\n files_to_sign: '**\pwsh.exe'\n search_root: $(Pipeline.Workspace)/toBeSigned\n\n- pwsh: |\n if (Test-Path $(Pipeline.Workspace)/toBeSigned/pwsh.exe) {\n Write-Verbose -Verbose "pwsh.exe is found, verifying signature"\n $signature = Get-AuthenticodeSignature -FilePath $(Pipeline.Workspace)/toBeSigned/pwsh.exe\n if ($signature.SignerCertificate.Issuer -notmatch '^CN=Microsoft Windows Production.*') {\n Write-Error -ErrorAction Stop "pwsh.exe is not signed by Microsoft"\n }\n else {\n Write-Verbose -Verbose "pwsh.exe is signed by Microsoft"\n }\n }\n else {\n Write-Verbose -Verbose "pwsh.exe is not found, skipping"\n }\n\n displayName: 'Verify windows signature'\n\n- pwsh : |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture environment\n\n- pwsh: |\n Import-Module $(PowerShellRoot)/build.psm1 -Force\n Import-Module $(PowerShellRoot)/tools/packaging -Force\n\n $BuildPath = (Get-Item '${{ parameters.binPath }}').FullName\n Write-Verbose -Verbose -Message "BuildPath: $BuildPath"\n\n ## copy all files to be signed to build folder\n Update-PSSignedBuildFolder -BuildPath $BuildPath -SignedFilesPath '$(Pipeline.Workspace)/toBeSigned'\n\n $dlls = Get-ChildItem $BuildPath/*.dll, $BuildPath/*.exe -Recurse\n $signatures = $dlls | Get-AuthenticodeSignature\n $missingSignatures = $signatures | Where-Object { $_.status -eq 'notsigned' -or $_.SignerCertificate.Issuer -notmatch '^CN=Microsoft.*'}| select-object -ExpandProperty Path\n\n Write-Verbose -verbose "to be signed:`r`n $($missingSignatures | Out-String)"\n\n $filesToSignDirectory = "$(Pipeline.Workspace)/thirdPartyToBeSigned"\n if (Test-Path $filesToSignDirectory) {\n Remove-Item -Path $filesToSignDirectory -Recurse -Force\n }\n $null = New-Item -ItemType Directory -Path $filesToSignDirectory -Force -Verbose\n\n $missingSignatures | ForEach-Object {\n $pathWithoutLeaf = Split-Path $_\n $relativePath = $pathWithoutLeaf.replace($BuildPath,'')\n Write-Verbose -Verbose -Message "relativePath: $relativePath"\n $targetDirectory = Join-Path -Path $filesToSignDirectory -ChildPath $relativePath\n Write-Verbose -Verbose -Message "targetDirectory: $targetDirectory"\n if(!(Test-Path $targetDirectory))\n {\n $null = New-Item -ItemType Directory -Path $targetDirectory -Force -Verbose\n }\n Copy-Item -Path $_ -Destination $targetDirectory\n }\n displayName: Create ThirdParty Signing Folder\n\n- task: onebranch.pipeline.signing@1\n displayName: Sign 3rd Party files\n inputs:\n command: 'sign'\n signing_profile: $(msft_3rd_party_cert_id)\n files_to_sign: '**\*.dll;**\*.exe'\n search_root: $(Pipeline.Workspace)/thirdPartyToBeSigned\n\n- pwsh: |\n Get-ChildItem '$(Pipeline.Workspace)/thirdPartyToBeSigned/*'\n displayName: Capture ThirdParty Signed files\n\n- pwsh: |\n Import-Module '$(PowerShellRoot)/build.psm1' -Force\n Import-Module '$(PowerShellRoot)/tools/packaging' -Force\n $isGlobalTool = '${{ parameters.globalTool }}' -eq 'true'\n\n if (-not $isGlobalTool) {\n $pathForUpload = New-Item -ItemType Directory -Path '$(ob_outputDirectory)/Signed-$(Runtime)' -Force\n Write-Verbose -Verbose -Message "pathForUpload: $pathForUpload"\n Copy-Item -Path '${{ parameters.binPath }}\*' -Destination $pathForUpload -Recurse -Force -Verbose\n Write-Verbose -Verbose -Message "Files copied to $pathForUpload"\n }\n else {\n $pathForUpload = '${{ parameters.binPath }}'\n }\n\n Write-Verbose "Copying third party signed files to the build folder"\n $thirdPartySignedFilesPath = (Get-Item '$(Pipeline.Workspace)/thirdPartyToBeSigned').FullName\n Update-PSSignedBuildFolder -BuildPath $pathForUpload -SignedFilesPath $thirdPartySignedFilesPath\n\n displayName: 'Copy signed files for upload'\n\n- template: /.pipelines/templates/step/finalize.yml@self\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\obp-file-signing.yml
obp-file-signing.yml
YAML
8,673
0.8
0.059459
0.019231
python-kit
565
2024-03-22T18:26:59.134698
BSD-3-Clause
false
134e38280fd9256bb6c24586181b3d6d
steps:\n - pwsh: |\n Write-Verbose -Verbose "Deploy Box Product Pathway Does Not Support the `"checkout`" task"\n if ($ENV:BUILD_REASON -eq 'PullRequest') {\n throw 'We dont support PRs'\n }\n \n Write-Verbose -Verbose $ENV:BUILD_SOURCEBRANCH\n $branchName = $ENV:BUILD_SOURCEBRANCH -replace '^refs/heads/'\n Write-Verbose -Verbose "Branch Name: $branchName"\n git clone --depth 1 --branch $branchName https://$(mscodehubCodeReadPat)@mscodehub.visualstudio.com/PowerShellCore/_git/PowerShell '$(Pipeline.Workspace)/PowerShell'\n cd $(Pipeline.Workspace)/PowerShell\n displayName: Checkout Powershell Repository\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\release-checkout-pwsh-repo.yml
release-checkout-pwsh-repo.yml
YAML
655
0.8
0.076923
0
vue-tools
364
2024-09-15T13:18:53.852048
Apache-2.0
false
63e6f52619448ec7f6754e7cf3f66d82
jobs:\n- job: CreateMSIXBundle\n displayName: Create .msixbundle file\n pool:\n type: windows\n\n variables:\n - group: msixTools\n - group: 'Azure Blob variable group'\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n\n steps:\n - template: release-SetReleaseTagandContainerName.yml@self\n\n - download: PSPackagesOfficial\n artifact: drop_windows_package_package_win_arm64\n displayName: Download arm64 msix\n patterns: '**/*.msix'\n\n - download: PSPackagesOfficial\n artifact: drop_windows_package_package_win_x64\n displayName: Download x64 msix\n patterns: '**/*.msix'\n\n - download: PSPackagesOfficial\n artifact: drop_windows_package_package_win_x86\n displayName: Download x86 msix\n patterns: '**/*.msix'\n \n # Finds the makeappx tool on the machine with image: 'onebranch.azurecr.io/windows/ltsc2022/vse2022:latest'\n - pwsh: |\n $cmd = Get-Command makeappx.exe -ErrorAction Ignore\n if ($cmd) {\n Write-Verbose -Verbose 'makeappx available in PATH'\n $exePath = $cmd.Source\n } else {\n $toolsDir = '$(Pipeline.Workspace)\releasePipeline\tools'\n New-Item $toolsDir -Type Directory -Force > $null\n $makeappx = Get-ChildItem -Recurse 'C:\Program Files (x86)\Windows Kits\10\makeappx.exe' |\n Where-Object { $_.DirectoryName -match 'x64' } |\n Select-Object -Last 1\n $exePath = $makeappx.FullName\n Write-Verbose -Verbose 'makeappx was found:'\n }\n $vstsCommandString = "vso[task.setvariable variable=MakeAppxPath]$exePath"\n Write-Host "sending " + $vstsCommandString\n Write-Host "##$vstsCommandString"\n displayName: Find makeappx tool\n retryCountOnTaskFailure: 1\n\n - pwsh: |\n $sourceDir = '$(Pipeline.Workspace)\releasePipeline\msix'\n $null = New-Item -Path $sourceDir -ItemType Directory -Force\n\n $msixFiles = Get-ChildItem -Path "$(Pipeline.Workspace)/PSPackagesOfficial/*.msix" -Recurse\n foreach ($msixFile in $msixFiles) {\n $null = Copy-Item -Path $msixFile.FullName -Destination $sourceDir -Force -Verbose\n }\n\n $file = Get-ChildItem $sourceDir | Select-Object -First 1\n $prefix = ($file.BaseName -split "-win")[0]\n $pkgName = "$prefix.msixbundle"\n Write-Verbose -Verbose "Creating $pkgName"\n\n $makeappx = '$(MakeAppxPath)'\n $outputDir = "$sourceDir\output"\n New-Item $outputDir -Type Directory -Force > $null\n & $makeappx bundle /d $sourceDir /p "$outputDir\$pkgName"\n\n Get-ChildItem -Path $sourceDir -Recurse\n $vstsCommandString = "vso[task.setvariable variable=BundleDir]$outputDir"\n Write-Host "sending " + $vstsCommandString\n Write-Host "##$vstsCommandString"\n displayName: Create MsixBundle\n retryCountOnTaskFailure: 1\n\n - task: onebranch.pipeline.signing@1\n displayName: Sign MsixBundle\n inputs:\n command: 'sign'\n signing_profile: $(MSIXProfile)\n files_to_sign: '**/*.msixbundle'\n search_root: '$(BundleDir)'\n \n - pwsh: |\n $signedBundle = Get-ChildItem -Path $(BundleDir) -Filter "*.msixbundle" -File\n Write-Verbose -Verbose "Signed bundle: $signedBundle"\n\n Copy-Item -Path $signedBundle -Destination $(ob_outputDirectory) -Verbose\n\n Write-Verbose -Verbose "Uploaded Bundle:"\n Get-ChildItem -Path $(ob_outputDirectory) | Write-Verbose -Verbose\n displayName: Upload msixbundle to Artifacts\n\n - task: AzurePowerShell@5\n displayName: Upload msix to blob\n inputs:\n azureSubscription: az-blob-cicd-infra\n scriptType: inlineScript\n azurePowerShellVersion: LatestVersion\n pwsh: true\n inline: |\n $containerName = '$(OutputVersion.AzureVersion)-private'\n $storageAccount = '$(StorageAccount)'\n\n $storageContext = New-AzStorageContext -StorageAccountName $storageAccount -UseConnectedAccount\n\n if ($env:BundleDir) {\n $bundleFile = Get-Item "$env:BundleDir\*.msixbundle"\n $blobName = $bundleFile | Split-Path -Leaf\n $existing = Get-AzStorageBlob -Container $containerName -Blob $blobName -Context $storageContext -ErrorAction Ignore\n if ($existing) {\n Write-Verbose -Verbose "MSIX bundle already exists at '$storageAccount/$containerName/$blobName', removing first."\n $existingBlob | Remove-AzStorageBlob -ErrorAction Stop -Verbose\n }\n\n Write-Verbose -Verbose "Uploading $bundleFile to $containerName/$blobName"\n Set-AzStorageBlobContent -File $bundleFile -Container $containerName -Blob $blobName -Context $storageContext -Force\n }\n else{\n throw "BundleDir not found"\n }\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\release-create-msix.yml
release-create-msix.yml
YAML
4,892
0.8
0.02439
0.009615
awesome-app
152
2024-03-24T06:05:12.648451
GPL-3.0
false
080f7201d0a0ba21c41276604d0608b7
jobs:\n- job: upload_packages\n displayName: Upload packages\n condition: succeeded()\n pool:\n type: windows\n variables:\n - template: ./variable/release-shared.yml@self\n parameters:\n REPOROOT: $(Build.SourcesDirectory)\n SBOM: true\n\n steps:\n - pwsh: |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture environment variables\n \n - download: PSPackagesOfficial\n artifact: drop_linux_package_deb\n displayName: Download linux deb packages\n\n - download: PSPackagesOfficial\n artifact: drop_linux_package_fxdependent\n displayName: Download linux fx packages\n\n - download: PSPackagesOfficial\n artifact: drop_linux_package_mariner_arm64\n displayName: Download linux mariner packages\n\n - download: PSPackagesOfficial\n artifact: drop_linux_package_mariner_x64\n displayName: Download linux mariner x64 packages\n\n - download: PSPackagesOfficial\n artifact: drop_linux_package_minSize\n displayName: Download linux min packages\n\n - download: PSPackagesOfficial\n artifact: drop_linux_package_rpm\n displayName: Download linux rpm packages\n\n - download: PSPackagesOfficial\n artifact: drop_linux_package_tar\n displayName: Download linux tar packages\n\n - download: PSPackagesOfficial\n artifact: drop_linux_package_tar_alpine\n displayName: Download linux tar alpine packages\n\n - download: PSPackagesOfficial\n artifact: drop_linux_package_tar_alpine_fxd\n displayName: Download linux tar alpine fxd packages\n\n - download: PSPackagesOfficial\n artifact: drop_linux_package_tar_arm\n displayName: Download linux tar arm packages\n\n - download: PSPackagesOfficial\n artifact: drop_linux_package_tar_arm64\n displayName: Download linux tar arm 64 packages\n\n - download: PSPackagesOfficial\n artifact: drop_nupkg_build_nupkg\n displayName: Download nupkg packages\n\n - download: PSPackagesOfficial\n artifact: drop_windows_package_package_win_arm64\n displayName: Download windows arm64 packages\n\n - download: PSPackagesOfficial\n artifact: drop_windows_package_package_win_fxdependent\n displayName: Download windows fxdependent packages\n\n - download: PSPackagesOfficial\n artifact: drop_windows_package_package_win_fxdependentWinDesktop\n displayName: Download windows fxdependentWinDesktop packages\n\n - download: PSPackagesOfficial\n artifact: drop_windows_package_package_win_minsize\n displayName: Download windows minsize packages\n\n - download: PSPackagesOfficial\n artifact: drop_windows_package_package_win_x64\n displayName: Download windows x64 packages\n\n - download: PSPackagesOfficial\n artifact: drop_windows_package_package_win_x86\n displayName: Download windows x86 packages\n\n - download: PSPackagesOfficial\n artifact: macos-pkgs\n displayName: Download macos tar packages\n\n - download: PSPackagesOfficial\n artifact: drop_mac_package_sign_package_macos_arm64\n displayName: Download macos arm packages\n\n - download: PSPackagesOfficial\n artifact: drop_mac_package_sign_package_macos_x64\n displayName: Download macos x64 packages\n\n - pwsh: |\n Get-ChildItem '$(Pipeline.Workspace)/PSPackagesOfficial' -Recurse | Select-Object -ExpandProperty FullName\n displayName: 'Capture downloads'\n \n - pwsh: |\n $PackagesPath = '$(Pipeline.Workspace)/PSPackagesOfficial'\n Write-Verbose -Verbose "Copying Github Release files in $PackagesPath to use in Release Pipeline"\n \n Write-Verbose -Verbose "Creating output directory for GitHub Release files: $(ob_outputDirectory)/GitHubPackages"\n New-Item -Path $(ob_outputDirectory)/GitHubPackages -ItemType Directory -Force\n Get-ChildItem -Path "$PackagesPath/*" -Recurse | \n Where-Object { $_.Extension -notin '.msix', '.nupkg' } |\n Where-Object { $_.Extension -in '.gz', '.pkg', '.msi', '.zip', '.deb', '.rpm', '.zip' } |\n Copy-Item -Destination $(ob_outputDirectory)/GitHubPackages -Recurse -Verbose\n \n Write-Verbose -Verbose "Creating output directory for NuGet packages: $(ob_outputDirectory)/NuGetPackages"\n New-Item -Path $(ob_outputDirectory)/NuGetPackages -ItemType Directory -Force\n Get-ChildItem -Path "$PackagesPath/*" -Recurse | \n Where-Object { $_.Extension -eq '.nupkg' } | \n Copy-Item -Destination $(ob_outputDirectory)/NuGetPackages -Recurse -Verbose\n displayName: Copy downloads to Artifacts\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\release-download-packages.yml
release-download-packages.yml
YAML
4,430
0.8
0.016393
0
awesome-app
575
2025-03-07T00:14:59.016046
MIT
false
662f72fe671ce3e8726ae83bf4f867d3
parameters:\n - name: skipPublish\n type: boolean\n\njobs:\n- job: GithubReleaseDraft\n displayName: Create GitHub Release Draft\n condition: succeeded()\n pool:\n type: release\n os: windows\n templateContext:\n inputs:\n - input: pipelineArtifact\n artifactName: drop_setReleaseTagAndChangelog_SetTagAndChangelog\n - input: pipelineArtifact\n pipeline: PSPackagesOfficial\n artifactName: drop_upload_upload_packages\n variables:\n - template: ./variable/release-shared.yml@self\n parameters:\n RELEASETAG: $[ stageDependencies.setReleaseTagAndChangelog.setTagAndChangelog.outputs['OutputReleaseTag.releaseTag'] ]\n\n steps:\n - task: PowerShell@2\n inputs:\n targetType: inline\n script: |\n Write-Verbose -Verbose "Release Tag: $(ReleaseTag)"\n Get-ChildItem Env: | Out-String -Stream | Write-Verbose -Verbose\n displayName: 'Capture Environment Variables'\n\n - template: release-install-pwsh.yml\n\n - task: PowerShell@2\n inputs:\n targetType: inline\n pwsh: true\n script: |\n $Path = "$(Pipeline.Workspace)/GitHubPackages"\n $OutputPath = Join-Path $Path 'hashes.sha256'\n $packages = Get-ChildItem -Path $Path -Include * -Recurse -File\n $checksums = $packages |\n ForEach-Object {\n Write-Verbose -Verbose "Generating checksum file for $($_.FullName)"\n $packageName = $_.Name\n $hash = (Get-FileHash -Path $_.FullName -Algorithm SHA256).Hash.ToLower()\n # the '*' before the packagename signifies it is a binary\n "$hash *$packageName"\n }\n $checksums | Out-File -FilePath $OutputPath -Force\n $fileContent = Get-Content -Path $OutputPath -Raw | Out-String\n Write-Verbose -Verbose -Message $fileContent\n displayName: Add sha256 hashes\n \n - task: PowerShell@2\n inputs:\n targetType: inline\n pwsh: true\n script: |\n Get-ChildItem $(Pipeline.Workspace) -recurse | Select-Object -ExpandProperty FullName\n displayName: List all files in the workspace\n\n - task: PowerShell@2\n inputs:\n targetType: inline\n pwsh: true\n script: |\n $releaseVersion = '$(ReleaseTag)' -replace '^v',''\n Write-Verbose -Verbose "Available modules: "\n Get-Module | Write-Verbose -Verbose\n\n $filePath = Get-ChildItem -Path "$(Pipeline.Workspace)/CHANGELOG" -Filter '*.md' | Select-Object -First 1 -ExpandProperty FullName\n \n if (-not (Test-Path $filePath)) {\n throw "$filePath not found"\n }\n \n $changelog = Get-Content -Path $filePath\n \n $headingPattern = "^## \[\d+\.\d+\.\d+"\n $headingStartLines = $changelog | Select-String -Pattern $headingPattern | Select-Object -ExpandProperty LineNumber\n $startLine = $headingStartLines[0]\n $endLine = $headingStartLines[1] - 1\n \n $clContent = $changelog | Select-Object -Skip ($startLine-1) -First ($endLine - $startLine) | Out-String\n \n Write-Verbose -Verbose "Selected content: `n$clContent"\n\n $releaseNotesFilePath = "$(Pipeline.Workspace)/release-notes.md"\n $clContent | Out-File -FilePath $releaseNotesFilePath -Encoding utf8\n \n Write-Host "##vso[task.setvariable variable=ReleaseNotesFilePath;]$releaseNotesFilePath"\n \n #if name has prelease then make prerelease true as a variable\n if ($releaseVersion -like '*-*') {\n Write-Host "##vso[task.setvariable variable=IsPreRelease;]true"\n } else {\n Write-Host "##vso[task.setvariable variable=IsPreRelease;]false"\n }\n displayName: Set variables for GitHub release task\n\n - pwsh: |\n Write-Host "ReleaseNotes content:"\n Get-Content "$(Pipeline.Workspace)/release-notes.md" -Raw | Out-String -width 9999 | Write-Host\n displayName: Verify Release Notes\n\n - task: GitHubRelease@1\n inputs:\n gitHubConnection: GitHubReleasePAT\n repositoryName: PowerShell/PowerShell\n target: master\n assets: '$(Pipeline.Workspace)/GitHubPackages/*'\n tagSource: 'userSpecifiedTag'\n tag: '$(ReleaseTag)'\n isDraft: true\n addChangeLog: false\n action: 'create'\n releaseNotesFilePath: '$(ReleaseNotesFilePath)'\n isPrerelease: '$(IsPreRelease)'\n\n- job: NuGetPublish\n displayName: Publish to NuGet\n condition: succeeded()\n pool:\n type: release\n os: windows\n templateContext:\n inputs:\n - input: pipelineArtifact\n pipeline: PSPackagesOfficial\n artifactName: drop_upload_upload_packages\n variables:\n - template: ./variable/release-shared.yml@self\n parameters:\n VERSION: $[ stageDependencies.setReleaseTagAndChangelog.SetTagAndChangelog.outputs['OutputVersion.Version'] ]\n\n steps:\n - template: release-install-pwsh.yml\n\n - pwsh: |\n Write-Verbose -Verbose "Version: $(Version)"\n Get-ChildItem Env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: 'Capture Environment Variables'\n\n - pwsh: |\n #Exclude all global tool packages. Their names start with 'PowerShell.'\n $null = New-Item -ItemType Directory -Path "$(Pipeline.Workspace)/release"\n Copy-Item "$(Pipeline.Workspace)/NuGetPackages/*.nupkg" -Destination "$(Pipeline.Workspace)/release" -Exclude "PowerShell.*.nupkg" -Force -Verbose\n\n $releaseVersion = '$(Version)'\n $globalToolPath = "$(Pipeline.Workspace)/NuGetPackages/PowerShell.$releaseVersion.nupkg"\n\n if ($releaseVersion -notlike '*-*') {\n # Copy the global tool package for stable releases\n Copy-Item $globalToolPath -Destination "$(Pipeline.Workspace)/release"\n }\n\n Write-Verbose -Verbose "The .nupkgs below will be pushed:"\n Get-ChildItem "$(Pipeline.Workspace)/release" -recurse\n displayName: Download and capture nupkgs\n condition: and(ne('${{ parameters.skipPublish }}', 'false'), succeeded())\n\n - task: NuGetCommand@2\n displayName: 'NuGet push'\n condition: and(ne('${{ parameters.skipPublish }}', 'false'), succeeded())\n inputs:\n command: push\n packagesToPush: '$(Pipeline.Workspace)/release/*.nupkg'\n nuGetFeedType: external\n publishFeedCredentials: PowerShellNuGetOrgPush\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\release-githubNuget.yml
release-githubNuget.yml
YAML
6,225
0.8
0.040936
0.027397
vue-tools
5
2025-06-02T05:09:35.775907
Apache-2.0
false
7a2f666861861c7be1e32e124a1e0b72
steps:\n - task: PowerShell@2\n inputs:\n targetType: inline\n script: |\n $localInstallerPath = Get-ChildItem -Path "$(Pipeline.Workspace)/GitHubPackages" -Filter '*win-x64.msi' | Select-Object -First 1 -ExpandProperty FullName\n if (Test-Path -Path $localInstallerPath) {\n Write-Verbose -Verbose "Installer found at $localInstallerPath"\n } else {\n throw "Installer not found"\n }\n Write-Verbose -Verbose "Installing PowerShell via msiexec"\n Start-Process -FilePath msiexec -ArgumentList "/package $localInstallerPath /quiet REGISTER_MANIFEST=1" -Wait -NoNewWindow\n $pwshPath = Get-ChildItem -Directory -Path 'C:\Program Files\PowerShell\7*' | Select-Object -First 1 -ExpandProperty FullName\n if (Test-Path -Path $pwshPath) {\n Write-Verbose -Verbose "PowerShell installed at $pwshPath"\n Write-Verbose -Verbose "Adding pwsh to env:PATH"\n Write-Host "##vso[task.prependpath]$pwshPath"\n } else {\n throw "PowerShell not installed"\n }\n displayName: Install pwsh 7\n\n - task: PowerShell@2\n inputs:\n targetType: inline\n pwsh: true\n script: |\n Write-Verbose -Verbose "Pwsh 7 Installed"\n Write-Verbose -Verbose "env:Path: "\n $env:PATH -split ';' | ForEach-Object {\n Write-Verbose -Verbose $_\n }\n displayName: Check pwsh 7 installation\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\release-install-pwsh.yml
release-install-pwsh.yml
YAML
1,419
0.8
0.058824
0
react-lib
145
2023-08-08T22:01:17.923930
Apache-2.0
false
1a681c3769a9b4e0f70260a078430f2e
parameters:\n - name: SkipPSInfraInstallers\n displayName: Skip Copying Archives and Installers to PSInfrastructure Public Location\n type: boolean\n default: false\n\njobs:\n- template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Approve Copy release packages to PSInfra storage\n jobName: CopyReleaseBlobApproval\n instructions: |\n Approval for Copy release packages to PSInfra storage\n\n- job: PSInfraReleaseBlobPublic\n displayName: Copy release to PSInfra storage\n dependsOn: CopyReleaseBlobApproval\n condition: and(succeeded(), ne('${{ parameters.SkipPSInfraInstallers }}', true))\n pool:\n name: PowerShell1ES\n type: windows\n isCustom: true\n demands:\n - ImageOverride -equals PSMMS2019-Secure\n\n\n variables:\n - group: 'PSInfraStorage'\n - group: 'Azure Blob variable group'\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n - name: ob_sdl_codeql_compiled_enabled\n value: false\n\n steps:\n - checkout: self\n clean: true\n env:\n ob_restore_phase: true # This ensures checkout is done at the beginning of the restore phase\n\n - template: /.pipelines/templates/SetVersionVariables.yml@self\n parameters:\n ReleaseTagVar: $(ReleaseTagVar)\n CreateJson: yes\n UseJson: no\n\n - pwsh: |\n Get-ChildItem Env:\n displayName: 'Capture Environment Variables'\n\n - task: AzurePowerShell@5\n displayName: Copy blobs to PSInfra storage\n inputs:\n azureSubscription: az-blob-cicd-infra\n scriptType: inlineScript\n azurePowerShellVersion: LatestVersion\n pwsh: true\n inline: |\n $sourceStorageAccountName = '$(StorageAccount)'\n $destinationStorageAccountName = '$(PSInfraStorageAccount)'\n $destinationContainerName = '$web'\n $destinationPrefix = 'install/$(ReleaseTagVar)'\n\n $sourceContext = New-AzStorageContext -StorageAccountName $sourceStorageAccountName\n Write-Verbose -Verbose "Source context: $($sourceContext.BlobEndPoint)"\n\n $destinationContext = New-AzStorageContext -StorageAccountName $destinationStorageAccountName\n Write-Verbose -Verbose "Destination context: $($destinationContext.BlobEndPoint)"\n\n foreach ($sourceContainerName in '$(AzureVersion)', '$(AzureVersion)-gc') {\n $blobs = Get-AzStorageBlob -Context $sourceContext -Container $sourceContainerName\n\n Write-Verbose -Verbose "Blobs found in $sourceContainerName"\n $blobs.Name | Write-Verbose -Verbose\n\n Write-Verbose -Verbose "Copying blobs from $sourceContainerName to $destinationContainerName/$destinationPrefix"\n\n foreach ($blob in $blobs) {\n $sourceBlobName = $blob.Name\n Write-Verbose -Verbose "sourceBlobName = $sourceBlobName"\n\n $destinationBlobName = "$destinationPrefix/$sourceBlobName"\n Write-Verbose -Verbose "destinationBlobName = $destinationBlobName"\n $existingBlob = Get-AzStorageBlob -Blob $destinationBlobName -Container $destinationContainerName -Context $destinationContext -ErrorAction Ignore\n if ($existingBlob) {\n Write-Verbose -Verbose "Blob $destinationBlobName already exists in '$destinationStorageAccountName/$destinationContainerName', removing before copy."\n $existingBlob | Remove-AzStorageBlob -ErrorAction Stop -Verbose\n }\n\n Copy-AzStorageBlob -SourceContext $sourceContext -DestinationContext $destinationContext -SrcContainer $sourceContainerName -SrcBlob $sourceBlobName -DestContainer $destinationContainerName -DestBlob $destinationBlobName -Force -Verbose -Confirm:$false\n }\n }\n\n\n- template: /.pipelines/templates/approvalJob.yml@self\n parameters:\n displayName: Approve Copy Global tool packages to PSInfra storage\n jobName: CopyBlobApproval\n instructions: |\n Approval for Copy global tool packages to PSInfra storage\n\n- job: PSInfraBlobPublic\n displayName: Copy global tools to PSInfra storage\n dependsOn: CopyBlobApproval\n pool:\n name: PowerShell1ES\n type: windows\n isCustom: true\n demands:\n - ImageOverride -equals PSMMS2019-Secure\n\n variables:\n - group: 'PSInfraStorage'\n - group: 'Azure Blob variable group'\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n\n steps:\n - checkout: self\n clean: true\n env:\n ob_restore_phase: true # This ensures checkout is done at the beginning of the restore phase\n\n - template: /.pipelines/templates/SetVersionVariables.yml@self\n parameters:\n ReleaseTagVar: $(ReleaseTagVar)\n CreateJson: yes\n UseJson: no\n\n - pwsh: |\n Get-ChildItem Env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: 'Capture Environment Variables'\n\n - task: AzurePowerShell@5\n displayName: Copy blobs to PSInfra storage\n inputs:\n azureSubscription: az-blob-cicd-infra\n scriptType: inlineScript\n azurePowerShellVersion: LatestVersion\n pwsh: true\n inline: |\n $sourceStorageAccountName = '$(StorageAccount)'\n $sourceContainerName = '$(AzureVersion)-nuget'\n $prefix = 'globaltool'\n\n $destinationStorageAccountName = '$(PSInfraStorageAccount)'\n $destinationContainerName = '$web'\n $destinationPrefix = 'tool/$(Version)'\n\n $sourceContext = New-AzStorageContext -StorageAccountName $sourceStorageAccountName\n Write-Verbose -Verbose "Source context: $($sourceContext.BlobEndPoint)"\n\n $destinationContext = New-AzStorageContext -StorageAccountName $destinationStorageAccountName\n Write-Verbose -Verbose "Destination context: $($destinationContext.BlobEndPoint)"\n\n $blobs = Get-AzStorageBlob -Context $sourceContext -Container $sourceContainerName -Prefix $prefix\n\n Write-Verbose -Verbose "Blobs found in $sourceContainerName"\n $blobs.Name | Write-Verbose -Verbose\n\n Write-Verbose -Verbose "Copying blobs from $sourceContainerName to $destinationContainerName/$destinationPrefix"\n\n foreach ($blob in $blobs) {\n $sourceBlobName = $blob.Name\n Write-Verbose -Verbose "sourceBlobName = $sourceBlobName"\n\n $destinationBlobName = $sourceBlobName -replace "$prefix", $destinationPrefix\n Write-Verbose -Verbose "destinationBlobName = $destinationBlobName"\n\n Copy-AzStorageBlob -SourceContext $sourceContext -DestinationContext $destinationContext -SrcContainer $sourceContainerName -SrcBlob $sourceBlobName -DestContainer $destinationContainerName -DestBlob $destinationBlobName -Force -Verbose -Confirm:$false\n }\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\release-MakeBlobPublic.yml
release-MakeBlobPublic.yml
YAML
7,267
0.8
0.01676
0
vue-tools
654
2024-04-18T09:36:43.392175
BSD-3-Clause
false
22f3f400794a640c4dbd8ea544d9ecb3
parameters:\n- name: skipPublish\n type: boolean\n default: false\n\nstages:\n- stage: PrepForEV2\n displayName: 'Copy and prep all files needed for EV2 stage'\n jobs:\n - job: CopyEV2FilesToArtifact\n displayName: 'Copy EV2 Files to Artifact'\n pool:\n type: linux\n variables:\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: repoRoot\n value: '$(Build.SourcesDirectory)/PowerShell'\n - name: ev2ServiceGroupRootFolder\n value: '$(Build.SourcesDirectory)/PowerShell/.pipelines/EV2Specs/ServiceGroupRoot'\n - name: ev2ParametersFolder\n value: '$(Build.SourcesDirectory)/PowerShell/.pipelines/EV2Specs/ServiceGroupRoot/Parameters'\n - group: 'mscodehub-code-read-akv'\n - group: 'packages.microsoft.com'\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n steps:\n - checkout: self ## the global setting on lfs didn't work\n lfs: false\n env:\n ob_restore_phase: true\n\n - template: release-SetReleaseTagandContainerName.yml\n parameters:\n restorePhase: true\n \n - pwsh: |\n $packageVersion = '$(OutputReleaseTag.ReleaseTag)'.ToLowerInvariant() -replace '^v',''\n $vstsCommandString = "vso[task.setvariable variable=packageVersion]$packageVersion"\n Write-Host "sending " + $vstsCommandString\n Write-Host "##$vstsCommandString"\n displayName: Set Package version\n env:\n ob_restore_phase: true\n \n - pwsh: |\n $branch = 'mirror-target'\n $gitArgs = "clone",\n "--verbose",\n "--branch",\n "$branch",\n "https://$(mscodehubCodeReadPat)@mscodehub.visualstudio.com/PowerShellCore/_git/Internal-PowerShellTeam-Tools",\n '$(Pipeline.Workspace)/tools'\n $gitArgs | Write-Verbose -Verbose\n git $gitArgs\n displayName: Clone Internal-PowerShellTeam-Tools from MSCodeHub\n env:\n ob_restore_phase: true\n\n - pwsh: |\n Get-ChildItem Env: | Out-String -Stream | write-Verbose -Verbose\n displayName: 'Capture Environment Variables'\n env:\n ob_restore_phase: true\n\n - pwsh: |\n Get-ChildItem '$(Build.SourcesDirectory)'\n displayName: 'Capture BuildDirectory'\n env:\n ob_restore_phase: true\n\n - pwsh: |\n Get-ChildItem '$(Pipeline.Workspace)' -Recurse | Out-String -Stream | write-Verbose -Verbose\n displayName: 'Capture Workspace'\n env:\n ob_restore_phase: true\n\n - pwsh: |\n New-Item -Path '$(ev2ParametersFolder)' -ItemType Directory\n displayName: 'Create Parameters folder under EV2Specs folder'\n env:\n ob_restore_phase: true\n\n - task: PipAuthenticate@1\n inputs:\n artifactFeeds: 'PowerShellCore/PowerShellCore_PublicPackages'\n displayName: 'Pip Authenticate'\n env:\n ob_restore_phase: true\n\n - pwsh: |\n python3 -m pip install --upgrade pip\n pip --version --verbose\n\n Write-Verbose -Verbose "Download pmc-cli to folder without installing it"\n $pythonDlFolderPath = Join-Path '$(ev2ServiceGroupRootFolder)/Shell/Run' -ChildPath "python_dl"\n pip download -d $pythonDlFolderPath pmc-cli --platform=manylinux_2_17_x86_64 --only-binary=:all: --verbose\n displayName: 'Download pmc-cli package'\n env:\n ob_restore_phase: true\n\n - download: PSPackagesOfficial\n artifact: 'drop_linux_package_deb'\n displayName: 'Download artifact containing .deb_amd64.deb file from PSPackagesOfficial triggering pipeline'\n env:\n ob_restore_phase: true\n\n - download: PSPackagesOfficial\n artifact: 'drop_linux_package_rpm'\n displayName: 'Download artifact containing .rh.x64_86.rpm file from PSPackagesOfficial triggering pipeline'\n env:\n ob_restore_phase: true\n\n - download: PSPackagesOfficial\n artifact: 'drop_linux_package_mariner_x64'\n displayName: 'Download artifact containing .cm.x86_64.rpm file from PSPackagesOfficial triggering pipeline'\n env:\n ob_restore_phase: true\n\n - download: PSPackagesOfficial\n artifact: 'drop_linux_package_mariner_arm64'\n displayName: 'Download artifact containing .cm.aarch64.rpm file from PSPackagesOfficial triggering pipeline'\n env:\n ob_restore_phase: true\n\n - pwsh: |\n Write-Verbose -Verbose "Copy ESRP signed .deb and .rpm packages"\n $downloadedPipelineFolder = Join-Path '$(Pipeline.Workspace)' -ChildPath 'PSPackagesOfficial'\n $srcFilesFolder = Join-Path -Path '$(Pipeline.Workspace)' -ChildPath 'SourceFiles'\n New-Item -Path $srcFilesFolder -ItemType Directory\n $packagesFolder = Join-Path -Path $srcFilesFolder -ChildPath 'packages'\n New-Item -Path $packagesFolder -ItemType Directory\n\n $packageFiles = Get-ChildItem -Path $downloadedPipelineFolder -Recurse -Directory -Filter "drop_*" | Get-ChildItem -File -Include *.deb, *.rpm\n foreach ($file in $packageFiles)\n {\n Write-Verbose -Verbose "copying file: $($file.FullName)"\n Copy-Item -Path $($file.FullName) -Destination $packagesFolder -Verbose\n }\n\n $packagesTarGzDestination = Join-Path -Path '$(ev2ParametersFolder)' -ChildPath 'packages.tar.gz'\n tar -czvf $packagesTarGzDestination -C $packagesFolder .\n displayName: 'Copy signed .deb and .rpm packages to .tar.gz to pass as a file var to shell extension'\n env:\n ob_restore_phase: true\n\n - pwsh: |\n $pathToPMCMetadataFile = Join-Path -Path '$(ev2ParametersFolder)' -ChildPath 'pmcMetadata.json'\n\n $metadata = Get-Content -Path "$(repoRoot)/tools/metadata.json" -Raw | ConvertFrom-Json\n $metadataHash = @{}\n $skipPublishValue = '${{ parameters.skipPublish }}'\n $metadataHash["ReleaseTag"] = '$(OutputReleaseTag.ReleaseTag)'\n $metadataHash["LTS"] = $metadata.LTSRelease.Latest\n $metadataHash["ForProduction"] = $true\n $metadataHash["SkipPublish"] = [System.Convert]::ToBoolean($skipPublishValue)\n\n $metadataHash | ConvertTo-Json | Out-File $pathToPMCMetadataFile\n\n $mappingFilePath = Join-Path -Path '$(repoRoot)/tools/packages.microsoft.com' -ChildPath 'mapping.json'\n $mappingFilePathExists = Test-Path $mappingFilePath\n $mappingFileEV2Path = Join-Path -Path '$(ev2ParametersFolder)' -ChildPath "mapping.json"\n Write-Verbose -Verbose "Copy mapping.json file at: $mappingFilePath which exists: $mappingFilePathExists to: $mappingFileEV2Path"\n Copy-Item -Path $mappingFilePath -Destination $mappingFileEV2Path\n displayName: 'Create pmcScriptMetadata.json and mapping.json file'\n env:\n ob_restore_phase: true\n\n - pwsh: |\n $pathToJsonFile = Join-Path -Path '$(ev2ServiceGroupRootFolder)' -ChildPath 'RolloutSpec.json'\n $content = Get-Content -Path $pathToJsonFile | ConvertFrom-Json\n $content.RolloutMetadata.Notification.Email.To = '$(PmcEV2SupportEmail)'\n Remove-Item -Path $pathToJsonFile\n $content | ConvertTo-Json -Depth 4 | Out-File $pathToJsonFile\n displayName: 'Replace values in RolloutSpecPath.json'\n env:\n ob_restore_phase: true\n\n - pwsh: |\n $pathToJsonFile = Join-Path -Path '$(ev2ServiceGroupRootFolder)' -ChildPath 'UploadLinux.Rollout.json'\n $content = Get-Content -Path $pathToJsonFile | ConvertFrom-Json\n\n $identityString = "/subscriptions/$(PmcSubscription)/resourcegroups/$(PmcResourceGroup)/providers/Microsoft.ManagedIdentity/userAssignedIdentities/$(PmcMIName)"\n $content.shellExtensions.launch.identity.userAssignedIdentities[0] = $identityString\n\n Remove-Item -Path $pathToJsonFile\n $content | ConvertTo-Json -Depth 6 | Out-File $pathToJsonFile\n displayName: 'Replace values in UploadLinux.Rollout.json file'\n env:\n ob_restore_phase: true\n\n - pwsh: |\n $pathToJsonFile = Join-Path -Path '$(ev2ServiceGroupRootFolder)' -ChildPath 'ServiceModel.json'\n $content = Get-Content -Path $pathToJsonFile | ConvertFrom-Json\n $content.ServiceResourceGroups[0].AzureResourceGroupName = '$(PmcResourceGroup)'\n $content.ServiceResourceGroups[0].AzureSubscriptionId = '$(PmcSubscription)'\n\n Remove-Item -Path $pathToJsonFile\n $content | ConvertTo-Json -Depth 9 | Out-File $pathToJsonFile\n displayName: 'Replace values in ServiceModel.json'\n env:\n ob_restore_phase: true\n\n - pwsh: |\n $settingFilePath = Join-Path '$(ev2ServiceGroupRootFolder)/Shell/Run' -ChildPath 'settings.toml'\n New-Item -Path $settingFilePath -ItemType File\n $pmcMIClientID = '$(PmcMIClientID)'\n $pmcEndpoint = '$(PmcEndpointUrl)'\n\n Add-Content -Path $settingFilePath -Value "[default]"\n Add-Content -Path $settingFilePath -Value "base_url = `"$pmcEndpoint`""\n Add-Content -Path $settingFilePath -Value "auth_type = `"msi`""\n Add-Content -Path $settingFilePath -Value "client_id = `"$pmcMIClientID`""\n displayName: 'Create settings.toml file with MI clientId populated'\n env:\n ob_restore_phase: true\n\n - task: onebranch.pipeline.signing@1\n inputs:\n command: 'sign'\n signing_profile: external_distribution\n files_to_sign: '*.ps1'\n search_root: '$(repoRoot)/.pipelines/EV2Specs/ServiceGroupRoot/Shell/Run'\n displayName: Sign Run.ps1\n \n - pwsh: |\n # folder to tar must have: Run.ps1, settings.toml, python_dl\n $srcPath = Join-Path '$(ev2ServiceGroupRootFolder)' -ChildPath 'Shell'\n $pathToRunTarFile = Join-Path $srcPath -ChildPath "Run.tar"\n tar -cvf $pathToRunTarFile -C $srcPath ./Run\n displayName: 'Create archive for the shell extension'\n\n - task: CopyFiles@2\n inputs:\n SourceFolder: '$(repoRoot)/.pipelines'\n Contents: 'EV2Specs/**'\n TargetFolder: $(ob_outputDirectory)\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\release-prep-for-ev2.yml
release-prep-for-ev2.yml
YAML
9,954
0.8
0.008439
0.004902
vue-tools
235
2025-01-12T13:59:56.555846
MIT
false
a6155888a47f3807a99750f32ba3af09
stages:\n- stage: 'Prod_Release'\n displayName: 'Deploy packages to PMC with EV2'\n dependsOn:\n - PrepForEV2\n variables:\n - name: ob_release_environment\n value: "Production"\n - name: repoRoot\n value: $(Build.SourcesDirectory)\n jobs:\n - job: Prod_ReleaseJob\n displayName: Publish to PMC\n pool:\n type: release\n\n steps:\n - task: DownloadPipelineArtifact@2\n inputs:\n targetPath: '$(Pipeline.Workspace)'\n artifact: drop_PrepForEV2_CopyEv2FilesToArtifact\n displayName: 'Download drop_PrepForEV2_CopyEv2FilesToArtifact artifact that has all files needed'\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n targetPath: '$(Pipeline.Workspace)'\n displayName: 'Download to get EV2 Files'\n\n - task: vsrm-ev2.vss-services-ev2.adm-release-task.ExpressV2Internal@1\n displayName: 'Ev2: Push to PMC'\n inputs:\n UseServerMonitorTask: true\n EndpointProviderType: ApprovalService\n ApprovalServiceEnvironment: Production\n ServiceRootPath: '$(Pipeline.Workspace)/drop_PrepForEV2_CopyEV2FilesToArtifact/EV2Specs/ServiceGroupRoot'\n RolloutSpecPath: '$(Pipeline.Workspace)/drop_PrepForEV2_CopyEV2FilesToArtifact/EV2Specs/ServiceGroupRoot/RolloutSpec.json'\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\release-publish-pmc.yml
release-publish-pmc.yml
YAML
1,283
0.7
0
0
node-utils
142
2024-06-01T15:07:05.745610
Apache-2.0
false
80c0af88ad8f1aef76fb12b0e8ba8a2f
parameters:\n- name: restorePhase\n default: false\n\nsteps:\n- pwsh: |\n $variable = 'releaseTag'\n $branch = $ENV:BUILD_SOURCEBRANCH\n if($branch -notmatch '^.*((release/|rebuild/.*rebuild))')\n {\n throw "Branch name is not in release format: '$branch'"\n }\n\n $releaseTag = $Branch -replace '^.*((release|rebuild)/)'\n $vstsCommandString = "vso[task.setvariable variable=$Variable;isOutput=true]$releaseTag"\n Write-Verbose -Message "setting $Variable to $releaseTag" -Verbose\n Write-Host -Object "##$vstsCommandString"\n name: OutputReleaseTag\n displayName: Set Release Tag\n env:\n ob_restore_phase: ${{ parameters.restorePhase }}\n\n- pwsh: |\n $azureVersion = '$(OutputReleaseTag.ReleaseTag)'.ToLowerInvariant() -replace '\.', '-'\n $vstsCommandString = "vso[task.setvariable variable=AzureVersion;isOutput=true]$azureVersion"\n Write-Host "sending " + $vstsCommandString\n Write-Host "##$vstsCommandString"\n\n $version = '$(OutputReleaseTag.ReleaseTag)'.ToLowerInvariant().Substring(1)\n $vstsCommandString = "vso[task.setvariable variable=Version;isOutput=true]$version"\n Write-Host ("sending " + $vstsCommandString)\n Write-Host "##$vstsCommandString"\n name: OutputVersion\n displayName: Set container name\n env:\n ob_restore_phase: ${{ parameters.restorePhase }}\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\release-SetReleaseTagandContainerName.yml
release-SetReleaseTagandContainerName.yml
YAML
1,319
0.8
0.027778
0
vue-tools
360
2024-03-15T23:32:17.884390
BSD-3-Clause
false
5b07923fb02d740e59d4f693889581b2
jobs:\n- job: setTagAndChangelog\n displayName: Set Tag and Upload Changelog\n condition: succeeded()\n pool:\n type: windows\n variables:\n - group: 'mscodehub-code-read-akv'\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n steps:\n - template: release-SetReleaseTagandContainerName.yml@self\n\n - checkout: self\n clean: true\n env:\n ob_restore_phase: true\n \n - pwsh: |\n Write-Verbose -Verbose "Release Tag: $(OutputReleaseTag.releaseTag)"\n $releaseVersion = '$(OutputReleaseTag.releaseTag)' -replace '^v',''\n Write-Verbose -Verbose "Release Version: $releaseVersion"\n $semanticVersion = [System.Management.Automation.SemanticVersion]$releaseVersion\n\n $isPreview = $semanticVersion.PreReleaseLabel -ne $null\n\n $fileName = if ($isPreview) {\n "preview.md"\n }\n else {\n $semanticVersion.Major.ToString() + "." + $semanticVersion.Minor.ToString() + ".md"\n }\n\n $filePath = "$(Build.SourcesDirectory)/PowerShell/CHANGELOG/$fileName"\n Write-Verbose -Verbose "Selected Log file: $filePath"\n\n if (-not (Test-Path -Path $filePath)) {\n Write-Error "Changelog file not found: $filePath"\n exit 1\n }\n \n Write-Verbose -Verbose "Creating output directory for CHANGELOG: $(ob_outputDirectory)/CHANGELOG"\n New-Item -Path $(ob_outputDirectory)/CHANGELOG -ItemType Directory -Force\n Copy-Item -Path $filePath -Destination $(ob_outputDirectory)/CHANGELOG\n displayName: Upload Changelog\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\release-SetTagAndChangelog.yml
release-SetTagAndChangelog.yml
YAML
1,758
0.7
0.061224
0
python-kit
363
2024-02-15T19:48:52.814217
Apache-2.0
false
ee7226b78ee2df32ca5decf7e8ed11c4
parameters:\n - name: skipPublish\n default: false\n type: boolean\n\njobs:\n- job: PublishSymbols\n displayName: Publish Symbols\n condition: succeeded()\n pool:\n type: windows\n variables:\n - name: runCodesignValidationInjection\n value: false\n - name: NugetSecurityAnalysisWarningLevel\n value: none\n - name: DOTNET_SKIP_FIRST_TIME_EXPERIENCE\n value: 1\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: ob_sdl_codeSignValidation_enabled\n value: false\n - name: ob_sdl_binskim_enabled\n value: false\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n\n steps:\n - checkout: self\n clean: true\n env:\n ob_restore_phase: true # This ensures checkout is done at the beginning of the restore phase\n\n - template: release-SetReleaseTagAndContainerName.yml\n\n - pwsh: |\n Get-ChildItem Env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: 'Capture Environment Variables'\n\n - download: CoOrdinatedBuildPipeline\n artifact: drop_windows_build_windows_x64_release\n patterns: 'symbols.zip'\n displayName: Download winx64\n\n - download: CoOrdinatedBuildPipeline\n artifact: drop_windows_build_windows_x86_release\n patterns: 'symbols.zip'\n displayName: Download winx86\n\n - download: CoOrdinatedBuildPipeline\n artifact: drop_windows_build_windows_arm64_release\n patterns: 'symbols.zip'\n displayName: Download winx64\n\n - pwsh: |\n Write-Verbose -Verbose "Enumerating $(Pipeline.Workspace)\CoOrdinatedBuildPipeline"\n $downloadedArtifacts = Get-ChildItem -Path "$(Pipeline.Workspace)\CoOrdinatedBuildPipeline" -Recurse -Filter 'symbols.zip'\n $downloadedArtifacts\n $expandedRoot = New-Item -Path "$(Pipeline.Workspace)/expanded" -ItemType Directory -Verbose\n $symbolsRoot = New-Item -Path "$(Pipeline.Workspace)/symbols" -ItemType Directory -Verbose\n\n $downloadedArtifacts | ForEach-Object {\n $folderName = (Get-Item (Split-Path $_.FullName)).Name\n Write-Verbose -Verbose "Expanding $($_.FullName) to $expandedRoot/$folderName/$($_.BaseName)"\n $destFolder = New-Item -Path "$expandedRoot/$folderName/$($_.BaseName)/" -ItemType Directory -Verbose\n Expand-Archive -Path $_.FullName -DestinationPath $destFolder -Force\n\n $symbolsToPublish = New-Item -Path "$symbolsRoot/$folderName/$($_.BaseName)" -ItemType Directory -Verbose\n\n Get-ChildItem -Path $destFolder -Recurse -Filter '*.pdb' | ForEach-Object {\n Copy-Item -Path $_.FullName -Destination $symbolsToPublish -Verbose\n }\n }\n\n Write-Verbose -Verbose "Enumerating $symbolsRoot"\n Get-ChildItem -Path $symbolsRoot -Recurse\n $vstsCommandString = "vso[task.setvariable variable=SymbolsPath]$symbolsRoot"\n Write-Verbose -Message "$vstsCommandString" -Verbose\n Write-Host -Object "##$vstsCommandString"\n displayName: Expand and capture symbols folders\n\n - task: PublishSymbols@2\n inputs:\n symbolsFolder: '$(SymbolsPath)'\n searchPattern: '**/*.pdb'\n indexSources: false\n publishSymbols: true\n symbolServerType: teamServices\n detailedLog: true\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\release-symbols.yml
release-symbols.yml
YAML
3,334
0.8
0
0
vue-tools
420
2023-09-14T08:46:42.918646
MIT
false
df941e81bc50673ff208db7f92d61a0e
parameters:\n - name: skipPublish\n default: false\n type: boolean\n\njobs:\n- job: BuildInfoPublish\n displayName: Publish BuildInfo\n condition: succeeded()\n pool:\n name: PowerShell1ES\n type: windows\n isCustom: true\n demands:\n - ImageOverride -equals PSMMS2019-Secure\n variables:\n - name: runCodesignValidationInjection\n value: false\n - name: NugetSecurityAnalysisWarningLevel\n value: none\n - name: DOTNET_SKIP_FIRST_TIME_EXPERIENCE\n value: 1\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - group: 'Azure Blob variable group'\n - name: ob_sdl_codeSignValidation_enabled\n value: false\n - name: ob_sdl_binskim_enabled\n value: false\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n\n steps:\n - checkout: self\n clean: true\n env:\n ob_restore_phase: true # This ensures checkout is done at the beginning of the restore phase\n\n - template: release-SetReleaseTagAndContainerName.yml\n\n - pwsh: |\n Get-ChildItem Env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: 'Capture Environment Variables'\n\n - download: PSPackagesOfficial\n artifact: BuildInfoJson\n displayName: Download build info artifact\n\n - pwsh: |\n $toolsDirectory = '$(Build.SourcesDirectory)/tools'\n Import-Module "$toolsDirectory/ci.psm1"\n $jsonFile = Get-Item "$ENV:PIPELINE_WORKSPACE/PSPackagesOfficial/BuildInfoJson/*.json"\n $fileName = Split-Path $jsonFile -Leaf\n\n $dateTime = [datetime]::UtcNow\n $dateTime = [datetime]::new($dateTime.Ticks - ($dateTime.Ticks % [timespan]::TicksPerSecond), $dateTime.Kind)\n\n $metadata = Get-Content -LiteralPath "$toolsDirectory/metadata.json" -ErrorAction Stop | ConvertFrom-Json\n $stableRelease = $metadata.StableRelease.Latest\n $ltsRelease = $metadata.LTSRelease.Latest\n\n Write-Verbose -Verbose "Writing $jsonFile contents:"\n $buildInfoJsonContent = Get-Content $jsonFile -Encoding UTF8NoBom -Raw\n Write-Verbose -Verbose $buildInfoJsonContent\n\n $buildInfo = $buildInfoJsonContent | ConvertFrom-Json\n $buildInfo.ReleaseDate = $dateTime\n\n $targetFile = "$ENV:PIPELINE_WORKSPACE/$fileName"\n ConvertTo-Json -InputObject $buildInfo | Out-File $targetFile -Encoding ascii\n\n if ($stableRelease -or $fileName -eq "preview.json") {\n Set-BuildVariable -Name CopyMainBuildInfo -Value YES\n } else {\n Set-BuildVariable -Name CopyMainBuildInfo -Value NO\n }\n\n Set-BuildVariable -Name BuildInfoJsonFile -Value $targetFile\n\n ## Create 'lts.json' if it's the latest stable and also a LTS release.\n\n if ($fileName -eq "stable.json") {\n if ($ltsRelease) {\n $ltsFile = "$ENV:PIPELINE_WORKSPACE/lts.json"\n Copy-Item -Path $targetFile -Destination $ltsFile -Force\n Set-BuildVariable -Name LtsBuildInfoJsonFile -Value $ltsFile\n Set-BuildVariable -Name CopyLTSBuildInfo -Value YES\n } else {\n Set-BuildVariable -Name CopyLTSBuildInfo -Value NO\n }\n\n $releaseTag = $buildInfo.ReleaseTag\n $version = $releaseTag -replace '^v'\n $semVersion = [System.Management.Automation.SemanticVersion] $version\n\n $versionFile = "$ENV:PIPELINE_WORKSPACE/$($semVersion.Major)-$($semVersion.Minor).json"\n Copy-Item -Path $targetFile -Destination $versionFile -Force\n Set-BuildVariable -Name VersionBuildInfoJsonFile -Value $versionFile\n Set-BuildVariable -Name CopyVersionBuildInfo -Value YES\n } else {\n Set-BuildVariable -Name CopyVersionBuildInfo -Value NO\n }\n displayName: Create json files\n\n - task: AzurePowerShell@5\n displayName: Upload buildjson to blob\n inputs:\n azureSubscription: az-blob-cicd-infra\n scriptType: inlineScript\n azurePowerShellVersion: LatestVersion\n pwsh: true\n inline: |\n $containerName = '$web'\n $storageAccount = '$(PSInfraStorageAccount)'\n $prefix = "buildinfo"\n\n $storageContext = New-AzStorageContext -StorageAccountName $storageAccount -UseConnectedAccount\n\n if ($env:CopyMainBuildInfo -eq 'YES') {\n $jsonFile = "$env:BuildInfoJsonFile"\n $blobName = Get-Item $jsonFile | Split-Path -Leaf\n Write-Verbose -Verbose "Uploading $jsonFile to $containerName/$prefix/$blobName"\n Set-AzStorageBlobContent -File $jsonFile -Container $containerName -Blob "$prefix/$blobName" -Context $storageContext -Force\n }\n\n if ($env:CopyLTSBuildInfo -eq 'YES') {\n $jsonFile = "$env:LtsBuildInfoJsonFile"\n $blobName = Get-Item $jsonFile | Split-Path -Leaf\n Write-Verbose -Verbose "Uploading $jsonFile to $containerName/$prefix/$blobName"\n Set-AzStorageBlobContent -File $jsonFile -Container $containerName -Blob "$prefix/$blobName" -Context $storageContext -Force\n }\n\n if ($env:CopyVersionBuildInfo -eq 'YES') {\n $jsonFile = "$env:VersionBuildInfoJsonFile"\n $blobName = Get-Item $jsonFile | Split-Path -Leaf\n Write-Verbose -Verbose "Uploading $jsonFile to $containerName/$prefix/$blobName"\n Set-AzStorageBlobContent -File $jsonFile -Container $containerName -Blob "$prefix/$blobName" -Context $storageContext -Force\n }\n condition: and(succeeded(), eq(variables['CopyMainBuildInfo'], 'YES'))\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\release-upload-buildinfo.yml
release-upload-buildinfo.yml
YAML
5,535
0.8
0.049645
0.008403
react-lib
903
2025-05-10T12:03:28.924727
Apache-2.0
false
b4e7754b2affe54f4d80b291593161ad
parameters:\n - name: jobName\n type: string\n default: ""\n - name: displayName\n type: string\n default: ""\n - name: jobtype\n type: string\n default: ""\n - name: artifactName\n type: string\n default: ""\n - name: packageNamePattern\n type: string\n default: ""\n - name: arm64\n type: string\n default: "no"\n - name: enableCredScan\n type: boolean\n default: true\n\njobs:\n- job: ${{ parameters.jobName }}\n displayName: ${{ parameters.displayName }}\n variables:\n - group: DotNetPrivateBuildAccess\n - name: artifactName\n value: ${{ parameters.artifactName }}\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n - name: ob_sdl_credscan_enabled\n value: ${{ parameters.enableCredScan }}\n\n pool:\n type: ${{ parameters.jobtype }}\n ${{ if eq(parameters.arm64, 'yes') }}:\n hostArchitecture: arm64\n\n steps:\n - checkout: self\n clean: true\n\n - template: release-SetReleaseTagandContainerName.yml@self\n\n - download: PSPackagesOfficial\n artifact: "${{ parameters.artifactName }}"\n displayName: Download fxd artifact\n\n - pwsh: |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture environment\n\n - pwsh: |\n $artifactName = '$(artifactName)'\n Get-ChildItem "$(Pipeline.Workspace)/PSPackagesOfficial/$artifactName" -Recurse\n displayName: 'Capture Downloaded Artifacts'\n\n - task: UseDotNet@2\n displayName: 'Use .NET Core sdk'\n inputs:\n useGlobalJson: true\n packageType: 'sdk'\n workingDirectory: $(Build.SourcesDirectory)/PowerShell"\n\n - pwsh: |\n $artifactName = '$(artifactName)'\n $rootPath = "$(Pipeline.Workspace)/PSPackagesOfficial/$artifactName"\n\n $destPath = New-Item "$rootPath/fxd" -ItemType Directory\n $packageNameFilter = '${{ parameters.packageNamePattern }}'\n\n if ($packageNameFilter.EndsWith('tar.gz')) {\n $package = @(Get-ChildItem -Path "$rootPath/*.tar.gz")\n Write-Verbose -Verbose "Package: $package"\n if ($package.Count -ne 1) {\n throw 'Only 1 package was expected.'\n }\n tar -xvf $package.FullName -C $destPath\n }\n else {\n $package = @(Get-ChildItem -Path "$rootPath/*.zip")\n Write-Verbose -Verbose "Package: $package"\n if ($package.Count -ne 1) {\n throw 'Only 1 package was expected.'\n }\n Expand-Archive -Path $package.FullName -Destination "$destPath" -Verbose\n }\n displayName: Expand fxd package\n\n - pwsh: |\n $repoRoot = "$(Build.SourcesDirectory)/PowerShell"\n $artifactName = '$(artifactName)'\n $rootPath = "$(Pipeline.Workspace)/PSPackagesOfficial/$artifactName"\n\n $env:DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1\n Import-Module "$repoRoot/build.psm1" -Force\n Find-Dotnet -SetDotnetRoot\n Write-Verbose -Verbose "DOTNET_ROOT: $env:DOTNET_ROOT"\n Write-Verbose -Verbose "Check dotnet install"\n dotnet --info\n Write-Verbose -Verbose "Start test"\n $packageNameFilter = '${{ parameters.packageNamePattern }}'\n $pwshExeName = if ($packageNameFilter.EndsWith('tar.gz')) { 'pwsh' } else { 'pwsh.exe' }\n $pwshPath = Join-Path "$rootPath/fxd" $pwshExeName\n\n if ($IsLinux) {\n chmod u+x $pwshPath\n }\n\n $pwshDllPath = Join-Path "$rootPath/fxd" 'pwsh.dll'\n\n $actualOutput = & dotnet $pwshDllPath -c 'Start-ThreadJob -ScriptBlock { "1" } | Wait-Job | Receive-Job'\n Write-Verbose -Verbose "Actual output: $actualOutput"\n if ($actualOutput -ne 1) {\n throw "Actual output is not as expected"\n }\n displayName: Test package\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\release-validate-fxdpackages.yml
release-validate-fxdpackages.yml
YAML
4,038
0.8
0.056911
0
node-utils
716
2024-12-29T04:21:53.467871
BSD-3-Clause
false
47d103b3472a8bcc89f199560d3c7442
parameters:\n jobName: ""\n displayName: ""\n jobtype: "windows"\n globalToolExeName: 'pwsh.exe'\n globalToolPackageName: 'PowerShell.Windows.x64'\n\n\njobs:\n- job: ${{ parameters.jobName }}\n displayName: ${{ parameters.displayName }}\n pool:\n type: ${{ parameters.jobtype }}\n variables:\n - group: DotNetPrivateBuildAccess\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n\n steps:\n - checkout: self\n clean: true\n\n - template: release-SetReleaseTagandContainerName.yml@self\n\n - download: PSPackagesOfficial\n artifact: drop_nupkg_build_nupkg\n displayName: Download nupkgs\n\n - pwsh: |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture environment\n\n - pwsh: |\n Get-ChildItem "$(Pipeline.Workspace)/PSPackagesOfficial/drop_nupkg_build_nupkg" -Recurse\n displayName: 'Capture Downloaded Artifacts'\n\n - task: UseDotNet@2\n displayName: 'Use .NET Core sdk'\n inputs:\n useGlobalJson: true\n packageType: 'sdk'\n workingDirectory: $(REPOROOT)\n\n - pwsh: |\n $repoRoot = "$(Build.SourcesDirectory)/PowerShell"\n\n $toolPath = New-Item -ItemType Directory "$(System.DefaultWorkingDirectory)/toolPath" | Select-Object -ExpandProperty FullName\n\n Write-Verbose -Verbose "dotnet tool list -g"\n dotnet tool list -g\n\n $packageName = '${{ parameters.globalToolPackageName }}'\n Write-Verbose -Verbose "Installing $packageName"\n\n dotnet tool install --add-source "$ENV:PIPELINE_WORKSPACE/PSPackagesOfficial/drop_nupkg_build_nupkg" --tool-path $toolPath --version '$(OutputVersion.Version)' $packageName\n\n Get-ChildItem -Path $toolPath\n\n displayName: Install global tool\n env:\n __DOTNET_RUNTIME_FEED_KEY: $(RUNTIME_SOURCEFEED_KEY)\n\n - pwsh: |\n $toolPath = "$(System.DefaultWorkingDirectory)/toolPath/${{ parameters.globalToolExeName }}"\n\n if (-not (Test-Path $toolPath))\n {\n throw "Tool is not installed at $toolPath"\n }\n else\n {\n Write-Verbose -Verbose "Tool found at: $toolPath"\n }\n displayName: Validate tool is installed\n\n - pwsh: |\n $repoRoot = "$(Build.SourcesDirectory)/PowerShell"\n\n $exeName = if ($IsWindows) { "pwsh.exe" } else { "pwsh" }\n\n $toolPath = "$(System.DefaultWorkingDirectory)/toolPath/${{ parameters.globalToolExeName }}"\n\n $source = (get-command -Type Application -Name dotnet | Select-Object -First 1 -ExpandProperty source)\n $target = (Get-ChildItem $source).target\n\n # If we find a symbolic link for dotnet, then we need to split the filename off the target.\n if ($target) {\n Write-Verbose -Verbose "Splitting target: $target"\n $target = Split-Path $target\n }\n\n Write-Verbose -Verbose "target is set as $target"\n\n $env:DOTNET_ROOT = (resolve-path -Path (Join-Path (split-path $source) $target)).ProviderPath\n\n Write-Verbose -Verbose "DOTNET_ROOT: $env:DOTNET_ROOT"\n Get-ChildItem $env:DOTNET_ROOT\n\n $versionFound = & $toolPath -c '$PSVersionTable.PSVersion.ToString()'\n\n if ( '$(OutputVersion.Version)' -ne $versionFound)\n {\n throw "Expected version of global tool not found. Installed version is $versionFound"\n }\n else\n {\n write-verbose -verbose "Found expected version: $versionFound"\n }\n\n $dateYear = & $toolPath -c '(Get-Date).Year'\n\n if ( $dateYear -ne [DateTime]::Now.Year)\n {\n throw "Get-Date returned incorrect year: $dateYear"\n }\n else\n {\n write-verbose -verbose "Got expected year: $dateYear"\n }\n displayName: Basic validation\n env:\n __DOTNET_RUNTIME_FEED_KEY: $(RUNTIME_SOURCEFEED_KEY)\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\release-validate-globaltools.yml
release-validate-globaltools.yml
YAML
4,137
0.8
0.047619
0.010309
node-utils
86
2023-12-21T13:36:49.674686
GPL-3.0
false
ae44bcc0f05a817be3ef2a9c7fe613ba
jobs:\n- job: validatePackageNames\n displayName: Validate Package Names\n pool:\n type: windows\n variables:\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n - group: 'Azure Blob variable group'\n\n steps:\n - checkout: self\n clean: true\n\n - template: release-SetReleaseTagAndContainerName.yml\n\n - pwsh: |\n Get-ChildItem ENV: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture environment\n\n - pwsh: |\n $name = "{0}_{1:x}" -f '$(OutputReleaseTag.releaseTag)', (Get-Date).Ticks\n Write-Host $name\n Write-Host "##vso[build.updatebuildnumber]$name"\n displayName: Set Release Name\n\n - task: AzurePowerShell@5\n displayName: Upload packages to blob\n inputs:\n azureSubscription: az-blob-cicd-infra\n scriptType: inlineScript\n azurePowerShellVersion: LatestVersion\n pwsh: true\n inline: |\n $storageAccount = Get-AzStorageAccount -ResourceGroupName '$(StorageResourceGroup)' -Name '$(StorageAccount)'\n $ctx = $storageAccount.Context\n $container = '$(OutputVersion.AzureVersion)'\n\n $destinationPath = '$(System.ArtifactsDirectory)'\n $blobList = Get-AzStorageBlob -Container $container -Context $ctx\n foreach ($blob in $blobList) {\n $blobName = $blob.Name\n $destinationFile = Join-Path -Path $destinationPath -ChildPath $blobName\n Get-AzStorageBlobContent -Container $container -Blob $blobName -Destination $destinationFile -Context $ctx -Force\n Write-Output "Downloaded $blobName to $destinationFile"\n }\n\n - pwsh: |\n Get-ChildItem $(System.ArtifactsDirectory)\* -recurse | Select-Object -ExpandProperty Name\n displayName: Capture Artifact Listing\n\n - pwsh: |\n $message = @()\n Get-ChildItem $(System.ArtifactsDirectory)\* -recurse -filter *.rpm | ForEach-Object {\n if($_.Name -notmatch 'powershell\-(preview-|lts-)?\d+\.\d+\.\d+(_[a-z]*\.\d+)?-1.(rh|cm).(x86_64|aarch64)\.rpm')\n {\n $messageInstance = "$($_.Name) is not a valid package name"\n $message += $messageInstance\n Write-Warning $messageInstance\n }\n }\n if($message.count -gt 0){throw ($message | out-string)}\n displayName: Validate RPM package names\n\n - pwsh: |\n $message = @()\n Get-ChildItem $(System.ArtifactsDirectory)\* -recurse -filter *.tar.gz | ForEach-Object {\n if($_.Name -notmatch 'powershell-(lts-)?\d+\.\d+\.\d+\-([a-z]*.\d+\-)?(linux|osx|linux-musl)+\-(x64\-fxdependent|x64|arm32|arm64|x64\-musl-noopt\-fxdependent)\.(tar\.gz)')\n {\n $messageInstance = "$($_.Name) is not a valid package name"\n $message += $messageInstance\n Write-Warning $messageInstance\n }\n }\n if($message.count -gt 0){throw ($message | out-string)}\n displayName: Validate Tar.Gz Package Names\n\n - pwsh: |\n $message = @()\n Get-ChildItem $(System.ArtifactsDirectory)\* -recurse -filter *.pkg | ForEach-Object {\n if($_.Name -notmatch 'powershell-(lts-)?\d+\.\d+\.\d+\-([a-z]*.\d+\-)?osx(\.10\.12)?\-(x64|arm64)\.pkg')\n {\n $messageInstance = "$($_.Name) is not a valid package name"\n $message += $messageInstance\n Write-Warning $messageInstance\n }\n }\n if($message.count -gt 0){throw ($message | out-string)}\n displayName: Validate PKG Package Names\n\n - pwsh: |\n $message = @()\n Get-ChildItem $(System.ArtifactsDirectory)\* -recurse -include *.zip, *.msi | ForEach-Object {\n if($_.Name -notmatch 'PowerShell-\d+\.\d+\.\d+\-([a-z]*.\d+\-)?win\-(fxdependent|x64|arm64|x86|fxdependentWinDesktop)\.(msi|zip){1}')\n {\n $messageInstance = "$($_.Name) is not a valid package name"\n $message += $messageInstance\n Write-Warning $messageInstance\n }\n }\n\n if($message.count -gt 0){throw ($message | out-string)}\n displayName: Validate Zip and MSI Package Names\n\n - pwsh: |\n $message = @()\n Get-ChildItem $(System.ArtifactsDirectory)\* -recurse -filter *.deb | ForEach-Object {\n if($_.Name -notmatch 'powershell(-preview|-lts)?_\d+\.\d+\.\d+([\-~][a-z]*.\d+)?-\d\.deb_amd64\.deb')\n {\n $messageInstance = "$($_.Name) is not a valid package name"\n $message += $messageInstance\n Write-Warning $messageInstance\n }\n }\n if($message.count -gt 0){throw ($message | out-string)}\n displayName: Validate Deb Package Names\n\n# Move to 1ES SBOM validation tool\n# - job: validateBOM\n# displayName: Validate Package Names\n# pool:\n# type: windows\n# variables:\n# - name: ob_outputDirectory\n# value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n# - name: ob_sdl_credscan_suppressionsFile\n# value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n# - name: ob_sdl_tsa_configFile\n# value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n# - group: 'Azure Blob variable group'\n\n# steps:\n# - checkout: self\n# clean: true\n\n# - pwsh: |\n# Get-ChildItem ENV: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n# displayName: Capture environment\n\n# - template: release-SetReleaseTagAndContainerName.yml\n\n# - pwsh: |\n# $name = "{0}_{1:x}" -f '$(releaseTag)', (Get-Date).Ticks\n# Write-Host $name\n# Write-Host "##vso[build.updatebuildnumber]$name"\n# displayName: Set Release Name\n\n# - task: DownloadPipelineArtifact@2\n# inputs:\n# source: specific\n# project: PowerShellCore\n# pipeline: '696'\n# preferTriggeringPipeline: true\n# runVersion: latestFromBranch\n# runBranch: '$(Build.SourceBranch)'\n# artifact: finalResults\n# path: $(System.ArtifactsDirectory)\n\n\n# - pwsh: |\n# Get-ChildItem $(System.ArtifactsDirectory)\* -recurse | Select-Object -ExpandProperty Name\n# displayName: Capture Artifact Listing\n\n# - pwsh: |\n# Install-module Pester -Scope CurrentUser -Force -MaximumVersion 4.99\n# displayName: Install Pester\n# condition: succeededOrFailed()\n\n# - pwsh: |\n# Import-module './build.psm1'\n# Import-module './tools/packaging'\n# $env:PACKAGE_FOLDER = '$(System.ArtifactsDirectory)'\n# $path = Join-Path -Path $pwd -ChildPath './packageReleaseTests.xml'\n# $results = invoke-pester -Script './tools/packaging/releaseTests' -OutputFile $path -OutputFormat NUnitXml -PassThru\n# Write-Host "##vso[results.publish type=NUnit;mergeResults=true;runTitle=Package Release Tests;publishRunAttachments=true;resultFiles=$path;]"\n# if($results.TotalCount -eq 0 -or $results.FailedCount -gt 0)\n# {\n# throw "Package Release Tests failed"\n# }\n# displayName: Run packaging release tests\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\release-validate-packagenames.yml
release-validate-packagenames.yml
YAML
7,142
0.8
0.059783
0.335404
react-lib
354
2025-01-13T04:34:22.554096
GPL-3.0
false
fb3313cd98d669375fd2f65a7decb955
parameters:\n jobName: ""\n displayName: ""\n poolName: "windows"\n imageName: 'none'\n\njobs:\n- job: ${{ parameters.jobName }}\n displayName: ${{ parameters.displayName }}\n pool:\n type: linux\n isCustom: true\n ${{ if eq( parameters.poolName, 'Azure Pipelines') }}:\n name: ${{ parameters.poolName }}\n vmImage: ${{ parameters.imageName }}\n ${{ else }}:\n name: ${{ parameters.poolName }}\n demands:\n - ImageOverride -equals ${{ parameters.imageName }}\n\n variables:\n - group: mscodehub-feed-read-general\n - group: mscodehub-feed-read-akv\n - group: DotNetPrivateBuildAccess\n\n steps:\n - checkout: self\n clean: true\n lfs: false\n\n - template: /.pipelines/templates/insert-nuget-config-azfeed.yml@self\n parameters:\n repoRoot: "$(Build.SourcesDirectory)"\n\n - template: release-SetReleaseTagandContainerName.yml@self\n\n - download: PSPackagesOfficial\n artifact: drop_nupkg_build_nupkg\n displayName: Download nupkgs\n\n - pwsh: |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture environment\n\n - pwsh: |\n Get-ChildItem "$(Pipeline.Workspace)/PSPackagesOfficial/drop_nupkg_build_nupkg" -Recurse\n displayName: 'Capture Downloaded Artifacts'\n\n - task: UseDotNet@2\n displayName: 'Use .NET Core sdk'\n inputs:\n useGlobalJson: true\n packageType: 'sdk'\n workingDirectory: $(REPOROOT)\n\n - pwsh: |\n $repoRoot = "$(Build.SourcesDirectory)"\n\n $env:DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1\n\n $localLocation = "$(Pipeline.Workspace)/PSPackagesOfficial/drop_nupkg_build_nupkg"\n $xmlElement = @"\n <add key=`"local`" value=`"$localLocation`" />\n <add key="dotnet" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet9/nuget/v2" />\n </packageSources>\n "@\n\n $releaseVersion = '$(OutputVersion.Version)'\n\n Write-Verbose -Message "Release Version: $releaseVersion" -Verbose\n\n Set-Location -Path $repoRoot/test/hosting\n\n Get-ChildItem\n\n ## register the packages download directory in the nuget file\n $nugetPath = './NuGet.Config'\n if(!(test-path $nugetPath)) {\n $nugetPath = "$repoRoot/nuget.config"\n }\n Write-Verbose -Verbose "nugetPath: $nugetPath"\n $nugetConfigContent = Get-Content $nugetPath -Raw\n $updateNugetContent = $nugetConfigContent.Replace("</packageSources>", $xmlElement)\n\n $updateNugetContent | Out-File $nugetPath -Encoding ascii\n\n Get-Content $nugetPath\n\n dotnet --info\n dotnet restore\n dotnet test /property:RELEASE_VERSION=$releaseVersion --test-adapter-path:. "--logger:xunit;LogFilePath=$(System.DefaultWorkingDirectory)/test-hosting.xml"\n displayName: Restore and execute tests\n env:\n __DOTNET_RUNTIME_FEED_KEY: $(RUNTIME_SOURCEFEED_KEY)\n\n - task: PublishTestResults@2\n displayName: 'Publish Test Results **\test-hosting.xml'\n inputs:\n testResultsFormat: XUnit\n testResultsFiles: '**\test-hosting.xml'\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\release-validate-sdk.yml
release-validate-sdk.yml
YAML
3,130
0.8
0.02
0.012658
awesome-app
440
2023-12-12T17:40:39.290201
BSD-3-Clause
false
9b5eed25d2d7e9a402ce00d8e59ba5b3
parameters:\n ReleaseTagVar: v6.2.0\n ReleaseTagVarName: ReleaseTagVar\n CreateJson: 'no'\n UseJson: 'yes'\n\nsteps:\n- ${{ if eq(parameters['UseJson'],'yes') }}:\n - task: DownloadBuildArtifacts@0\n inputs:\n artifactName: 'drop_prep_SetVars'\n itemPattern: '*.json'\n downloadPath: '$(System.ArtifactsDirectory)'\n displayName: Download Build Info Json\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n- powershell: |\n $path = "./build.psm1"\n if($env:REPOROOT){\n Write-Verbose "reporoot already set to ${env:REPOROOT}" -Verbose\n exit 0\n }\n if(Test-Path -Path $path)\n {\n Write-Verbose "reporoot detect at: ." -Verbose\n $repoRoot = '.'\n }\n else{\n $path = "./PowerShell/build.psm1"\n if(Test-Path -Path $path)\n {\n Write-Verbose "reporoot detect at: ./PowerShell" -Verbose\n $repoRoot = './PowerShell'\n }\n }\n if($repoRoot) {\n $vstsCommandString = "vso[task.setvariable variable=repoRoot]$repoRoot"\n Write-Host ("sending " + $vstsCommandString)\n Write-Host "##$vstsCommandString"\n } else {\n Write-Verbose -Verbose "repo not found"\n }\n displayName: 'Set repo Root'\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n- powershell: |\n $createJson = ("${{ parameters.CreateJson }}" -ne "no")\n\n $REPOROOT = $env:REPOROOT\n\n if (-not (Test-Path $REPOROOT/tools/releaseBuild/setReleaseTag.ps1)) {\n if ((Test-Path "$REPOROOT/PowerShell/tools/releaseBuild/setReleaseTag.ps1")) {\n $REPOROOT = "$REPOROOT/PowerShell"\n } else {\n throw "Could not find setReleaseTag.ps1 in $REPOROOT/tools/releaseBuild or $REPOROOT/PowerShell/tools/releaseBuild"\n }\n }\n\n $releaseTag = & "$REPOROOT/tools/releaseBuild/setReleaseTag.ps1" -ReleaseTag ${{ parameters.ReleaseTagVar }} -Variable "${{ parameters.ReleaseTagVarName }}" -CreateJson:$createJson\n $version = $releaseTag.Substring(1)\n $vstsCommandString = "vso[task.setvariable variable=Version]$version"\n Write-Host ("sending " + $vstsCommandString)\n Write-Host "##$vstsCommandString"\n $azureVersion = $releaseTag.ToLowerInvariant() -replace '\.', '-'\n $vstsCommandString = "vso[task.setvariable variable=AzureVersion]$azureVersion"\n Write-Host ("sending " + $vstsCommandString)\n Write-Host "##$vstsCommandString"\n displayName: 'Set ${{ parameters.ReleaseTagVarName }} and other version Variables'\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n- powershell: |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture environment\n condition: succeededOrFailed()\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\SetVersionVariables.yml
SetVersionVariables.yml
YAML
2,902
0.8
0.088608
0
react-lib
433
2025-04-23T09:42:03.992686
Apache-2.0
false
c182ee1d385d1b1e800136a482d3ec0c
steps:\n- powershell: |\n $shouldSign = $true\n $authenticodeCert = 'CP-230012'\n $msixCert = 'CP-230012'\n if($env:IS_DAILY -eq 'true')\n {\n $authenticodeCert = 'CP-460906'\n }\n if($env:SKIP_SIGNING -eq 'Yes')\n {\n $shouldSign = $false\n }\n $vstsCommandString = "vso[task.setvariable variable=SHOULD_SIGN]$($shouldSign.ToString().ToLowerInvariant())"\n Write-Host "sending " + $vstsCommandString\n Write-Host "##$vstsCommandString"\n $vstsCommandString = "vso[task.setvariable variable=MSIX_CERT]$($msixCert)"\n Write-Host "sending " + $vstsCommandString\n Write-Host "##$vstsCommandString"\n $vstsCommandString = "vso[task.setvariable variable=AUTHENTICODE_CERT]$($authenticodeCert)"\n Write-Host "sending " + $vstsCommandString\n Write-Host "##$vstsCommandString"\n displayName: 'Set SHOULD_SIGN Variable'\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\shouldSign.yml
shouldSign.yml
YAML
962
0.8
0.08
0
node-utils
159
2024-04-05T17:13:40.608239
MIT
false
33b28881e6a0f890c2a512b3f2b2c133
jobs:\n- job: upload_packages\n displayName: Upload packages\n condition: succeeded()\n pool:\n type: windows\n variables:\n - name: ob_sdl_sbom_enabled\n value: true\n - name: runCodesignValidationInjection\n value: false\n - name: NugetSecurityAnalysisWarningLevel\n value: none\n - name: DOTNET_SKIP_FIRST_TIME_EXPERIENCE\n value: 1\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: ob_sdl_codeSignValidation_enabled\n value: false\n - name: ob_sdl_binskim_enabled\n value: false\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n - name: ob_sdl_codeql_compiled_enabled\n value: false\n\n steps:\n - checkout: self\n clean: true\n env:\n ob_restore_phase: true # This ensures checkout is done at the beginning of the restore phase\n\n - template: /.pipelines/templates/SetVersionVariables.yml@self\n parameters:\n ReleaseTagVar: $(ReleaseTagVar)\n CreateJson: yes\n UseJson: no\n\n - template: /.pipelines/templates/cloneToOfficialPath.yml@self\n\n - pwsh: |\n Get-ChildItem Env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: 'Capture Environment Variables'\n\n - pwsh: |\n New-Item -Path '$(Build.ArtifactStagingDirectory)/downloads' -ItemType Directory -Force\n displayName: Create downloads directory\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_linux_package_deb\n itemPattern: '**/*.deb'\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download deb package\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_linux_package_fxdependent\n itemPattern: '**/*.tar.gz'\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download linux fxd package\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_linux_package_mariner_arm64\n itemPattern: '**/*.rpm'\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download linux mariner arm64 package\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_linux_package_mariner_x64\n itemPattern: '**/*.rpm'\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download linux mariner x64 package\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_linux_package_minSize\n itemPattern: '**/*.tar.gz'\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download linux minSize package\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_linux_package_rpm\n itemPattern: '**/*.rpm'\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download linux rpm package\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_linux_package_tar\n itemPattern: '**/*.tar.gz'\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download linux tar package\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_linux_package_tar_alpine\n itemPattern: '**/*.tar.gz'\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download linux alpine tar package\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_linux_package_tar_alpine_fxd\n itemPattern: '**/*.tar.gz'\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download linux alpine fxd tar package\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_linux_package_tar_arm\n itemPattern: '**/*.tar.gz'\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download linux arm32 tar package\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_linux_package_tar_arm64\n itemPattern: '**/*.tar.gz'\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download linux arm64 tar package\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_nupkg_build_nupkg\n itemPattern: '**/*.nupkg'\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download nupkgs\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_windows_package_package_win_arm64\n itemPattern: |\n **/*.msi\n **/*.msix\n **/*.zip\n **/*.exe\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download windows arm64 packages\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_windows_package_package_win_fxdependent\n itemPattern: '**/*.zip'\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download windows fxdependent packages\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_windows_package_package_win_fxdependentWinDesktop\n itemPattern: '**/*.zip'\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download windows fxdependentWinDesktop packages\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_windows_package_package_win_minsize\n itemPattern: '**/*.zip'\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download windows minsize packages\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_windows_package_package_win_x64\n itemPattern: |\n **/*.msi\n **/*.msix\n **/*.zip\n **/*.exe\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download windows x64 packages\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_windows_package_package_win_x86\n itemPattern: |\n **/*.msi\n **/*.msix\n **/*.zip\n **/*.exe\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download windows x86 packages\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: macos-pkgs\n itemPattern: |\n **/*.tar.gz\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download macos tar packages\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_mac_package_sign_package_macos_arm64\n itemPattern: |\n **/*.pkg\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download macos arm packages\n\n - task: DownloadPipelineArtifact@2\n inputs:\n buildType: 'current'\n artifact: drop_mac_package_sign_package_macos_x64\n itemPattern: |\n **/*.pkg\n targetPath: '$(Build.ArtifactStagingDirectory)/downloads'\n displayName: Download macos x64 packages\n\n - pwsh: |\n Get-ChildItem '$(Build.ArtifactStagingDirectory)/downloads' | Select-Object -ExpandProperty FullName\n displayName: 'Capture downloads'\n\n - pwsh: |\n Write-Verbose -Verbose "Copying Github Release files in $(Build.ArtifactStagingDirectory)/downloads to use in Release Pipeline"\n \n Write-Verbose -Verbose "Creating output directory for GitHub Release files: $(ob_outputDirectory)/GitHubPackages"\n New-Item -Path $(ob_outputDirectory)/GitHubPackages -ItemType Directory -Force\n Get-ChildItem -Path "$(Build.ArtifactStagingDirectory)/downloads/*" -Recurse | \n Where-Object { $_.Extension -notin '.msix', '.nupkg' -and $_.Name -notmatch '-gc'} | \n Copy-Item -Destination $(ob_outputDirectory)/GitHubPackages -Recurse -Verbose\n \n Write-Verbose -Verbose "Creating output directory for NuGet packages: $(ob_outputDirectory)/NuGetPackages"\n New-Item -Path $(ob_outputDirectory)/NuGetPackages -ItemType Directory -Force\n Get-ChildItem -Path "$(Build.ArtifactStagingDirectory)/downloads/*" -Recurse | \n Where-Object { $_.Extension -eq '.nupkg' } | \n Copy-Item -Destination $(ob_outputDirectory)/NuGetPackages -Recurse -Verbose\n displayName: Copy downloads to Artifacts\n\n - pwsh: |\n # Create output directory for packages which have been uploaded to blob storage\n New-Item -Path $(Build.ArtifactStagingDirectory)/uploaded -ItemType Directory -Force\n displayName: Create output directory for packages\n\n - task: AzurePowerShell@5\n displayName: Upload packages to blob\n inputs:\n azureSubscription: az-blob-cicd-infra\n scriptType: inlineScript\n azurePowerShellVersion: LatestVersion\n pwsh: true\n inline: |\n $downloadsDirectory = '$(Build.ArtifactStagingDirectory)/downloads'\n $uploadedDirectory = '$(Build.ArtifactStagingDirectory)/uploaded'\n $storageAccountName = "pscoretestdata"\n $containerName = $env:AZUREVERSION\n\n Write-Verbose -Verbose "Uploading packages to blob storage account: $storageAccountName container: $containerName"\n\n $context = New-AzStorageContext -StorageAccountName $storageAccountName -UseConnectedAccount\n\n # Create the blob container if it doesn't exist\n $containerExists = Get-AzStorageContainer -Name $containerName -Context $context -ErrorAction SilentlyContinue\n if (-not $containerExists) {\n $null = New-AzStorageContainer -Name $containerName -Context $context\n Write-Host "Blob container $containerName created successfully."\n }\n\n $gcPackages = Get-ChildItem -Path $downloadsDirectory -Filter "powershell*gc.*"\n Write-Verbose -Verbose "gc files to upload."\n $gcPackages | Write-Verbose -Verbose\n $gcContainerName = "$containerName-gc"\n # Create the blob container if it doesn't exist\n $containerExists = Get-AzStorageContainer -Name $gcContainerName -Context $context -ErrorAction SilentlyContinue\n if (-not $containerExists) {\n $null = New-AzStorageContainer -Name $gcContainerName -Context $context\n Write-Host "Blob container $gcContainerName created successfully."\n }\n\n $gcPackages | ForEach-Object {\n $blobName = "${_.Name}"\n Write-Verbose -Verbose "Uploading $($_.FullName) to $gcContainerName/$blobName"\n $null = Set-AzStorageBlobContent -File $_.FullName -Container $gcContainerName -Blob $blobName -Context $context\n # Move to folder to we wont upload again\n Move-Item -Path $_.FullName -Destination $uploadedDirectory -Force -Verbose\n }\n\n $nupkgFiles = Get-ChildItem -Path $downloadsDirectory -Filter "*.nupkg" | Where-Object { $_.Name -notlike "powershell*.nupkg" }\n\n # create a SHA512 checksum file for each nupkg files\n\n $checksums = $nupkgFiles |\n ForEach-Object {\n Write-Verbose -Verbose "Generating checksum file for $($_.FullName)"\n $packageName = $_.Name\n $hash = (Get-FileHash -Path $_.FullName -Algorithm SHA256).Hash.ToLower()\n # the '*' before the packagename signifies it is a binary\n "$hash *$packageName"\n }\n\n $checksums | Out-File -FilePath "$downloadsDirectory\SHA512SUMS" -Force\n $fileContent = Get-Content -Path "$downloadsDirectory\SHA512SUMS" -Raw | Out-String\n Write-Verbose -Verbose -Message $fileContent\n\n Write-Verbose -Verbose "nupkg files to upload."\n $nupkgFiles += (Get-Item "$downloadsDirectory\SHA512SUMS")\n $nupkgFiles | Write-Verbose -Verbose\n $nugetContainerName = "$containerName-nuget"\n # Create the blob container if it doesn't exist\n $containerExists = Get-AzStorageContainer -Name $nugetContainerName -Context $context -ErrorAction SilentlyContinue\n if (-not $containerExists) {\n $null = New-AzStorageContainer -Name $nugetContainerName -Context $context\n Write-Host "Blob container $nugetContainerName created successfully."\n }\n\n $nupkgFiles | ForEach-Object {\n $blobName = $_.Name\n Write-Verbose -Verbose "Uploading $($_.FullName) to $nugetContainerName/$blobName"\n $null = Set-AzStorageBlobContent -File $_.FullName -Container $nugetContainerName -Blob $blobName -Context $context\n # Move to folder to we wont upload again\n Move-Item -Path $_.FullName -Destination $uploadedDirectory -Force -Verbose\n }\n\n $globaltoolFiles = Get-ChildItem -Path $downloadsDirectory -Filter "powershell*.nupkg"\n # create a SHA512 checksum file for each nupkg files\n\n $checksums = $globaltoolFiles |\n ForEach-Object {\n Write-Verbose -Verbose "Generating checksum file for $($_.FullName)"\n $packageName = $_.Name\n $hash = (Get-FileHash -Path $_.FullName -Algorithm SHA256).Hash.ToLower()\n # the '*' before the packagename signifies it is a binary\n "$hash *$packageName"\n }\n\n New-Item -Path "$downloadsDirectory\globaltool" -ItemType Directory -Force\n $checksums | Out-File -FilePath "$downloadsDirectory\globaltool\SHA512SUMS" -Force\n $fileContent = Get-Content -Path "$downloadsDirectory\globaltool\SHA512SUMS" -Raw | Out-String\n Write-Verbose -Verbose -Message $fileContent\n\n Write-Verbose -Verbose "globaltool files to upload."\n $globaltoolFiles += Get-Item ("$downloadsDirectory\globaltool\SHA512SUMS")\n $globaltoolFiles | Write-Verbose -Verbose\n $globaltoolContainerName = "$containerName-nuget"\n $globaltoolFiles | ForEach-Object {\n $blobName = "globaltool/" + $_.Name\n $globaltoolContainerName = "$containerName-nuget"\n Write-Verbose -Verbose "Uploading $($_.FullName) to $globaltoolContainerName/$blobName"\n $null = Set-AzStorageBlobContent -File $_.FullName -Container $globaltoolContainerName -Blob $blobName -Context $context\n # Move to folder to we wont upload again\n Move-Item -Path $_.FullName -Destination $uploadedDirectory -Force\n }\n\n # To use -Include parameter, we need to use \* to get all files\n $privateFiles = Get-ChildItem -Path $downloadsDirectory\* -Include @("*.msix", "*.exe")\n Write-Verbose -Verbose "private files to upload."\n $privateFiles | Write-Verbose -Verbose\n $privateContainerName = "$containerName-private"\n # Create the blob container if it doesn't exist\n $containerExists = Get-AzStorageContainer -Name $privateContainerName -Context $context -ErrorAction SilentlyContinue\n if (-not $containerExists) {\n $null = New-AzStorageContainer -Name $privateContainerName -Context $context\n Write-Host "Blob container $privateContainerName created successfully."\n }\n\n $privateFiles | ForEach-Object {\n $blobName = $_.Name\n Write-Verbose -Verbose "Uploading $($_.FullName) to $privateContainerName/$blobName"\n $null = Set-AzStorageBlobContent -File $_.FullName -Container $privateContainerName -Blob $blobName -Context $context\n # Move to folder to we wont upload again\n Move-Item -Path $_.FullName -Destination $uploadedDirectory -Force -Verbose\n }\n\n # To use -Include parameter, we need to use \* to get all files\n $files = Get-ChildItem -Path $downloadsDirectory\* -Include @("*.deb", "*.tar.gz", "*.rpm", "*.msi", "*.zip", "*.pkg")\n Write-Verbose -Verbose "files to upload."\n $files | Write-Verbose -Verbose\n\n $files | ForEach-Object {\n $blobName = $_.Name\n Write-Verbose -Verbose "Uploading $($_.FullName) to $containerName/$blobName"\n $null = Set-AzStorageBlobContent -File $_.FullName -Container $containerName -Blob $blobName -Context $context\n Write-Host "File $blobName uploaded to $containerName container."\n Move-Item -Path $_.FullName -Destination $uploadedDirectory -Force -Verbose\n }\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\uploadToAzure.yml
uploadToAzure.yml
YAML
16,465
0.8
0.0401
0.086207
node-utils
123
2023-09-01T03:30:21.579007
GPL-3.0
false
b756433fa80ddaee4a6d1f40b6bb9f81
parameters:\n Architecture: 'x64'\n BuildConfiguration: 'release'\n JobName: 'build_windows'\n\njobs:\n- job: build_windows_${{ parameters.Architecture }}_${{ parameters.BuildConfiguration }}\n displayName: Build_Windows_${{ parameters.Architecture }}_${{ parameters.BuildConfiguration }}\n condition: succeeded()\n pool:\n type: windows\n variables:\n - name: runCodesignValidationInjection\n value: false\n - name: NugetSecurityAnalysisWarningLevel\n value: none\n - name: DOTNET_SKIP_FIRST_TIME_EXPERIENCE\n value: 1\n - group: DotNetPrivateBuildAccess\n - group: certificate_logical_to_actual\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: ob_sdl_codeSignValidation_enabled\n value: false\n - name: ob_sdl_binskim_enabled\n value: true\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n - name: Architecture\n value: ${{ parameters.Architecture }}\n - name: BuildConfiguration\n value: ${{ parameters.BuildConfiguration }}\n - name: ob_sdl_sbom_packageName\n value: 'Microsoft.Powershell.Windows.${{ parameters.Architecture }}'\n # We add this manually, so we need it disabled the OneBranch auto-injected one.\n - name: ob_sdl_codeql_compiled_enabled\n value: false\n\n steps:\n - checkout: self\n clean: true\n env:\n ob_restore_phase: true # This ensures checkout is done at the beginning of the restore phase\n\n - template: /.pipelines/templates/SetVersionVariables.yml@self\n parameters:\n ReleaseTagVar: $(ReleaseTagVar)\n\n - template: /.pipelines/templates/cloneToOfficialPath.yml@self\n\n - template: /.pipelines/templates/insert-nuget-config-azfeed.yml@self\n parameters:\n repoRoot: $(PowerShellRoot)\n\n - task: CodeQL3000Init@0 # Add CodeQL Init task right before your 'Build' step.\n condition: eq(variables['CODEQL_ENABLED'], 'true')\n env:\n ob_restore_phase: true # Set ob_restore_phase to run this step before '🔒 Setup Signing' step.\n inputs:\n Enabled: true\n # AnalyzeInPipeline: false = upload results\n # AnalyzeInPipeline: true = do not upload results\n AnalyzeInPipeline: false\n Language: csharp\n\n - task: UseDotNet@2\n inputs:\n useGlobalJson: true\n workingDirectory: $(PowerShellRoot)\n env:\n ob_restore_phase: true\n\n - pwsh: |\n $runtime = switch ($env:Architecture)\n {\n "x64" { "win7-x64" }\n "x86" { "win7-x86" }\n "arm64" { "win-arm64" }\n "fxdependent" { "fxdependent" }\n "fxdependentWinDesktop" { "fxdependent-win-desktop" }\n }\n\n $params = @{}\n if ($env:BuildConfiguration -eq 'minSize') {\n $params['ForMinimalSize'] = $true\n }\n\n $vstsCommandString = "vso[task.setvariable variable=Runtime]$runtime"\n Write-Host ("sending " + $vstsCommandString)\n Write-Host "##$vstsCommandString"\n\n Write-Verbose -Message "Building PowerShell with Runtime: $runtime for '$env:BuildConfiguration' configuration"\n Import-Module -Name $(PowerShellRoot)/build.psm1 -Force\n $buildWithSymbolsPath = New-Item -ItemType Directory -Path $(Pipeline.Workspace)/Symbols_$(Architecture) -Force\n\n Start-PSBootstrap -Scenario Package\n $null = New-Item -ItemType Directory -Path $buildWithSymbolsPath -Force -Verbose\n\n $ReleaseTagParam = @{}\n\n if ($env:RELEASETAGVAR) {\n $ReleaseTagParam['ReleaseTag'] = $env:RELEASETAGVAR\n }\n\n Start-PSBuild -Runtime $runtime -Configuration Release -Output $buildWithSymbolsPath -Clean -PSModuleRestore @params @ReleaseTagParam\n\n $refFolderPath = Join-Path $buildWithSymbolsPath 'ref'\n Write-Verbose -Verbose "refFolderPath: $refFolderPath"\n $outputPath = Join-Path '$(ob_outputDirectory)' 'psoptions'\n $null = New-Item -ItemType Directory -Path $outputPath -Force\n $psOptPath = "$outputPath/psoptions.json"\n Save-PSOptions -PSOptionsPath $psOptPath\n\n Write-Verbose -Verbose "Verifying pdbs exist in build folder"\n $pdbs = Get-ChildItem -Path $buildWithSymbolsPath -Recurse -Filter *.pdb\n if ($pdbs.Count -eq 0) {\n Write-Error -Message "No pdbs found in build folder"\n }\n else {\n Write-Verbose -Verbose "Found $($pdbs.Count) pdbs in build folder"\n $pdbs | ForEach-Object {\n Write-Verbose -Verbose "Pdb: $($_.FullName)"\n }\n\n $pdbs | Compress-Archive -DestinationPath "$(ob_outputDirectory)/symbols.zip" -Update\n }\n\n Write-Verbose -Verbose "Completed building PowerShell for '$env:BuildConfiguration' configuration"\n displayName: 'Build Windows Universal - $(Architecture)-$(BuildConfiguration) Symbols folder'\n env:\n __DOTNET_RUNTIME_FEED_KEY: $(RUNTIME_SOURCEFEED_KEY)\n ob_restore_phase: true # Set ob_restore_phase to run this step before '🔒 Setup Signing' step.\n\n - pwsh: |\n $runtime = switch ($env:Architecture)\n {\n "x64" { "win7-x64" }\n "x86" { "win7-x86" }\n "arm64" { "win-arm64" }\n "fxdependent" { "fxdependent" }\n "fxdependentWinDesktop" { "fxdependent-win-desktop" }\n }\n\n Import-Module -Name $(PowerShellRoot)/build.psm1 -Force\n\n ## Build global tool\n Write-Verbose -Message "Building PowerShell global tool for Windows.x64" -Verbose\n $globalToolCsProjDir = Join-Path $(PowerShellRoot) 'src' 'GlobalTools' 'PowerShell.Windows.x64'\n Push-Location -Path $globalToolCsProjDir -Verbose\n\n $globalToolArtifactPath = Join-Path $(Build.SourcesDirectory) 'GlobalTool'\n $vstsCommandString = "vso[task.setvariable variable=GlobalToolArtifactPath]${globalToolArtifactPath}"\n Write-Host "sending " + $vstsCommandString\n Write-Host "##$vstsCommandString"\n\n if ($env:RELEASETAGVAR) {\n $ReleaseTagToUse = $env:RELEASETAGVAR -Replace '^v'\n }\n\n Write-Verbose -Verbose "Building PowerShell global tool for Windows.x64 with cmdline: dotnet publish --no-self-contained --artifacts-path $globalToolArtifactPath /property:PackageVersion=$(Version) --configuration 'Release' /property:ReleaseTag=$ReleaseTagToUse"\n dotnet publish --no-self-contained --artifacts-path $globalToolArtifactPath /property:PackageVersion=$(Version) --configuration 'Release' /property:ReleaseTag=$ReleaseTagToUse\n $globalToolBuildModulePath = Join-Path $globalToolArtifactPath 'publish' 'PowerShell.Windows.x64' 'release'\n Pop-Location\n # do this to ensure everything gets signed.\n Restore-PSModuleToBuild -PublishPath $globalToolBuildModulePath\n\n $buildWithSymbolsPath = Get-Item -Path "$(Pipeline.Workspace)/Symbols_$(Architecture)"\n $refFolderPath = Join-Path $buildWithSymbolsPath 'ref'\n Write-Verbose -Verbose "refFolderPath: $refFolderPath"\n\n # Copy reference assemblies\n Copy-Item -Path $refFolderPath -Destination $globalToolBuildModulePath -Recurse -Force\n\n Write-Verbose -Verbose "clean unnecessary files in obj directory"\n $objDir = Join-Path $globalToolArtifactPath 'obj' 'PowerShell.Windows.x64' 'release'\n\n $filesToKeep = @("apphost.exe", "PowerShell.Windows.x64.pdb", "PowerShell.Windows.x64.dll", "project.assets.json")\n\n # only four files are needed in obj folder for global tool packaging\n Get-ChildItem -Path $objDir -File -Recurse |\n Where-Object { -not $_.PSIsContainer } |\n Where-Object { $_.name -notin $filesToKeep } |\n Remove-Item -Verbose\n\n\n displayName: 'Build Winx64 Global tool'\n condition: and(succeeded(), eq(variables['Architecture'], 'fxdependent'))\n env:\n __DOTNET_RUNTIME_FEED_KEY: $(RUNTIME_SOURCEFEED_KEY)\n ob_restore_phase: true # Set ob_restore_phase to run this step before '🔒 Setup Signing' step.\n\n - task: CodeQL3000Finalize@0 # Add CodeQL Finalize task right after your 'Build' step.\n condition: eq(variables['CODEQL_ENABLED'], 'true')\n env:\n ob_restore_phase: true # Set ob_restore_phase to run this step before '🔒 Setup Signing' step.\n\n - pwsh: |\n $platform = 'windows'\n $vstsCommandString = "vso[task.setvariable variable=ArtifactPlatform]$platform"\n Write-Host ("sending " + $vstsCommandString)\n Write-Host "##$vstsCommandString"\n displayName: Set artifact platform\n\n - template: /.pipelines/templates/obp-file-signing.yml@self\n parameters:\n binPath: '$(Pipeline.Workspace)/Symbols_$(Architecture)'\n\n ## first we sign all the files in the bin folder\n - ${{ if eq(variables['Architecture'], 'fxdependent') }}:\n - template: /.pipelines/templates/obp-file-signing.yml@self\n parameters:\n binPath: '$(GlobalToolArtifactPath)/publish/PowerShell.Windows.x64/release'\n globalTool: 'true'\n\n - pwsh: |\n Get-ChildItem '$(GlobalToolArtifactPath)/obj/PowerShell.Windows.x64/release'\n displayName: Capture obj files\n condition: and(succeeded(), eq(variables['Architecture'], 'fxdependent'))\n\n ## Now we sign couple of file from the obj folder which are needed for the global tool packaging\n - task: onebranch.pipeline.signing@1\n displayName: Sign obj files\n inputs:\n command: 'sign'\n signing_profile: external_distribution\n files_to_sign: '**\*.dll;**\*.exe'\n search_root: '$(GlobalToolArtifactPath)/obj/PowerShell.Windows.x64/release'\n condition: and(succeeded(), eq(variables['Architecture'], 'fxdependent'))\n\n - pwsh: |\n <# The way the packaging works is a bit tricky as when it is built, we cannot add the modules that come from gallery.\n We have to use dotnet pack to build the nupkg and then expand it as a zip.\n After expanding we restore the signed files for the modules from the gallery.\n We also delete pdbs, content and contentFiles folder which are not necessary.\n After that, we repack using Compress-Archive and rename it back to a nupkg.\n #>\n\n $packagingStrings = Import-PowerShellDataFile "$(PowerShellRoot)\tools\packaging\packaging.strings.psd1"\n\n $outputPath = Join-Path '$(ob_outputDirectory)' 'globaltool'\n $null = New-Item -ItemType Directory -Path $outputPath -Force\n $globalToolCsProjDir = Join-Path $(PowerShellRoot) 'src' 'GlobalTools' 'PowerShell.Windows.x64'\n Push-Location -Path $globalToolCsProjDir -Verbose\n\n if ($env:RELASETAGVAR) {\n $ReleaseTagToUse = $env:RELASETAGVAR -Replace '^v'\n }\n\n Write-Verbose -Verbose "Packing PowerShell global tool for Windows.x64 with cmdline: dotnet pack --output $outputPath --no-build --artifacts-path '$(GlobalToolArtifactPath)' /property:PackageVersion=$(Version) /property:PackageIcon=Powershell_64.png /property:Version=$(Version) /property:ReleaseTag=$ReleaseTagToUse"\n\n dotnet pack --output $outputPath --no-build --artifacts-path '$(GlobalToolArtifactPath)' /property:PackageVersion=$(Version) /property:PackageIcon=Powershell_64.png /property:Version=$(Version) /property:ReleaseTag=$ReleaseTagToUse\n\n Write-Verbose -Verbose "Deleting content and contentFiles folders from the nupkg"\n\n $nupkgs = Get-ChildItem -Path $outputPath -Filter powershell*.nupkg\n\n $nupkgName = $nupkgs.Name\n $newName = $nupkgName -replace '(\.nupkg)$', '.zip'\n Rename-Item -Path $nupkgs.FullName -NewName $newName\n\n $zipPath = Get-ChildItem -Path $outputPath -Filter powershell*.zip\n\n # Expand zip and remove content and contentFiles folders\n Expand-Archive -Path $zipPath -DestinationPath "$outputPath\temp" -Force\n\n $modulesToCopy = @(\n 'PowerShellGet'\n 'PackageManagement'\n 'Microsoft.PowerShell.PSResourceGet'\n 'Microsoft.PowerShell.Archive'\n 'PSReadLine'\n 'ThreadJob'\n )\n\n $sourceModulePath = Join-Path '$(GlobalToolArtifactPath)' 'publish' 'PowerShell.Windows.x64' 'release' 'Modules'\n $destModulesPath = Join-Path "$outputPath" 'temp' 'tools' 'net10.0' 'any' 'modules'\n\n $modulesToCopy | ForEach-Object {\n $modulePath = Join-Path $sourceModulePath $_\n Copy-Item -Path $modulePath -Destination $destModulesPath -Recurse -Force\n }\n\n # Copy ref assemblies\n Copy-Item '$(Pipeline.Workspace)/Symbols_$(Architecture)/ref' "$outputPath\temp\tools\net10.0\any\ref" -Recurse -Force\n\n $contentPath = Join-Path "$outputPath\temp" 'content'\n $contentFilesPath = Join-Path "$outputPath\temp" 'contentFiles'\n\n Remove-Item -Path $contentPath,$contentFilesPath -Recurse -Force\n\n # remove PDBs to reduce the size of the nupkg\n Remove-Item -Path "$outputPath\temp\tools\net10.0\any\*.pdb" -Recurse -Force\n\n # create powershell.config.json\n $config = [ordered]@{}\n $config.Add("Microsoft.PowerShell:ExecutionPolicy", "RemoteSigned")\n $config.Add("WindowsPowerShellCompatibilityModuleDenyList", @("PSScheduledJob", "BestPractices", "UpdateServices"))\n\n $configPublishPath = Join-Path "$outputPath" 'temp' 'tools' 'net10.0' 'any' "powershell.config.json"\n Set-Content -Path $configPublishPath -Value ($config | ConvertTo-Json) -Force -ErrorAction Stop\n\n Compress-Archive -Path "$outputPath\temp\*" -DestinationPath "$outputPath\$nupkgName" -Force\n\n Remove-Item -Path "$outputPath\temp" -Recurse -Force\n Remove-Item -Path $zipPath -Force\n\n if (-not (Test-Path "$outputPath\powershell.windows.x64.*.nupkg")) {\n throw "Global tool package not found at $outputPath"\n }\n displayName: 'Pack Windows.x64 global tool'\n condition: and(succeeded(), eq(variables['Architecture'], 'fxdependent'))\n\n - task: onebranch.pipeline.signing@1\n displayName: Sign nupkg files\n inputs:\n command: 'sign'\n cp_code: 'CP-401405'\n files_to_sign: '**\*.nupkg'\n search_root: '$(ob_outputDirectory)\globaltool'\n condition: and(succeeded(), eq(variables['Architecture'], 'fxdependent'))\n\n - template: /.pipelines/templates/step/finalize.yml@self\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\windows-hosted-build.yml
windows-hosted-build.yml
YAML
14,000
0.8
0.052469
0.05364
python-kit
909
2023-11-02T01:49:55.666542
BSD-3-Clause
false
37ce1ecd487c933ff2ce74d0c05c38cd
parameters:\n runtime: x64\n\njobs:\n- job: package_win_${{ parameters.runtime }}\n displayName: Package Windows ${{ parameters.runtime }}\n condition: succeeded()\n pool:\n type: windows\n\n variables:\n - name: runCodesignValidationInjection\n value: false\n - name: nugetMultiFeedWarnLevel\n value: none\n - name: NugetSecurityAnalysisWarningLevel\n value: none\n - name: skipNugetSecurityAnalysis\n value: true\n - group: DotNetPrivateBuildAccess\n - group: certificate_logical_to_actual\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)\ONEBRANCH_ARTIFACT'\n - name: ob_sdl_binskim_enabled\n value: true\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n - name: Runtime\n value: ${{ parameters.runtime }}\n - group: msixTools\n\n steps:\n - checkout: self\n clean: true\n env:\n ob_restore_phase: true # This ensures checkout is done at the beginning of the restore phase\n\n - pwsh: |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture environment\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n - template: SetVersionVariables.yml@self\n parameters:\n ReleaseTagVar: $(ReleaseTagVar)\n CreateJson: yes\n UseJson: no\n\n - template: shouldSign.yml\n\n - template: cloneToOfficialPath.yml\n parameters:\n nativePathRoot: '$(Agent.TempDirectory)'\n\n - download: CoOrdinatedBuildPipeline\n artifact: drop_windows_build_windows_${{ parameters.runtime }}_release\n displayName: Download signed artifacts\n condition: ${{ ne(parameters.runtime, 'minSize') }}\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n - download: CoOrdinatedBuildPipeline\n artifact: drop_windows_build_windows_x64_${{ parameters.runtime }}\n displayName: Download minsize signed artifacts\n condition: ${{ eq(parameters.runtime, 'minSize') }}\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n - pwsh: |\n Write-Verbose -Verbose "signed artifacts"\n Get-ChildItem "$(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_windows_build_windows_${{ parameters.runtime }}_release" -Recurse\n displayName: 'Capture Downloaded Artifacts'\n # Diagnostics is not critical it passes every time it runs\n continueOnError: true\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n - task: UseDotNet@2\n inputs:\n useGlobalJson: true\n workingDirectory: $(REPOROOT)\n env:\n ob_restore_phase: true\n\n - pwsh: |\n $msixUrl = '$(makeappUrl)'\n Invoke-RestMethod -Uri $msixUrl -OutFile '$(Pipeline.Workspace)\makeappx.zip'\n Expand-Archive '$(Pipeline.Workspace)\makeappx.zip' -destination '\' -Force\n displayName: Install packaging tools\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n - pwsh: |\n $runtime = '$(Runtime)'\n Write-Verbose -Verbose "runtime = '$(Runtime)'"\n\n $signedFolder = switch ($runtime) {\n 'x64' { 'Signed-win7-x64' }\n 'x86' { 'Signed-win7-x86' }\n 'arm64' { 'Signed-win-arm64' }\n 'fxdependent' { 'Signed-fxdependent' }\n 'fxdependentWinDesktop' { 'Signed-fxdependent-win-desktop' }\n 'minsize' { 'Signed-win7-x64' }\n }\n\n Write-Verbose -Message "Init..." -Verbose\n\n $repoRoot = "$env:REPOROOT"\n Import-Module "$repoRoot\build.psm1"\n Import-Module "$repoRoot\tools\packaging"\n\n Start-PSBootstrap -Scenario Package\n\n $signedFilesPath, $psoptionsFilePath = if ($env:RUNTIME -eq 'minsize') {\n "$(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_windows_build_windows_x64_${runtime}\$signedFolder"\n "$(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_windows_build_windows_x64_${runtime}\psoptions\psoptions.json"\n }\n else {\n "$(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_windows_build_windows_${runtime}_release\$signedFolder"\n "$(Pipeline.Workspace)\CoOrdinatedBuildPipeline\drop_windows_build_windows_${runtime}_release\psoptions\psoptions.json"\n }\n\n Write-Verbose -Verbose "signedFilesPath: $signedFilesPath"\n Write-Verbose -Verbose "psoptionsFilePath: $psoptionsFilePath"\n\n Write-Verbose -Message "checking pwsh exists in $signedFilesPath" -Verbose\n if (-not (Test-Path $signedFilesPath\pwsh.exe)) {\n throw "pwsh.exe not found in $signedFilesPath"\n }\n\n Write-Verbose -Message "Restoring PSOptions from $psoptionsFilePath" -Verbose\n\n Restore-PSOptions -PSOptionsPath "$psoptionsFilePath"\n Get-PSOptions | Write-Verbose -Verbose\n\n $metadata = Get-Content "$repoRoot/tools/metadata.json" -Raw | ConvertFrom-Json\n $LTS = $metadata.LTSRelease.Package\n\n if ($LTS) {\n Write-Verbose -Message "LTS Release: $LTS"\n }\n\n Start-PSBootstrap -Scenario Package\n\n $WindowsRuntime = switch ($runtime) {\n 'x64' { 'win7-x64' }\n 'x86' { 'win7-x86' }\n 'arm64' { 'win-arm64' }\n 'fxdependent' { 'win7-x64' }\n 'fxdependentWinDesktop' { 'win7-x64' }\n 'minsize' { 'win7-x64' }\n }\n\n $packageTypes = switch ($runtime) {\n 'x64' { @('msi', 'zip', 'msix') }\n 'x86' { @('msi', 'zip', 'msix') }\n 'arm64' { @('msi', 'zip', 'msix') }\n 'fxdependent' { 'fxdependent' }\n 'fxdependentWinDesktop' { 'fxdependent-win-desktop' }\n 'minsize' { 'min-size' }\n }\n\n if (-not (Test-Path $(ob_outputDirectory))) {\n New-Item -ItemType Directory -Path $(ob_outputDirectory) -Force\n }\n\n Set-Location $repoRoot\n\n Start-PSPackage -Type $packageTypes -SkipReleaseChecks -WindowsRuntime $WindowsRuntime -ReleaseTag $(ReleaseTagVar) -PackageBinPath $signedFilesPath -LTS:$LTS\n\n displayName: 'Package ${{ parameters.buildArchitecture}}'\n env:\n __DOTNET_RUNTIME_FEED_KEY: $(RUNTIME_SOURCEFEED_KEY)\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n - task: onebranch.pipeline.signing@1\n displayName: Sign MSI packages\n inputs:\n command: 'sign'\n signing_profile: external_distribution\n files_to_sign: '**\*.msi'\n search_root: '$(Pipeline.Workspace)'\n\n - pwsh: |\n $runtime = '$(Runtime)'\n Write-Verbose -Verbose "runtime = '$(Runtime)'"\n\n $repoRoot = "$env:REPOROOT"\n Import-Module "$repoRoot\build.psm1"\n Import-Module "$repoRoot\tools\packaging"\n\n $noExeRuntimes = @('fxdependent', 'fxdependentWinDesktop', 'minsize')\n\n if ($runtime -in $noExeRuntimes) {\n Write-Verbose -Verbose "No EXE generated for $runtime"\n return\n }\n\n $version = '$(Version)'\n\n $msiLocation = Get-ChildItem -Path $(Pipeline.Workspace) -Recurse -Filter "powershell-*$runtime.msi" | Select-Object -ExpandProperty FullName\n Write-Verbose -Verbose "msiLocation: $msiLocation"\n\n Set-Location $repoRoot\n\n $exePath = New-ExePackage -ProductVersion $version -ProductTargetArchitecture $runtime -MsiLocationPath $msiLocation\n Write-Verbose -Verbose "setting vso[task.setvariable variable=exePath]$exePath"\n Write-Host "##vso[task.setvariable variable=exePath]$exePath"\n Write-Verbose -Verbose "exePath: $exePath"\n\n $enginePath = Join-Path -Path '$(System.ArtifactsDirectory)\unsignedEngine' -ChildPath engine.exe\n Expand-ExePackageEngine -ExePath $exePath -EnginePath $enginePath -ProductTargetArchitecture $runtime\n displayName: 'Make exe and expand package'\n\n - task: onebranch.pipeline.signing@1\n displayName: Sign exe engine\n inputs:\n command: 'sign'\n signing_profile: $(msft_3rd_party_cert_id)\n files_to_sign: '$(System.ArtifactsDirectory)\unsignedEngine\*.exe'\n search_root: '$(Pipeline.Workspace)'\n\n - pwsh: |\n $runtime = '$(Runtime)'\n Write-Verbose -Verbose "runtime = '$(Runtime)'"\n $repoRoot = "$env:REPOROOT"\n Import-Module "$repoRoot\build.psm1"\n Import-Module "$repoRoot\tools\packaging"\n\n $noExeRuntimes = @('fxdependent', 'fxdependentWinDesktop', 'minsize')\n\n if ($runtime -in $noExeRuntimes) {\n Write-Verbose -Verbose "No EXE generated for $runtime"\n return\n }\n\n $exePath = '$(exePath)'\n $enginePath = Join-Path -Path '$(System.ArtifactsDirectory)\unsignedEngine' -ChildPath engine.exe\n $enginePath | Get-AuthenticodeSignature | out-string | Write-Verbose -verbose\n Compress-ExePackageEngine -ExePath $exePath -EnginePath $enginePath -ProductTargetArchitecture $runtime\n displayName: Compress signed exe package\n\n - task: onebranch.pipeline.signing@1\n displayName: Sign exe packages\n inputs:\n command: 'sign'\n signing_profile: external_distribution\n files_to_sign: '**\*.exe'\n search_root: '$(Pipeline.Workspace)'\n\n - pwsh: |\n $runtime = '$(Runtime)'\n Write-Verbose -Verbose "runtime = '$(Runtime)'"\n\n $packageTypes = switch ($runtime) {\n 'x64' { @('msi', 'zip', 'msix', 'exe') }\n 'x86' { @('msi', 'zip', 'msix', 'exe') }\n 'arm64' { @('msi', 'zip', 'msix', 'exe') }\n 'fxdependent' { 'fxdependent' }\n 'fxdependentWinDesktop' { 'fxdependent-win-desktop' }\n 'minsize' { 'min-size' }\n }\n\n if (-not (Test-Path $(ob_outputDirectory))) {\n New-Item -ItemType Directory -Path $(ob_outputDirectory) -Force\n }\n\n if ($packageTypes -contains 'msi') {\n $msiPkgNameFilter = "powershell-*.msi"\n $msiPkgPath = Get-ChildItem -Path $(Pipeline.Workspace) -Filter $msiPkgNameFilter -Recurse -File | Select-Object -ExpandProperty FullName\n Write-Verbose -Verbose "msiPkgPath: $msiPkgPath"\n Copy-Item -Path $msiPkgPath -Destination '$(ob_outputDirectory)' -Force -Verbose\n }\n\n if ($packageTypes -contains 'exe') {\n $msiPkgNameFilter = "powershell-*.exe"\n $msiPkgPath = Get-ChildItem -Path $(Pipeline.Workspace) -Filter $msiPkgNameFilter -Recurse -File | Select-Object -ExpandProperty FullName\n Write-Verbose -Verbose "msiPkgPath: $msiPkgPath"\n Copy-Item -Path $msiPkgPath -Destination '$(ob_outputDirectory)' -Force -Verbose\n }\n\n if ($packageTypes -contains 'zip' -or $packageTypes -contains 'fxdependent' -or $packageTypes -contains 'min-size' -or $packageTypes -contains 'fxdependent-win-desktop') {\n $zipPkgNameFilter = "powershell-*.zip"\n $zipPkgPath = Get-ChildItem -Path $(Pipeline.Workspace) -Filter $zipPkgNameFilter -Recurse -File | Select-Object -ExpandProperty FullName\n Write-Verbose -Verbose "zipPkgPath: $zipPkgPath"\n Copy-Item -Path $zipPkgPath -Destination '$(ob_outputDirectory)' -Force -Verbose\n }\n\n if ($packageTypes -contains 'msix') {\n $msixPkgNameFilter = "powershell-*.msix"\n $msixPkgPath = Get-ChildItem -Path $(Pipeline.Workspace) -Filter $msixPkgNameFilter -Recurse -File | Select-Object -ExpandProperty FullName\n Write-Verbose -Verbose "msixPkgPath: $msixPkgPath"\n Copy-Item -Path $msixPkgPath -Destination '$(ob_outputDirectory)' -Force -Verbose\n }\n displayName: Copy to output directory\n\n - pwsh: |\n Get-ChildItem -Path $(ob_outputDirectory) -Recurse\n displayName: 'List artifacts'\n env:\n ob_restore_phase: true # This ensures this done in restore phase to workaround signing issue\n\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\windows-package-build.yml
windows-package-build.yml
YAML
11,724
0.8
0.055738
0.004016
vue-tools
626
2024-05-11T18:19:35.250319
BSD-3-Clause
false
90c40ee6cd3796703134d637fe9cb93d
# Copyright (c) Microsoft Corporation.\n# Licensed under the MIT License.\n\njobs:\n - job: APIScan\n variables:\n - name: runCodesignValidationInjection\n value : false\n - name: NugetSecurityAnalysisWarningLevel\n value: none\n - name: ReleaseTagVar\n value: fromBranch\n # Defines the variables APIScanClient, APIScanTenant and APIScanSecret\n - group: PS-PS-APIScan\n - name: branchCounterKey\n value: $[format('{0:yyyyMMdd}-{1}', pipeline.startTime,variables['Build.SourceBranch'])]\n - name: branchCounter\n value: $[counter(variables['branchCounterKey'], 1)]\n - group: DotNetPrivateBuildAccess\n - group: Azure Blob variable group\n - group: ReleasePipelineSecrets\n - group: mscodehub-feed-read-general\n - group: mscodehub-feed-read-akv\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: repoRoot\n value: '$(Build.SourcesDirectory)\PowerShell'\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n - name: Codeql.SourceRoot\n value: $(repoRoot)\n\n pool:\n type: windows\n\n # APIScan can take a long time\n timeoutInMinutes: 180\n\n steps:\n - checkout: self\n clean: true\n fetchTags: true\n fetchDepth: 1000\n displayName: Checkout PowerShell\n retryCountOnTaskFailure: 1\n env:\n ob_restore_phase: true # This ensures checkout is done at the beginning of the restore phase\n\n - template: ../SetVersionVariables.yml\n parameters:\n ReleaseTagVar: $(ReleaseTagVar)\n CreateJson: yes\n UseJson: no\n\n - template: ../insert-nuget-config-azfeed.yml\n parameters:\n repoRoot: '$(repoRoot)'\n\n - task: UseDotNet@2\n displayName: 'Use .NET Core sdk'\n inputs:\n useGlobalJson: true\n packageType: 'sdk'\n workingDirectory: $(Build.SourcesDirectory)"\n\n - pwsh: |\n Import-Module .\build.psm1 -force\n Find-DotNet\n dotnet tool install dotnet-symbol --tool-path $(Agent.ToolsDirectory)\tools\dotnet-symbol\n $symbolToolPath = Get-ChildItem -Path $(Agent.ToolsDirectory)\tools\dotnet-symbol\dotnet-symbol.exe | Select-Object -First 1 -ExpandProperty FullName\n Write-Host "##vso[task.setvariable variable=symbolToolPath]$symbolToolPath"\n displayName: Install dotnet-symbol\n workingDirectory: '$(repoRoot)'\n retryCountOnTaskFailure: 2\n\n - task: AzurePowerShell@5\n displayName: Download winverify-private Artifacts\n inputs:\n azureSubscription: az-blob-cicd-infra\n scriptType: inlineScript\n azurePowerShellVersion: LatestVersion\n workingDirectory: '$(repoRoot)'\n pwsh: true\n inline: |\n # download smybols for getfilesiginforedist.dll\n $downloadsDirectory = '$(Build.ArtifactStagingDirectory)/downloads'\n $uploadedDirectory = '$(Build.ArtifactStagingDirectory)/uploaded'\n $storageAccountName = "pscoretestdata"\n $containerName = 'winverify-private'\n $winverifySymbolsPath = New-Item -ItemType Directory -Path '$(System.ArtifactsDirectory)/winverify-symbols' -Force\n $dllName = 'getfilesiginforedist.dll'\n $winverifySymbolsDllPath = Join-Path $winverifySymbolsPath $dllName\n\n $context = New-AzStorageContext -StorageAccountName $storageAccountName -UseConnectedAccount\n\n Get-AzStorageBlobContent -Container $containerName -Blob $dllName -Destination $winverifySymbolsDllPath -Context $context\n\n - pwsh: |\n Get-ChildItem -Path '$(System.ArtifactsDirectory)/winverify-symbols'\n displayName: Capture winverify-private Artifacts\n workingDirectory: '$(repoRoot)'\n condition: succeededOrFailed()\n\n - task: CodeQL3000Init@0 # Add CodeQL Init task right before your 'Build' step.\n displayName: 🔏 CodeQL 3000 Init\n condition: eq(variables['CODEQL_ENABLED'], 'true')\n inputs:\n Language: csharp\n\n - pwsh: |\n Import-Module .\build.psm1 -force\n Find-DotNet\n Start-PSBuild -Configuration StaticAnalysis -PSModuleRestore -Clean -Runtime fxdependent-win-desktop\n\n $OutputFolder = Split-Path (Get-PSOutput)\n\n Write-Verbose -Verbose -Message "Deleting ref folder from output folder"\n if (Test-Path $OutputFolder/ref) {\n Remove-Item -Recurse -Force $OutputFolder/ref\n }\n\n Copy-Item -Path "$OutputFolder\*" -Destination '$(ob_outputDirectory)' -Recurse -Verbose\n workingDirectory: '$(repoRoot)'\n displayName: 'Build PowerShell Source'\n\n - pwsh: |\n # Only key windows runtimes\n Get-ChildItem -Path '$(ob_outputDirectory)\runtimes\*' -File -Recurse | Where-Object {$_.FullName -notmatch '.*\/runtimes\/win'} | Foreach-Object {\n Write-Verbose -Verbose -Message "Deleting $($_.FullName)"\n Remove-Item -Force -Verbose -Path $_.FullName\n }\n\n # Temporarily remove runtimes/win-x64 due to issues with that runtime\n Get-ChildItem -Path '$(ob_outputDirectory)\runtimes\*' -File -Recurse | Where-Object {$_.FullName -match '.*\/runtimes\/win-x86\/'} | Foreach-Object {\n Write-Verbose -Verbose -Message "Deleting $($_.FullName)"\n Remove-Item -Force -Verbose -Path $_.FullName\n }\n\n workingDirectory: '$(repoRoot)'\n displayName: 'Remove unused runtimes'\n\n - task: CodeQL3000Finalize@0 # Add CodeQL Finalize task right after your 'Build' step.\n displayName: 🔏 CodeQL 3000 Finalize\n condition: eq(variables['CODEQL_ENABLED'], 'true')\n\n - pwsh: |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n workingDirectory: '$(repoRoot)'\n displayName: Capture Environment\n condition: succeededOrFailed()\n\n # Explicitly download symbols for the drop since the SDL image doesn't have http://SymWeb access and APIScan cannot handle https yet.\n - pwsh: |\n Import-Module .\build.psm1 -force\n Find-DotNet\n $pat = '$(SymbolServerPAT)'\n if ($pat -like '*PAT*' -or $pat -eq '')\n {\n throw 'No PAT defined'\n }\n $url = 'https://microsoft.artifacts.visualstudio.com/defaultcollection/_apis/symbol/symsrv'\n $(symbolToolPath) --authenticated-server-path $(SymbolServerPAT) $url --symbols -d "$env:ob_outputDirectory\*" --recurse-subdirectories\n displayName: 'Download Symbols for binaries'\n retryCountOnTaskFailure: 2\n workingDirectory: '$(repoRoot)'\n\n - pwsh: |\n Get-ChildItem '$(ob_outputDirectory)' -File -Recurse |\n Foreach-Object {\n [pscustomobject]@{\n Path = $_.FullName\n Version = $_.VersionInfo.FileVersion\n Md5Hash = (Get-FileHash -Algorithm MD5 -Path $_.FullName).Hash\n Sha512Hash = (Get-FileHash -Algorithm SHA512 -Path $_.FullName).Hash\n }\n } | Export-Csv -Path '$(Build.SourcesDirectory)/ReleaseFileHash.csv'\n workingDirectory: '$(repoRoot)'\n displayName: 'Create release file hash artifact'\n\n - pwsh: |\n Copy-Item -Path '$(Build.SourcesDirectory)/ReleaseFileHash.csv' -Destination '$(ob_outputDirectory)' -Verbose\n displayName: 'Publish Build File Hash artifact'\n\n - pwsh: |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture Environment\n condition: succeededOrFailed()\n workingDirectory: '$(repoRoot)'\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\compliance\apiscan.yml
apiscan.yml
YAML
7,671
0.8
0.026316
0.04878
react-lib
97
2023-09-18T21:44:51.650038
BSD-3-Clause
false
def94d9cd95bd137a15590965cbcfa93
# Copyright (c) Microsoft Corporation.\n# Licensed under the MIT License.\n\nparameters:\n - name: parentJobs\n type: jobList\n - name: SkipVerifyPackages\n type: boolean\n\njobs:\n- job: generateNotice\n variables:\n - name: runCodesignValidationInjection\n value : false\n - name: NugetSecurityAnalysisWarningLevel\n value: none\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT/notice'\n - name: ob_sdl_apiscan_enabled\n value: false\n - name: repoRoot\n value: '$(Build.SourcesDirectory)\PowerShell'\n - name: ob_sdl_tsa_configFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\tsaoptions.json\n - name: ob_sdl_credscan_suppressionsFile\n value: $(Build.SourcesDirectory)\PowerShell\.config\suppress.json\n\n displayName: Generate Notice\n dependsOn:\n ${{ parameters.parentJobs }}\n pool:\n type: windows\n\n timeoutInMinutes: 15\n\n steps:\n - checkout: self\n clean: true\n\n - pwsh: |\n [string]$Branch=$env:BUILD_SOURCEBRANCH\n $branchOnly = $Branch -replace '^refs/heads/';\n $branchOnly = $branchOnly -replace '[_\-]'\n\n if ($branchOnly -eq 'master') {\n $container = 'tpn'\n } else {\n $branchOnly = $branchOnly -replace '[\./]', '-'\n $container = "tpn-$branchOnly"\n }\n\n $vstsCommandString = "vso[task.setvariable variable=tpnContainer]$container"\n Write-Verbose -Message $vstsCommandString -Verbose\n Write-Host -Object "##$vstsCommandString"\n displayName: Set ContainerName\n\n - task: ms.vss-governance-buildtask.governance-build-task-component-detection.ComponentGovernanceComponentDetection@0\n displayName: 'Component Detection'\n inputs:\n sourceScanPath: '$(repoRoot)\tools'\n\n - pwsh: |\n $(repoRoot)/tools/clearlyDefined/ClearlyDefined.ps1 -TestAndHarvest\n displayName: Verify that packages have license data\n condition: eq(${{ parameters.SkipVerifyPackages }}, false)\n\n - task: msospo.ospo-extension.8d7f9abb-6896-461d-9e25-4f74ed65ddb2.notice@0\n displayName: 'NOTICE File Generator'\n inputs:\n outputfile: '$(ob_outputDirectory)\ThirdPartyNotices.txt'\n # output format can be html or text\n outputformat: text\n # this isn't working\n # additionaldata: $(Build.SourcesDirectory)\assets\additionalAttributions.txt\n\n - pwsh: |\n Get-Content -Raw -Path $(repoRoot)\assets\additionalAttributions.txt | Out-File '$(ob_outputDirectory)\ThirdPartyNotices.txt' -Encoding utf8NoBOM -Force -Append\n Get-Content -Raw -Path $(repoRoot)\assets\additionalAttributions.txt\n displayName: Append Additional Attributions\n continueOnError: true\n\n - pwsh: |\n Get-Content -Raw -Path '$(ob_outputDirectory)\ThirdPartyNotices.txt'\n displayName: Capture Notice\n continueOnError: true\n\n - task: AzurePowerShell@5\n displayName: Upload Notice\n inputs:\n azureSubscription: az-blob-cicd-infra\n scriptType: inlineScript\n azurePowerShellVersion: LatestVersion\n workingDirectory: '$(repoRoot)'\n pwsh: true\n inline: |\n try {\n $downloadsDirectory = '$(Build.ArtifactStagingDirectory)/downloads'\n $uploadedDirectory = '$(Build.ArtifactStagingDirectory)/uploaded'\n $storageAccountName = "pscoretestdata"\n $containerName = '$(tpnContainer)'\n $blobName = 'ThirdPartyNotices.txt'\n $noticePath = "$(ob_outputDirectory)\$blobName"\n\n Write-Verbose -Verbose "creating context ($storageAccountName) ..."\n $context = New-AzStorageContext -StorageAccountName $storageAccountName -UseConnectedAccount\n\n Write-Verbose -Verbose "checking if container ($containerName) exists ..."\n $containerExists = Get-AzStorageContainer -Name $containerName -Context $context -ErrorAction SilentlyContinue\n if (-not $containerExists) {\n Write-Verbose -Verbose "Creating container ..."\n $null = New-AzStorageContainer -Name $containerName -Context $context\n Write-Verbose -Verbose "Blob container $containerName created successfully."\n }\n\n Write-Verbose -Verbose "Setting blob ($blobName) content ($noticePath) ..."\n $null = Set-AzStorageBlobContent -File $noticePath -Container $containerName -Blob $blobName -Context $context -confirm:$false -force\n Write-Verbose -Verbose "Done"\n } catch {\n Get-Error\n throw\n }\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\compliance\generateNotice.yml
generateNotice.yml
YAML
4,416
0.8
0.041322
0.048077
node-utils
500
2024-02-11T22:03:51.209813
Apache-2.0
false
63a273af3c82f9ea90de29d64ef4b8cd
# This was used before migrating to OneBranch to deal with one of the SDL taks from failing with a warning instead of an error.\nsteps:\n- pwsh: |\n throw "Jobs with an Issue will not work for release. Please fix the issue and try again."\n displayName: Check for SucceededWithIssues\n condition: eq(variables['Agent.JobStatus'],'SucceededWithIssues')\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\step\finalize.yml
finalize.yml
YAML
352
0.8
0.5
0.166667
vue-tools
926
2024-06-07T19:07:03.509047
MIT
false
7a6b77f24d7aca3222bbeab253e88ad9
parameters:\n - name: REPOROOT\n type: string\n default: $(Build.SourcesDirectory)\PowerShell\n - name: SBOM\n type: boolean\n default: false\n - name: RELEASETAG\n type: string\n default: 'Not Initialized'\n - name: VERSION\n type: string\n default: 'Not Initialized'\n\nvariables:\n - name: ob_signing_setup_enabled \n value: false\n - name: ob_sdl_sbom_enabled\n value: ${{ parameters.SBOM }}\n - name: runCodesignValidationInjection\n value: false\n - name: DOTNET_SKIP_FIRST_TIME_EXPERIENCE\n value: 1\n - group: 'mscodehub-code-read-akv'\n - group: 'Azure Blob variable group'\n - group: 'GitHubTokens'\n - name: ob_outputDirectory\n value: '$(Build.ArtifactStagingDirectory)/ONEBRANCH_ARTIFACT'\n - name: ob_sdl_codeSignValidation_enabled\n value: false\n - name: ob_sdl_binskim_enabled\n value: false\n - name: ob_sdl_tsa_configFile\n value: ${{ parameters.REPOROOT }}\.config\tsaoptions.json\n - name: ob_sdl_credscan_suppressionsFile\n value: ${{ parameters.REPOROOT }}\.config\suppress.json\n - name: ob_sdl_codeql_compiled_enabled\n value: false\n - name: ReleaseTag\n value: ${{ parameters.RELEASETAG }}\n - name: Version\n value: ${{ parameters.VERSION }}\n
dataset_sample\yaml\PowerShell_PowerShell\.pipelines\templates\variable\release-shared.yml
release-shared.yml
YAML
1,219
0.7
0
0
awesome-app
384
2024-07-09T09:05:03.583944
GPL-3.0
false
3104ea2bea4711b954a3f1bc5e738b8c
name: PR-$(System.PullRequest.PullRequestNumber)-$(Date:yyyyMMdd)$(Rev:.rr)\ntrigger:\n # Batch merge builds together while a merge build is running\n batch: true\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n include:\n - /tools/install-powershell.*\n - /tools/installpsh-*.sh\n - /.vsts-ci/install-ps.yml\npr:\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n include:\n - /tools/install-powershell.sh\n - /tools/installpsh-*.sh\n - /tools/install-powershell.ps1\n - /.vsts-ci/install-ps.yml\n\nvariables:\n DOTNET_CLI_TELEMETRY_OPTOUT: 1\n POWERSHELL_TELEMETRY_OPTOUT: 1\n\nresources:\n- repo: self\n clean: true\nphases:\n- template: templates/install-ps-phase.yml\n parameters:\n scriptName: sudo ./tools/install-powershell.sh\n jobName: InstallPowerShellUbuntu\n pool: ubuntu-latest\n verification: |\n if ([Version]"$($PSVersionTable.PSVersion.Major).$($PSVersionTable.PSVersion.Minor).$($PSVersionTable.PSVersion.Patch)" -lt [version]"7.3.0")\n {\n throw "powershell was not upgraded: $($PSVersionTable.PSVersion)"\n }\n\n- template: templates/install-ps-phase.yml\n parameters:\n scriptName: sudo ./tools/install-powershell.sh\n jobName: InstallPowerShellMariner2\n pool: ubuntu-latest\n container: mcr.microsoft.com/powershell/test-deps:mariner-2.0\n verification: |\n if ([Version]"$($PSVersionTable.PSVersion.Major).$($PSVersionTable.PSVersion.Minor).$($PSVersionTable.PSVersion.Patch)" -lt [version]"7.3.0")\n {\n throw "powershell was not upgraded: $($PSVersionTable.PSVersion)"\n }\n\n- template: templates/install-ps-phase.yml\n parameters:\n scriptName: sudo ./tools/install-powershell.sh\n jobName: InstallPowerShellAmazonLinux\n pool: ubuntu-latest\n container: pshorg/powershellcommunity-test-deps:amazonlinux-2.0\n verification: |\n if ([Version]"$($PSVersionTable.PSVersion.Major).$($PSVersionTable.PSVersion.Minor).$($PSVersionTable.PSVersion.Patch)" -lt [version]"7.3.0")\n {\n throw "powershell was not upgraded: $($PSVersionTable.PSVersion)"\n }\n\n- template: templates/install-ps-phase.yml\n parameters:\n scriptName: sudo ./tools/installpsh-amazonlinux.sh\n jobName: InstallPSHAmazonLinux\n pool: ubuntu-latest\n container: pshorg/powershellcommunity-test-deps:amazonlinux-2.0\n verification: |\n if ([Version]"$($PSVersionTable.PSVersion.Major).$($PSVersionTable.PSVersion.Minor).$($PSVersionTable.PSVersion.Patch)" -lt [version]"7.3.0")\n {\n throw "powershell was not upgraded: $($PSVersionTable.PSVersion)"\n }\n continueOnError: false\n\n# TODO: add sudo to script and use image with sudo\n- template: templates/install-ps-phase.yml\n parameters:\n scriptName: ./tools/install-powershell.sh\n jobName: InstallPowerShellCentOS\n pool: ubuntu-latest\n container: mcr.microsoft.com/powershell/test-deps:centos-7\n\n- template: templates/install-ps-phase.yml\n parameters:\n scriptName: ./tools/install-powershell.sh\n jobName: InstallPowerShellDebian9\n pool: ubuntu-latest\n container: mcr.microsoft.com/powershell/test-deps:debian-9\n\n\n# VSTS could not find pwsh in:\n# mcr.microsoft.com/powershell:opensuse-42.3\n# could not repo locally\n\n# sudo is not needed on macOS\n- template: templates/install-ps-phase.yml\n parameters:\n scriptName: ./tools/install-powershell.sh\n jobName: InstallPowerShellMacOS\n pool: macOS-latest\n verification: |\n if ([Version]"$($PSVersionTable.PSVersion.Major).$($PSVersionTable.PSVersion.Minor).$($PSVersionTable.PSVersion.Patch)" -lt [version]"7.3.0")\n {\n # The script does not upgrade on mac os https://github.com/PowerShell/PowerShell/issues/9322\n Write-Warning "powershell was not upgraded: $($PSVersionTable.PSVersion)"\n }\n\n- template: templates/install-ps-phase.yml\n parameters:\n scriptName: pwsh -c ./tools/install-powershell.ps1 -AddToPath\n jobName: InstallPowerShellPS1Ubuntu\n pool: ubuntu-latest\n\n- template: templates/install-ps-phase.yml\n parameters:\n scriptName: pwsh -c ./tools/install-powershell.ps1 -AddToPath -Daily\n jobName: InstallPowerShellPS1UbuntuDaily\n pool: ubuntu-latest\n verification: |\n Write-Verbose $PSVersionTable.PSVersion -verbose\n if ([Version]"$($PSVersionTable.PSVersion.Major).$($PSVersionTable.PSVersion.Minor).$($PSVersionTable.PSVersion.Patch)" -lt [version]"7.3.0")\n {\n throw "powershell was not upgraded: $($PSVersionTable.PSVersion)"\n }\n\n- template: templates/install-ps-phase.yml\n parameters:\n scriptName: pwsh -c ./tools/install-powershell.ps1 -AddToPath -Daily\n jobName: InstallPowerShellMacOSDaily\n pool: macOS-latest\n verification: |\n Write-Verbose $PSVersionTable.PSVersion -verbose\n if ([Version]"$($PSVersionTable.PSVersion.Major).$($PSVersionTable.PSVersion.Minor).$($PSVersionTable.PSVersion.Patch)" -lt [version]"7.0.0")\n {\n throw "powershell was not upgraded: $($PSVersionTable.PSVersion)"\n }\n\n- template: templates/install-ps-phase.yml\n parameters:\n scriptName: |\n pwsh -c ./tools/install-powershell.ps1 -AddToPath -Daily\n jobName: InstallPowerShellWindowsDaily\n pool: windows-latest\n verification: |\n $newVersion = &$env:LOCALAPPDATA\Microsoft\powershell-daily\pwsh -v\n $newVersion -match '^PowerShell ((\d*\.\d*\.\d*)(-\w*(\.\d*)?)?){1}'\n $versionOnly = $Matches[2]\n Write-verbose "$newVersion; versionOnly: $versionOnly" -verbose\n if ([Version]$versionOnly -lt [version]"7.0.0")\n {\n throw "powershell was not upgraded: $newVersion"\n }\n
dataset_sample\yaml\PowerShell_PowerShell\.vsts-ci\install-ps.yml
install-ps.yml
YAML
5,632
0.8
0.055901
0.047619
react-lib
745
2025-05-01T10:39:45.121454
MIT
false
a88d81c67b6dbda64e058a1209d7ce7c
name: PR-$(System.PullRequest.PullRequestNumber)-$(Date:yyyyMMdd)$(Rev:.rr)\ntrigger:\n # Batch merge builds together while a merge build is running\n batch: true\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n include:\n - '*'\n exclude:\n - /.vsts-ci/misc-analysis.yml\n - /.github/ISSUE_TEMPLATE/*\n - /.dependabot/config.yml\npr:\n branches:\n include:\n - master\n paths:\n include:\n - .vsts-ci/linux-daily.yml\n\nvariables:\n DOTNET_CLI_TELEMETRY_OPTOUT: 1\n POWERSHELL_TELEMETRY_OPTOUT: 1\n # Avoid expensive initialization of dotnet cli, see: https://donovanbrown.com/post/Stop-wasting-time-during-NET-Core-builds\n DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1\n __SuppressAnsiEscapeSequences: 1\n\nresources:\n- repo: self\n clean: true\n\nstages:\n- stage: BuildLinux\n displayName: Build for Linux\n jobs:\n - template: templates/ci-build.yml\n parameters:\n pool: ubuntu-20.04\n jobName: linux_build\n displayName: linux Build\n\n- stage: TestLinux\n displayName: Test for Linux\n jobs:\n - job: linux_test\n timeoutInMinutes: 90\n pool:\n vmImage: ubuntu-20.04\n displayName: Linux Test\n\n steps:\n - pwsh: |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture Environment\n condition: succeededOrFailed()\n\n - task: DownloadBuildArtifacts@0\n displayName: 'Download Build Artifacts'\n inputs:\n downloadType: specific\n itemPattern: |\n build/**/*\n xunit/**/*\n downloadPath: '$(System.ArtifactsDirectory)'\n\n - pwsh: |\n Get-ChildItem "$(System.ArtifactsDirectory)\*" -Recurse\n displayName: 'Capture Artifacts Directory'\n continueOnError: true\n\n - pwsh: |\n Import-Module .\tools\ci.psm1\n Invoke-CIInstall -SkipUser\n displayName: Bootstrap\n condition: succeededOrFailed()\n\n - pwsh: |\n Import-Module .\build.psm1\n Restore-PSOptions -PSOptionsPath '$(System.ArtifactsDirectory)\build\psoptions.json'\n $output = (Get-PSOptions).Output\n $rootPath = Split-Path (Split-Path $output)\n Expand-Archive -Path '$(System.ArtifactsDirectory)\build\build.zip' -DestinationPath $rootPath -Force\n\n ## Fix permissions\n Get-ChildItem $rootPath -Recurse | ForEach-Object {\n if ($_ -is [System.IO.DirectoryInfo]) {\n chmod +rwx $_.FullName\n } else {\n chmod +rw $_.FullName\n }\n }\n chmod a+x $output\n\n Write-Host "=== Capture Unzipped Directory ==="\n Get-ChildItem $rootPath -Recurse\n displayName: 'Unzip Build and Fix Permissions'\n condition: succeeded()\n\n - pwsh: |\n Import-Module .\tools\ci.psm1\n Restore-PSOptions -PSOptionsPath '$(System.ArtifactsDirectory)\build\psoptions.json'\n Invoke-CITest -Purpose UnelevatedPesterTests -TagSet CI\n displayName: Test - UnelevatedPesterTests - CI\n condition: succeeded()\n\n - pwsh: |\n Import-Module .\tools\ci.psm1\n Restore-PSOptions -PSOptionsPath '$(System.ArtifactsDirectory)\build\psoptions.json'\n Invoke-CITest -Purpose ElevatedPesterTests -TagSet CI\n displayName: Test - ElevatedPesterTests - CI\n condition: succeededOrFailed()\n\n - pwsh: |\n Import-Module .\tools\ci.psm1\n Restore-PSOptions -PSOptionsPath '$(System.ArtifactsDirectory)\build\psoptions.json'\n Invoke-CITest -Purpose UnelevatedPesterTests -TagSet Others\n displayName: Test - UnelevatedPesterTests - Others\n condition: succeededOrFailed()\n\n - pwsh: |\n Import-Module .\tools\ci.psm1\n Restore-PSOptions -PSOptionsPath '$(System.ArtifactsDirectory)\build\psoptions.json'\n Invoke-CITest -Purpose ElevatedPesterTests -TagSet Others\n displayName: Test - ElevatedPesterTests - Others\n condition: succeededOrFailed()\n\n - pwsh: |\n Import-Module .\build.psm1\n $xUnitTestResultsFile = "$(System.ArtifactsDirectory)\xunit\xUnitTestResults.xml"\n Test-XUnitTestResults -TestResultsFile $xUnitTestResultsFile\n displayName: Verify xUnit Test Results\n condition: succeededOrFailed()\n\n- stage: CodeCovTestPackage\n displayName: CodeCoverage and Test Packages\n dependsOn: [] # by specifying an empty array, this stage doesn't depend on the stage before it\n jobs:\n - job: CodeCovTestPackage\n displayName: CodeCoverage and Test Packages\n pool:\n vmImage: ubuntu-20.04\n steps:\n - pwsh: |\n Import-Module .\tools\ci.psm1\n New-CodeCoverageAndTestPackage\n displayName: CodeCoverage and Test Package\n
dataset_sample\yaml\PowerShell_PowerShell\.vsts-ci\linux-daily.yml
linux-daily.yml
YAML
4,656
0.8
0.026667
0.022556
awesome-app
806
2023-12-05T14:25:04.554237
MIT
false
53239868875103c671c1f804e40844f5
# Pipeline to run Linux CI internally\nname: PR-$(System.PullRequest.PullRequestNumber)-$(Date:yyyyMMdd)$(Rev:.rr)\ntrigger:\n # Batch merge builds together while a merge build is running\n batch: true\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n include:\n - '*'\n exclude:\n - .vsts-ci/misc-analysis.yml\n - .github/ISSUE_TEMPLATE/*\n - .github/workflows/*\n - .dependabot/config.yml\n - .pipelines/*\n - test/perf/*\npr:\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n include:\n - '*'\n exclude:\n - .dependabot/config.yml\n - .github/ISSUE_TEMPLATE/*\n - .github/workflows/*\n - .vsts-ci/misc-analysis.yml\n - .vsts-ci/windows.yml\n - .vsts-ci/windows/*\n - tools/cgmanifest.json\n - LICENSE.txt\n - test/common/markdown/*\n - test/perf/*\n - tools/releaseBuild/*\n - tools/install*\n - tools/releaseBuild/azureDevOps/templates/*\n - README.md\n - .spelling\n - .pipelines/*\n\nvariables:\n DOTNET_CLI_TELEMETRY_OPTOUT: 1\n POWERSHELL_TELEMETRY_OPTOUT: 1\n # Avoid expensive initialization of dotnet cli, see: https://donovanbrown.com/post/Stop-wasting-time-during-NET-Core-builds\n DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1\n __SuppressAnsiEscapeSequences: 1\n nugetMultiFeedWarnLevel: none\n\nresources:\n repositories:\n - repository: Docker\n type: github\n endpoint: PowerShell\n name: PowerShell/PowerShell-Docker\n ref: master\n\nstages:\n- stage: BuildLinuxStage\n displayName: Build for Linux\n jobs:\n - template: templates/ci-build.yml\n parameters:\n pool: ubuntu-20.04\n jobName: linux_build\n displayName: linux Build\n\n- stage: TestUbuntu\n displayName: Test for Ubuntu\n dependsOn: [BuildLinuxStage]\n jobs:\n - template: templates/nix-test.yml\n parameters:\n name: Ubuntu\n pool: ubuntu-20.04\n purpose: UnelevatedPesterTests\n tagSet: CI\n\n - template: templates/nix-test.yml\n parameters:\n name: Ubuntu\n pool: ubuntu-20.04\n purpose: ElevatedPesterTests\n tagSet: CI\n\n - template: templates/nix-test.yml\n parameters:\n name: Ubuntu\n pool: ubuntu-20.04\n purpose: UnelevatedPesterTests\n tagSet: Others\n\n - template: templates/nix-test.yml\n parameters:\n name: Ubuntu\n pool: ubuntu-20.04\n purpose: ElevatedPesterTests\n tagSet: Others\n\n - template: templates/verify-xunit.yml\n parameters:\n pool: ubuntu-20.04\n\n- stage: PackageLinux\n displayName: Package Linux\n dependsOn: ["BuildLinuxStage"]\n jobs:\n - template: linux/templates/packaging.yml\n parameters:\n pool: ubuntu-20.04\n
dataset_sample\yaml\PowerShell_PowerShell\.vsts-ci\linux-internal.yml
linux-internal.yml
YAML
2,638
0.8
0.025862
0.028037
vue-tools
789
2023-08-07T20:06:59.098531
GPL-3.0
false
6a7802c2daa5a9358ff66a838c919e71
parameters:\n - name: ContainerPattern\n displayName: |\n Pattern to match JobName of the container.\n Update this to force a container.\n `.` will match everything\n type: string\n default: .\n\nname: PR-$(System.PullRequest.PullRequestNumber)-$(Date:yyyyMMdd)$(Rev:.rr)\ntrigger:\n # Batch merge builds together while a merge build is running\n batch: true\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n include:\n - '*'\n exclude:\n - .vsts-ci/misc-analysis.yml\n - .github/ISSUE_TEMPLATE/*\n - .github/workflows/*\n - .dependabot/config.yml\n - .pipelines/*\n - test/perf/*\npr:\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n include:\n - .vsts-ci/linux.yml\n - .vsts-ci/linux/templates/packaging.yml\n - assets/manpage/*\n - build.psm1\n - global.json\n - nuget.config\n - PowerShell.Common.props\n - src/*.csproj\n - tools/ci.psm1\n - tools/packaging/*\n\nvariables:\n DOTNET_CLI_TELEMETRY_OPTOUT: 1\n POWERSHELL_TELEMETRY_OPTOUT: 1\n # Avoid expensive initialization of dotnet cli, see: https://donovanbrown.com/post/Stop-wasting-time-during-NET-Core-builds\n DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1\n __SuppressAnsiEscapeSequences: 1\n nugetMultiFeedWarnLevel: none\n\nresources:\n repositories:\n - repository: Docker\n type: github\n endpoint: PowerShell\n name: PowerShell/PowerShell-Docker\n ref: master\n\nstages:\n- stage: BuildLinuxStage\n displayName: Build for Linux\n jobs:\n - template: templates/ci-build.yml\n parameters:\n pool: ubuntu-20.04\n jobName: linux_build\n displayName: linux Build\n\n- stage: PackageLinux\n displayName: Package Linux\n dependsOn: ["BuildLinuxStage"]\n jobs:\n - template: linux/templates/packaging.yml\n parameters:\n pool: ubuntu-20.04\n
dataset_sample\yaml\PowerShell_PowerShell\.vsts-ci\linux.yml
linux.yml
YAML
1,832
0.8
0.025
0.026667
react-lib
289
2025-02-13T08:49:42.054807
Apache-2.0
false
e1cdd70175fbb16f5de74239a3f6d630
name: PR-$(System.PullRequest.PullRequestNumber)-$(Date:yyyyMMdd)$(Rev:.rr)\ntrigger:\n # Batch merge builds together while a merge build is running\n batch: true\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n include:\n - '*'\n exclude:\n - tools/releaseBuild/**/*\n - .vsts-ci/misc-analysis.yml\n - .github/ISSUE_TEMPLATE/*\n - .github/workflows/*\n - .dependabot/config.yml\n - .pipelines/*\n - test/perf/*\npr:\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n include:\n - '*'\n exclude:\n - .dependabot/config.yml\n - .github/ISSUE_TEMPLATE/*\n - .github/workflows/*\n - .vsts-ci/misc-analysis.yml\n - .vsts-ci/windows.yml\n - .vsts-ci/windows/*\n - tools/cgmanifest.json\n - LICENSE.txt\n - test/common/markdown/*\n - test/perf/*\n - tools/packaging/*\n - tools/releaseBuild/*\n - tools/releaseBuild/azureDevOps/templates/*\n - README.md\n - .spelling\n - .pipelines/*\n\nvariables:\n DOTNET_CLI_TELEMETRY_OPTOUT: 1\n POWERSHELL_TELEMETRY_OPTOUT: 1\n # Avoid expensive initialization of dotnet cli, see: https://donovanbrown.com/post/Stop-wasting-time-during-NET-Core-builds\n DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1\n # Turn off Homebrew analytics\n HOMEBREW_NO_ANALYTICS: 1\n __SuppressAnsiEscapeSequences: 1\n nugetMultiFeedWarnLevel: none\n\nresources:\n- repo: self\n clean: true\n\nstages:\n- stage: BuildMac\n displayName: Build for macOS\n jobs:\n - template: templates/ci-build.yml\n parameters:\n pool: macOS-latest\n jobName: mac_build\n displayName: macOS Build\n\n- stage: TestMac\n displayName: Test for macOS\n jobs:\n - template: templates/nix-test.yml\n parameters:\n purpose: UnelevatedPesterTests\n tagSet: CI\n\n - template: templates/nix-test.yml\n parameters:\n purpose: ElevatedPesterTests\n tagSet: CI\n\n - template: templates/nix-test.yml\n parameters:\n purpose: UnelevatedPesterTests\n tagSet: Others\n\n - template: templates/nix-test.yml\n parameters:\n purpose: ElevatedPesterTests\n tagSet: Others\n\n - template: templates/verify-xunit.yml\n parameters:\n pool: macOS-latest\n\n- stage: PackageMac\n dependsOn: ['BuildMac']\n displayName: Package macOS (bootstrap only)\n jobs:\n - job: macos_packaging\n pool:\n vmImage: macOS-latest\n\n displayName: macOS packaging (bootstrap only)\n steps:\n - checkout: self\n clean: true\n - pwsh: |\n import-module ./build.psm1\n start-psbootstrap -Scenario package\n displayName: Bootstrap packaging\n condition: succeededOrFailed()\n
dataset_sample\yaml\PowerShell_PowerShell\.vsts-ci\mac.yml
mac.yml
YAML
2,647
0.95
0.026087
0.028571
vue-tools
5
2023-09-21T14:22:57.958433
MIT
false
1423874f6138c7d761bc41c582e7bc1a
# Copyright (c) Microsoft Corporation.\n# Licensed under the MIT License.\n\nname: PR-$(System.PullRequest.PullRequestNumber)-$(Date:yyyyMMdd)$(Rev:.rr)\ntrigger:\n # Batch merge builds together while a merge build is running\n batch: true\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n include:\n - '*'\n exclude:\n - .vsts-ci/misc-analysis.yml\n - .github/ISSUE_TEMPLATE/*\n - .github/workflows/*\n - .dependabot/config.yml\n - test/perf/*\n - .pipelines/*\npr:\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n include:\n - '*'\n exclude:\n - .dependabot/config.yml\n - .github/ISSUE_TEMPLATE/*\n - .github/workflows/*\n - .vsts-ci/misc-analysis.yml\n - tools/cgmanifest.json\n - LICENSE.txt\n - test/common/markdown/*\n - test/perf/*\n - tools/packaging/*\n - tools/releaseBuild/*\n - tools/releaseBuild/azureDevOps/templates/*\n - README.md\n - .spelling\n - .pipelines/*\n\nvariables:\n GIT_CONFIG_PARAMETERS: "'core.autocrlf=false'"\n DOTNET_CLI_TELEMETRY_OPTOUT: 1\n POWERSHELL_TELEMETRY_OPTOUT: 1\n # Avoid expensive initialization of dotnet cli, see: https://donovanbrown.com/post/Stop-wasting-time-during-NET-Core-builds\n DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1\n __SuppressAnsiEscapeSequences: 1\n NugetSecurityAnalysisWarningLevel: none\n nugetMultiFeedWarnLevel: none\n\nresources:\n- repo: self\n clean: true\n\nstages:\n- stage: BuildWin\n displayName: Build for Windows\n jobs:\n - template: templates/ci-build.yml\n\n- stage: TestWin\n displayName: Test PSResourceGetACR\n jobs:\n - job: win_test_ACR\n displayName: PSResourceGet ACR Tests\n pool:\n vmImage: 'windows-latest'\n\n steps:\n - pwsh: |\n Get-ChildItem -Path env:\n displayName: Capture Environment\n condition: succeededOrFailed()\n\n - task: DownloadBuildArtifacts@0\n displayName: 'Download Build Artifacts'\n inputs:\n downloadType: specific\n itemPattern: |\n build/**/*\n downloadPath: '$(System.ArtifactsDirectory)'\n\n - pwsh: |\n Get-ChildItem "$(System.ArtifactsDirectory)\*" -Recurse\n displayName: 'Capture Artifacts Directory'\n continueOnError: true\n\n - pwsh: |\n # Remove "Program Files\dotnet" from the env variable PATH, so old SDKs won't affect us.\n Write-Host "Old Path:"\n Write-Host $env:Path\n\n $dotnetPath = Join-Path $env:SystemDrive 'Program Files\dotnet'\n $paths = $env:Path -split ";" | Where-Object { -not $_.StartsWith($dotnetPath) }\n $env:Path = $paths -join ";"\n\n Write-Host "New Path:"\n Write-Host $env:Path\n\n # Bootstrap\n Import-Module .\tools\ci.psm1\n Invoke-CIInstall\n displayName: Bootstrap\n\n - pwsh: |\n Install-Module -Name 'Microsoft.PowerShell.SecretManagement' -force -SkipPublisherCheck -AllowClobber\n Install-Module -Name 'Microsoft.PowerShell.SecretStore' -force -SkipPublisherCheck -AllowClobber\n $vaultPassword = ConvertTo-SecureString $("a!!"+ (Get-Random -Maximum ([int]::MaxValue))) -AsPlainText -Force\n Set-SecretStoreConfiguration -Authentication None -Interaction None -Confirm:$false -Password $vaultPassword\n Register-SecretVault -Name SecretStore -ModuleName Microsoft.PowerShell.SecretStore -DefaultVault\n displayName: 'Install Secret store'\n\n - task: AzurePowerShell@5\n inputs:\n azureSubscription: PSResourceGetACR\n azurePowerShellVersion: LatestVersion\n ScriptType: InlineScript\n pwsh: true\n inline: |\n Write-Verbose -Verbose "Getting Azure Container Registry"\n Get-AzContainerRegistry -ResourceGroupName 'PSResourceGet' -Name 'psresourcegettest' | Select-Object -Property *\n Write-Verbose -Verbose "Setting up secret for Azure Container Registry"\n $azt = Get-AzAccessToken\n $tenantId = $azt.TenantID\n Set-Secret -Name $tenantId -Secret $azt.Token -Verbose\n $vstsCommandString = "vso[task.setvariable variable=TenantId]$tenantId"\n Write-Host "sending " + $vstsCommandString\n Write-Host "##$vstsCommandString"\n displayName: 'Setup Azure Container Registry secret'\n\n - pwsh: |\n Import-Module .\build.psm1 -force\n Import-Module .\tools\ci.psm1\n Restore-PSOptions -PSOptionsPath '$(System.ArtifactsDirectory)\build\psoptions.json'\n $options = (Get-PSOptions)\n $path = split-path -path $options.Output\n $rootPath = split-Path -path $path\n Expand-Archive -Path '$(System.ArtifactsDirectory)\build\build.zip' -DestinationPath $rootPath -Force\n\n $pwshExe = Get-ChildItem -Path $rootPath -Recurse -Filter pwsh.exe | Select-Object -First 1\n\n $outputFilePath = "$(Build.SourcesDirectory)\test\powershell\Modules\Microsoft.PowerShell.PSResourceGet\ACRTests.xml"\n $cmdline = "`$env:ACRTESTS = 'true'; Invoke-Pester -Path '$(Build.SourcesDirectory)\test\powershell\Modules\Microsoft.PowerShell.PSResourceGet\Microsoft.PowerShell.PSResourceGet.Tests.ps1' -TestName 'PSResourceGet - ACR tests' -OutputFile $outputFilePath -OutputFormat NUnitXml"\n Write-Verbose -Verbose "Running $cmdline"\n\n & $pwshExe -Command $cmdline\n\n Publish-TestResults -Title "PSResourceGet - ACR tests" -Path $outputFilePath -Type NUnit\n displayName: 'PSResourceGet ACR functional tests using AzAuth'\n\n
dataset_sample\yaml\PowerShell_PowerShell\.vsts-ci\psresourceget-acr.yml
psresourceget-acr.yml
YAML
5,421
0.95
0.019108
0.043796
vue-tools
420
2023-11-15T14:21:31.012054
BSD-3-Clause
false
6636eb39f3b8032d3ef4d24f6a910c46
name: PR-$(System.PullRequest.PullRequestNumber)-$(Date:yyyyMMdd)$(Rev:.rr)\ntrigger:\n # Batch merge builds together while a merge build is running\n batch: true\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n include:\n - '*'\n exclude:\n - .vsts-ci/misc-analysis.yml\n - .github/ISSUE_TEMPLATE/*\n - .dependabot/config.yml\n - test/perf/*\npr:\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n include:\n - '*'\n exclude:\n - .dependabot/config.yml\n - .github/ISSUE_TEMPLATE/*\n - .vsts-ci/misc-analysis.yml\n - tools/cgmanifest.json\n - LICENSE.txt\n - test/common/markdown/*\n - test/perf/*\n - tools/packaging/*\n - tools/releaseBuild/*\n - tools/releaseBuild/azureDevOps/templates/*\n - README.md\n - .spelling\n\nvariables:\n - name: GIT_CONFIG_PARAMETERS\n value: "'core.autocrlf=false'"\n - name: DOTNET_CLI_TELEMETRY_OPTOUT\n value: 1\n - name: POWERSHELL_TELEMETRY_OPTOUT\n value: 1\n # Avoid expensive initialization of dotnet cli, see: https://donovanbrown.com/post/Stop-wasting-time-during-NET-Core-builds\n - name: DOTNET_SKIP_FIRST_TIME_EXPERIENCE\n value: 1\n - name: __SuppressAnsiEscapeSequences\n value: 1\n - group: PoolNames\n\nresources:\n- repo: self\n clean: true\n\nstages:\n- stage: BuildWin\n displayName: Build for Windows\n jobs:\n - template: templates/ci-build.yml\n parameters:\n pool: $(armPool)\n PoolType: 1esHosted\n\n- stage: TestWin\n displayName: Test for Windows\n jobs:\n - template: templates/windows-test.yml\n parameters:\n purpose: UnelevatedPesterTests\n tagSet: CI\n pool: $(armPool)\n\n - template: templates/windows-test.yml\n parameters:\n purpose: ElevatedPesterTests\n tagSet: CI\n pool: $(armPool)\n\n - template: templates/windows-test.yml\n parameters:\n purpose: UnelevatedPesterTests\n tagSet: Others\n pool: $(armPool)\n\n - template: templates/windows-test.yml\n parameters:\n purpose: ElevatedPesterTests\n tagSet: Others\n pool: $(armPool)\n\n - template: templates/verify-xunit.yml\n
dataset_sample\yaml\PowerShell_PowerShell\.vsts-ci\windows-arm64.yml
windows-arm64.yml
YAML
2,111
0.8
0.031579
0.022989
awesome-app
942
2024-03-25T19:18:36.096690
Apache-2.0
false
4ead2239f9ccfed2b4a4c8686e8a5b58
name: PR-$(System.PullRequest.PullRequestNumber)-$(Date:yyyyMMdd)$(Rev:.rr)\ntrigger:\n # Batch merge builds together while a merge build is running\n batch: true\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n include:\n - '*'\n exclude:\n - /.vsts-ci/misc-analysis.yml\n - /.github/ISSUE_TEMPLATE/*\n - /.dependabot/config.yml\npr:\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n include:\n - '*'\n exclude:\n - /.vsts-ci/misc-analysis.yml\n - /.github/ISSUE_TEMPLATE/*\n - /.dependabot/config.yml\n\nvariables:\n GIT_CONFIG_PARAMETERS: "'core.autocrlf=false'"\n DOTNET_CLI_TELEMETRY_OPTOUT: 1\n POWERSHELL_TELEMETRY_OPTOUT: 1\n # Avoid expensive initialization of dotnet cli, see: https://donovanbrown.com/post/Stop-wasting-time-during-NET-Core-builds\n DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1\n __SuppressAnsiEscapeSequences: 1\n\nresources:\n- repo: self\n clean: true\n\nstages:\n- stage: BuildWin\n displayName: Build for Windows\n jobs:\n - template: templates/ci-build.yml\n\n- stage: TestWin\n displayName: Test for Windows\n jobs:\n - job: win_test\n pool:\n vmImage: windows-2019\n displayName: Windows Test\n timeoutInMinutes: 90\n\n steps:\n - pwsh: |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: 'Capture Environment'\n condition: succeededOrFailed()\n\n - task: DownloadBuildArtifacts@0\n displayName: 'Download Build Artifacts'\n inputs:\n downloadType: specific\n itemPattern: |\n build/**/*\n xunit/**/*\n downloadPath: '$(System.ArtifactsDirectory)'\n\n - pwsh: |\n Get-ChildItem "$(System.ArtifactsDirectory)\*" -Recurse\n displayName: 'Capture Artifacts Directory'\n continueOnError: true\n\n # must be run frow Windows PowerShell\n - powershell: |\n # Remove "Program Files\dotnet" from the env variable PATH, so old SDKs won't affect us.\n Write-Host "Old Path:"\n Write-Host $env:Path\n\n $dotnetPath = Join-Path $env:SystemDrive 'Program Files\dotnet'\n $paths = $env:Path -split ";" | Where-Object { -not $_.StartsWith($dotnetPath) }\n $env:Path = $paths -join ";"\n\n Write-Host "New Path:"\n Write-Host $env:Path\n\n Import-Module .\tools\ci.psm1\n Invoke-CIInstall\n displayName: Bootstrap\n condition: succeededOrFailed()\n\n - task: UseDotNet@2\n displayName: 'Use .NET Core sdk'\n inputs:\n useGlobalJson: true\n packageType: 'sdk'\n workingDirectory: $(Build.SourcesDirectory)"\n\n - pwsh: |\n Import-Module .\build.psm1\n Restore-PSOptions -PSOptionsPath '$(System.ArtifactsDirectory)\build\psoptions.json'\n $path = Split-Path -Parent (Get-PSOutput -Options (Get-PSOptions))\n $rootPath = Split-Path -Path $path\n Expand-Archive -Path '$(System.ArtifactsDirectory)\build\build.zip' -DestinationPath $rootPath -Force\n displayName: 'Unzip Build'\n condition: succeeded()\n\n - pwsh: |\n Import-Module .\build.psm1\n Import-Module .\tools\ci.psm1\n Restore-PSOptions -PSOptionsPath '$(System.ArtifactsDirectory)\build\psoptions.json'\n Invoke-CITest -Purpose UnelevatedPesterTests -TagSet CI\n displayName: Test - UnelevatedPesterTests - CI\n condition: succeeded()\n\n - pwsh: |\n Import-Module .\build.psm1\n Import-Module .\tools\ci.psm1\n Restore-PSOptions -PSOptionsPath '$(System.ArtifactsDirectory)\build\psoptions.json'\n Invoke-CITest -Purpose ElevatedPesterTests -TagSet CI\n displayName: Test - ElevatedPesterTests - CI\n condition: succeededOrFailed()\n\n - pwsh: |\n Import-Module .\build.psm1\n Import-Module .\tools\ci.psm1\n Restore-PSOptions -PSOptionsPath '$(System.ArtifactsDirectory)\build\psoptions.json'\n Invoke-CITest -Purpose UnelevatedPesterTests -TagSet Others\n displayName: Test - UnelevatedPesterTests - Others\n condition: succeededOrFailed()\n\n - pwsh: |\n Import-Module .\build.psm1\n Import-Module .\tools\ci.psm1\n Restore-PSOptions -PSOptionsPath '$(System.ArtifactsDirectory)\build\psoptions.json'\n Invoke-CITest -Purpose ElevatedPesterTests -TagSet Others\n displayName: Test - ElevatedPesterTests - Others\n condition: succeededOrFailed()\n\n - pwsh: |\n Import-Module .\build.psm1\n $xUnitTestResultsFile = '$(System.ArtifactsDirectory)\xunit\xUnitTestResults.xml'\n Test-XUnitTestResults -TestResultsFile $xUnitTestResultsFile\n displayName: Verify xUnit Test Results\n condition: succeededOrFailed()\n
dataset_sample\yaml\PowerShell_PowerShell\.vsts-ci\windows-daily.yml
windows-daily.yml
YAML
4,682
0.8
0.020134
0.030534
react-lib
850
2023-07-20T07:50:50.798295
GPL-3.0
false
5ff2aba70775d0292023522824930562
name: PR-$(System.PullRequest.PullRequestNumber)-$(Date:yyyyMMdd)$(Rev:.rr)\ntrigger:\n # Batch merge builds together while a merge build is running\n batch: true\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n include:\n - '*'\n exclude:\n - .vsts-ci/misc-analysis.yml\n - .github/ISSUE_TEMPLATE/*\n - .github/workflows/*\n - .dependabot/config.yml\n - test/perf/*\n - .pipelines/*\npr:\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n include:\n - .vsts-ci/templates/*\n - .vsts-ci/windows.yml\n - '*.props'\n - build.psm1\n - src/*\n - test/*\n - tools/buildCommon/*\n - tools/ci.psm1\n - tools/WindowsCI.psm1\n exclude:\n - test/common/markdown/*\n - test/perf/*\n\nvariables:\n GIT_CONFIG_PARAMETERS: "'core.autocrlf=false'"\n DOTNET_CLI_TELEMETRY_OPTOUT: 1\n POWERSHELL_TELEMETRY_OPTOUT: 1\n # Avoid expensive initialization of dotnet cli, see: https://donovanbrown.com/post/Stop-wasting-time-during-NET-Core-builds\n DOTNET_SKIP_FIRST_TIME_EXPERIENCE: 1\n __SuppressAnsiEscapeSequences: 1\n NugetSecurityAnalysisWarningLevel: none\n nugetMultiFeedWarnLevel: none\n\nresources:\n- repo: self\n clean: true\n\nstages:\n- stage: BuildWin\n displayName: Build for Windows\n jobs:\n - template: templates/ci-build.yml\n\n- stage: TestWin\n displayName: Test for Windows\n jobs:\n - template: templates/windows-test.yml\n parameters:\n purpose: UnelevatedPesterTests\n tagSet: CI\n\n - template: templates/windows-test.yml\n parameters:\n purpose: ElevatedPesterTests\n tagSet: CI\n\n - template: templates/windows-test.yml\n parameters:\n purpose: UnelevatedPesterTests\n tagSet: Others\n\n - template: templates/windows-test.yml\n parameters:\n purpose: ElevatedPesterTests\n tagSet: Others\n\n - template: templates/verify-xunit.yml\n
dataset_sample\yaml\PowerShell_PowerShell\.vsts-ci\windows.yml
windows.yml
YAML
1,866
0.8
0.035714
0.026316
python-kit
783
2023-09-27T14:26:58.102623
GPL-3.0
false
0a6cc567bdefbbfb7a5d6ebf508f8704
parameters:\n pool: 'ubuntu-20.04'\n parentJobs: []\n name: 'Linux'\n\njobs:\n- job: ${{ parameters.name }}_packaging\n dependsOn:\n ${{ parameters.parentJobs }}\n pool:\n vmImage: ${{ parameters.pool }}\n\n displayName: ${{ parameters.name }} packaging\n\n steps:\n - task: UseDotNet@2\n displayName: 'Use .NET Core sdk'\n inputs:\n useGlobalJson: true\n packageType: 'sdk'\n\n - pwsh: |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture Environment\n condition: succeededOrFailed()\n\n - task: DownloadBuildArtifacts@0\n displayName: 'Download build artifacts'\n inputs:\n downloadType: specific\n itemPattern: |\n build/**/*\n downloadPath: '$(System.ArtifactsDirectory)'\n\n - pwsh: |\n Get-ChildItem "$(System.ArtifactsDirectory)\*" -Recurse\n displayName: 'Capture Artifacts Directory'\n continueOnError: true\n\n - pwsh: |\n Import-Module .\build.psm1\n Start-PSBootstrap -Scenario Package\n displayName: Bootstrap\n\n - pwsh: |\n Import-Module ./build.psm1\n displayName: 'Capture Artifacts Directory'\n continueOnError: true\n\n - task: ExtractFiles@1\n displayName: 'Extract Build ZIP'\n inputs:\n archiveFilePatterns: '$(System.ArtifactsDirectory)/build/build.zip'\n destinationFolder: '$(System.ArtifactsDirectory)/bins'\n\n - bash: |\n find "$(System.ArtifactsDirectory)/bins" -type d -exec chmod +rwx {} \;\n find "$(System.ArtifactsDirectory)/bins" -type f -exec chmod +rw {} \;\n displayName: 'Fix permissions'\n continueOnError: true\n\n - pwsh: |\n Get-ChildItem "$(System.ArtifactsDirectory)\bins\*" -Recurse -ErrorAction SilentlyContinue\n displayName: 'Capture Extracted Build ZIP'\n continueOnError: true\n\n - pwsh: |\n Import-Module .\tools\ci.psm1\n Restore-PSOptions -PSOptionsPath '$(System.ArtifactsDirectory)\build\psoptions.json'\n $options = (Get-PSOptions)\n $rootPath = '$(System.ArtifactsDirectory)\bins'\n $originalRootPath = Split-Path -path $options.Output\n $path = Join-Path -path $rootPath -ChildPath (split-path -leaf -path $originalRootPath)\n $pwshPath = Join-Path -path $path -ChildPath 'pwsh'\n chmod a+x $pwshPath\n $options.Output = $pwshPath\n Set-PSOptions $options\n Invoke-CIFinish\n displayName: Packaging Tests\n condition: succeeded()\n\n - pwsh: |\n Get-ChildItem "${env:BUILD_ARTIFACTSTAGINGDIRECTORY}\*.deb" -Recurse | ForEach-Object {\n $packagePath = $_.FullName\n Write-Host "Uploading $packagePath"\n Write-Host "##vso[artifact.upload containerfolder=deb;artifactname=deb]$packagePath"\n }\n Get-ChildItem "${env:BUILD_ARTIFACTSTAGINGDIRECTORY}\*.rpm" -Recurse | ForEach-Object {\n $packagePath = $_.FullName\n Write-Host "Uploading $packagePath"\n Write-Host "##vso[artifact.upload containerfolder=rpm;artifactname=rpm]$packagePath"\n }\n Get-ChildItem "${env:BUILD_ARTIFACTSTAGINGDIRECTORY}\*.tar.gz" -Recurse | ForEach-Object {\n $packagePath = $_.FullName\n Write-Host "Uploading $packagePath"\n Write-Host "##vso[artifact.upload containerfolder=rpm;artifactname=rpm]$packagePath"\n }\n displayName: Upload packages\n retryCountOnTaskFailure: 2\n
dataset_sample\yaml\PowerShell_PowerShell\.vsts-ci\linux\templates\packaging.yml
packaging.yml
YAML
3,287
0.8
0
0
node-utils
391
2023-07-15T06:07:56.935627
MIT
false
b357c708218ab9002d9813d22df90826
parameters:\n - name: jobName\n - name: taskName\n\njobs:\n- job: ${{ parameters.jobName }}\n displayName: Generate Markdown Matrix\n\n pool:\n vmImage: ubuntu-20.04\n\n variables:\n - name: repoPath\n value: $(Agent.BuildDirectory)/$(repoFolder)\n\n steps:\n - checkout: self\n clean: true\n path: $(repoFolder)\n\n - powershell: |\n $matrix = @{}\n $matrix += @{\n 'root' = @{\n markdown_folder = "$(repoPath)"\n markdown_recurse = $false\n }\n }\n Get-ChildItem -path '$(repoPath)' -Directory | Foreach-Object {\n $folder = $_\n $matrix += @{\n $_.Name = @{\n markdown_folder = $_.fullName\n markdown_recurse = $true\n }\n }\n }\n\n $matrixJson = $matrix | ConvertTo-Json -Compress\n $variableName = "matrix"\n $command = "vso[task.setvariable variable=$variableName;isoutput=true]$($matrixJson)"\n Write-Verbose "sending command: '$command'"\n Write-Host "##$command"\n displayName: Create Matrix\n condition: succeededOrFailed()\n name: ${{ parameters.taskName }}\n
dataset_sample\yaml\PowerShell_PowerShell\.vsts-ci\misc-analysis\generateMarkdownMatrix.yml
generateMarkdownMatrix.yml
YAML
1,101
0.8
0
0
awesome-app
165
2024-02-01T20:50:13.580660
GPL-3.0
false
e491b4529b2c0d013289e80954a20ddd
parameters:\n - name: pool\n default: 'windows-latest'\n - name: imageName\n default: 'PSWindows11-ARM64'\n - name: jobName\n default: 'win_build'\n - name: displayName\n default: Windows Build\n - name: PoolType\n default: AzDoHosted\n type: string\n values:\n - AzDoHosted\n - 1esHosted\n\njobs:\n- job: ${{ parameters.jobName }}\n pool:\n ${{ if eq( parameters.PoolType, 'AzDoHosted') }}:\n vmImage: ${{ parameters.pool }}\n ${{ else }}:\n name: ${{ parameters.pool }}\n demands:\n - ImageOverride -equals ${{ parameters.imageName }}\n\n displayName: ${{ parameters.displayName }}\n\n steps:\n - powershell: |\n [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.SecurityProtocolType]::Tls12\n $pwsh = Get-Command pwsh -ErrorAction SilentlyContinue -CommandType Application\n\n if ($null -eq $pwsh) {\n $powerShellPath = Join-Path -Path $env:AGENT_TEMPDIRECTORY -ChildPath 'powershell'\n Invoke-WebRequest -Uri https://raw.githubusercontent.com/PowerShell/PowerShell/master/tools/install-powershell.ps1 -outfile ./install-powershell.ps1\n ./install-powershell.ps1 -Destination $powerShellPath\n $vstsCommandString = "vso[task.setvariable variable=PATH]$powerShellPath;$env:PATH"\n Write-Host "sending " + $vstsCommandString\n Write-Host "##$vstsCommandString"\n }\n\n displayName: Install PowerShell\n\n - checkout: self\n fetchDepth: 1000\n\n - pwsh: |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture Environment\n condition: succeededOrFailed()\n\n - pwsh: Write-Host "##vso[build.updatebuildnumber]$env:BUILD_SOURCEBRANCHNAME-$env:BUILD_SOURCEVERSION-$((get-date).ToString("yyyyMMddhhmmss"))"\n displayName: Set Build Name for Non-PR\n condition: ne(variables['Build.Reason'], 'PullRequest')\n\n - ${{ if ne(variables['UseAzDevOpsFeed'], '') }}:\n - template: /tools/releaseBuild/azureDevOps/templates/insert-nuget-config-azfeed.yml\n\n - task: UseDotNet@2\n displayName: 'Use .NET Core sdk'\n inputs:\n useGlobalJson: true\n packageType: 'sdk'\n\n - pwsh: |\n Import-Module .\tools\ci.psm1\n Invoke-CIInstall -SkipUser\n Write-Verbose -Verbose "Start Sync-PSTags"\n Sync-PSTags -AddRemoteIfMissing\n Write-Verbose -Verbose "End Sync-PSTags"\n displayName: Bootstrap\n condition: succeeded()\n\n - pwsh: |\n Import-Module .\tools\ci.psm1\n Invoke-CIBuild\n displayName: Build\n condition: succeeded()\n\n - pwsh: |\n Import-Module .\tools\ci.psm1\n Restore-PSOptions\n Invoke-CIxUnit -SkipFailing\n displayName: xUnit Tests\n condition: succeeded()\n continueOnError: true\n
dataset_sample\yaml\PowerShell_PowerShell\.vsts-ci\templates\ci-build.yml
ci-build.yml
YAML
2,717
0.8
0.045977
0
awesome-app
895
2025-05-19T19:40:05.725008
GPL-3.0
false
a1256e56b8708c2bde6ab00af62632b6
parameters:\n pool: 'windows-latest'\n jobName: 'credscan'\n displayName: Secret Scan\n\njobs:\n- job: ${{ parameters.jobName }}\n pool:\n vmImage: ${{ parameters.pool }}\n\n displayName: ${{ parameters.displayName }}\n\n steps:\n - task: securedevelopmentteam.vss-secure-development-tools.build-task-credscan.CredScan@2\n displayName: 'Scan for Secrets'\n inputs:\n suppressionsFile: tools/credScan/suppress.json\n toolMajorVersion: V2\n debugMode: false\n\n - task: securedevelopmentteam.vss-secure-development-tools.build-task-publishsecurityanalysislogs.PublishSecurityAnalysisLogs@2\n displayName: 'Publish Secret Scan Logs to Build Artifacts'\n continueOnError: true\n\n - task: securedevelopmentteam.vss-secure-development-tools.build-task-postanalysis.PostAnalysis@1\n displayName: 'Check for Failures'\n inputs:\n CredScan: true\n ToolLogsNotFoundAction: Error\n
dataset_sample\yaml\PowerShell_PowerShell\.vsts-ci\templates\credscan.yml
credscan.yml
YAML
897
0.7
0.068966
0
python-kit
469
2024-01-14T02:07:57.183476
GPL-3.0
false
98b5149e3cd308ff37276fcd8570830f
parameters:\n pool: 'ubuntu-latest'\n jobName: 'none'\n scriptName: ''\n container: ''\n verification: ''\n continueOnError: false\n\njobs:\n\n- job: ${{ parameters.jobName }}\n variables:\n scriptName: ${{ parameters.scriptName }}\n\n ${{ if ne(parameters.container, '') }}:\n container: ${{ parameters.container }}\n\n pool:\n vmImage: ${{ parameters.pool }}\n\n displayName: ${{ parameters.jobName }}\n\n steps:\n - pwsh: |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture Environment\n condition: succeededOrFailed()\n\n - powershell: Write-Host "##vso[build.updatebuildnumber]$env:BUILD_SOURCEBRANCHNAME-$env:BUILD_SOURCEVERSION-$((get-date).ToString("yyyyMMddhhmmss"))"\n displayName: Set Build Name for Non-PR\n condition: ne(variables['Build.Reason'], 'PullRequest')\n\n - bash: |\n $(scriptName)\n displayName: Run Script - $(scriptName)\n condition: succeededOrFailed()\n continueOnError: ${{ parameters.continueOnError }}\n\n - ${{ if ne(parameters.verification, '') }}:\n - pwsh: ${{ parameters.verification }}\n displayName: Verification\n continueOnError: ${{ parameters.continueOnError }}\n
dataset_sample\yaml\PowerShell_PowerShell\.vsts-ci\templates\install-ps-phase.yml
install-ps-phase.yml
YAML
1,191
0.8
0.071429
0
python-kit
602
2023-07-25T04:22:19.316269
BSD-3-Clause
false
c72cb42248def70d275e842bff88123e
parameters:\n vmImage: 'windows-latest'\n jobName: 'Nanoserver_Tests'\n continueOnError: false\n\njobs:\n\n- job: ${{ parameters.jobName }}\n variables:\n scriptName: ${{ parameters.scriptName }}\n\n pool:\n vmImage: ${{ parameters.vmImage }}\n\n displayName: ${{ parameters.jobName }}\n\n steps:\n - script: |\n set\n displayName: Capture Environment\n condition: succeededOrFailed()\n\n - task: DownloadBuildArtifacts@0\n displayName: 'Download Build Artifacts'\n inputs:\n downloadType: specific\n itemPattern: |\n build/**/*\n downloadPath: '$(System.ArtifactsDirectory)'\n\n - pwsh: |\n Get-ChildItem "$(System.ArtifactsDirectory)\*" -Recurse\n displayName: 'Capture Artifacts Directory'\n continueOnError: true\n\n - pwsh: |\n Install-module Pester -Scope CurrentUser -Force -MaximumVersion 4.99\n displayName: 'Install Pester'\n continueOnError: true\n\n - pwsh: |\n Import-Module .\tools\ci.psm1\n Restore-PSOptions -PSOptionsPath '$(System.ArtifactsDirectory)\build\psoptions.json'\n $options = (Get-PSOptions)\n $path = split-path -path $options.Output\n Write-Verbose "Path: '$path'" -Verbose\n $rootPath = split-Path -path $path\n Expand-Archive -Path '$(System.ArtifactsDirectory)\build\build.zip' -DestinationPath $rootPath -Force\n Invoke-Pester -Path ./test/nanoserver -OutputFormat NUnitXml -OutputFile ./test-nanoserver.xml\n displayName: Test\n condition: succeeded()\n\n - task: PublishTestResults@2\n condition: succeededOrFailed()\n displayName: Publish Nanoserver Test Results **\test*.xml\n inputs:\n testRunner: NUnit\n testResultsFiles: '**\test*.xml'\n testRunTitle: nanoserver\n mergeTestResults: true\n failTaskOnFailedTests: true\n
dataset_sample\yaml\PowerShell_PowerShell\.vsts-ci\templates\nanoserver.yml
nanoserver.yml
YAML
1,760
0.8
0
0
react-lib
112
2023-10-15T19:50:00.848226
MIT
false
af5e5ebdde8c0fdf62bbe68e61b946b3
parameters:\n parentJobs: []\n pool: 'windows-latest'\n jobName: 'xunit_verify'\n\njobs:\n- job: verify_xunit\n displayName: Verify xUnit Results\n pool:\n vmImage: ${{ parameters.pool }}\n dependsOn:\n ${{ parameters.parentJobs }}\n steps:\n - task: DownloadBuildArtifacts@0\n displayName: 'Download build artifacts'\n inputs:\n downloadType: specific\n itemPattern: |\n xunit/**/*\n downloadPath: '$(System.ArtifactsDirectory)'\n\n - pwsh: |\n dir "$(System.ArtifactsDirectory)\*" -Recurse\n displayName: 'Capture artifacts directory'\n continueOnError: true\n\n - pwsh: |\n Import-Module .\tools\ci.psm1\n $xUnitTestResultsFile = "$(System.ArtifactsDirectory)\xunit\xUnitTestResults.xml"\n\n Test-XUnitTestResults -TestResultsFile $xUnitTestResultsFile\n displayName: Test\n condition: succeeded()\n
dataset_sample\yaml\PowerShell_PowerShell\.vsts-ci\templates\verify-xunit.yml
verify-xunit.yml
YAML
845
0.8
0
0
node-utils
122
2024-06-06T11:25:46.125860
BSD-3-Clause
false
80a68896a96b16a69b5ba8e72c4a14cf
name: PR-$(System.PullRequest.PullRequestNumber)-$(Date:yyyyMMdd)$(Rev:.rr)\ntrigger:\n # Batch merge builds together while a merge build is running\n batch: true\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n exclude:\n - tests/*\n - docs/*\n - demos/*\n - CHANGELOG/*\n - .devcontainer/*\n - .github/*\n - .poshchan/*\n - .vscode/*\n - code-server/*\n - docker/*\n\npr:\n branches:\n include:\n - master\n - release*\n - feature*\n paths:\n include:\n - .vsts-ci/windows/*.yml\n - assets/wix/*\n - build.psm1\n - global.json\n - nuget.config\n - PowerShell.Common.props\n - src/*.csproj\n - test/packaging/windows/*\n - tools/ci.psm1\n - tools/packaging/*\n - tools/wix/*\n\nvariables:\n - name: GIT_CONFIG_PARAMETERS\n value: "'core.autocrlf=false'"\n - name: DOTNET_CLI_TELEMETRY_OPTOUT\n value: 1\n - name: POWERSHELL_TELEMETRY_OPTOUT\n value: 1\n # Avoid expensive initialization of dotnet cli, see: https://donovanbrown.com/post/Stop-wasting-time-during-NET-Core-builds\n - name: DOTNET_SKIP_FIRST_TIME_EXPERIENCE\n value: 1\n - name: __SuppressAnsiEscapeSequences\n value: 1\n - group: fakeNugetKey\n - name: SBOMGenerator_Formats\n value: spdx:2.2\n - name: nugetMultiFeedWarnLevel\n value: none\n\nresources:\n repositories:\n - repository: ComplianceRepo\n type: github\n endpoint: PowerShell\n name: PowerShell/compliance\n ref: master\n\nstages:\n- stage: PackagingWin\n displayName: Packaging for Windows\n dependsOn: [] # by specifying an empty array, this stage doesn't depend on the stage before it\n jobs:\n # Unlike daily builds, we do not upload nuget package to MyGet so we do not wait on tests to finish.\n - template: templates/windows-packaging.yml\n - template: templates/windows-packaging.yml\n parameters:\n channel: stable\n architecture: x86\n - template: templates/windows-packaging.yml\n parameters:\n channel: preview\n architecture: x86\n - template: templates/windows-packaging.yml\n parameters:\n channel: preview\n architecture: arm64\n runtimePrefix: win\n
dataset_sample\yaml\PowerShell_PowerShell\.vsts-ci\windows\windows-packaging.yml
windows-packaging.yml
YAML
2,154
0.8
0.022727
0.035714
node-utils
930
2024-06-05T10:59:13.729790
BSD-3-Clause
false
471178d032b997c364dfe27c2c1dbf09
parameters:\n - name: pool\n default: 'windows-latest'\n - name: jobName\n default: 'win_packaging'\n - name: runtimePrefix\n default: 'win7'\n - name: architecture\n default: 'x64'\n - name: channel\n default: 'preview'\n\njobs:\n- job: ${{ parameters.jobName }}_${{ parameters.channel }}_${{ parameters.architecture }}\n\n variables:\n - name: repoFolder\n value: PowerShell\n - name: repoPath\n value: $(Agent.BuildDirectory)\$(repoFolder)\n - name: complianceRepoFolder\n value: compliance\n - name: complianceRepoPath\n value: $(Agent.BuildDirectory)\$(complianceRepoFolder)\n\n pool:\n vmImage: ${{ parameters.pool }}\n\n displayName: Windows Packaging - ${{ parameters.architecture }} - ${{ parameters.channel }}\n\n steps:\n - checkout: self\n clean: true\n path: $(repoFolder)\n\n - checkout: ComplianceRepo\n clean: true\n path: $(complianceRepoFolder)\n\n - powershell: |\n Get-ChildItem -Path env: | Out-String -width 9999 -Stream | write-Verbose -Verbose\n displayName: Capture environment\n condition: succeededOrFailed()\n\n - pwsh: |\n $PSVersionTable\n displayName: Capture PowerShell Version Table\n condition: succeededOrFailed()\n\n - pwsh: |\n Import-Module .\tools\ci.psm1\n Switch-PSNugetConfig -Source Public\n displayName: Switch to public feeds\n condition: succeeded()\n workingDirectory: $(repoPath)\n\n - task: UseDotNet@2\n displayName: 'Use .NET Core sdk'\n inputs:\n useGlobalJson: true\n packageType: 'sdk'\n workingDirectory: $(repoPath)\n\n - pwsh: |\n Import-Module .\tools\ci.psm1\n Invoke-CIInstall -SkipUser\n displayName: Bootstrap\n condition: succeeded()\n workingDirectory: $(repoPath)\n\n - pwsh: |\n Import-Module .\tools\ci.psm1\n New-CodeCoverageAndTestPackage\n Invoke-CIFinish -Runtime ${{ parameters.runtimePrefix }}-${{ parameters.architecture }} -channel ${{ parameters.channel }} -Stage Build\n displayName: Build\n workingDirectory: $(repoPath)\n\n - template: Sbom.yml@ComplianceRepo\n parameters:\n BuildDropPath: '$(System.ArtifactsDirectory)/mainBuild'\n Build_Repository_Uri: $(build.repository.uri)\n displayName: SBOM\n sourceScanPath: '$(repoPath)\tools'\n signSBOM: false\n\n # This is needed as SBOM task removed the installed .NET and installs .NET 3.1\n - pwsh: |\n Import-Module .\tools\ci.psm1\n Invoke-CIInstall -SkipUser\n displayName: Bootstrap\n condition: succeeded()\n workingDirectory: $(repoPath)\n\n - pwsh: |\n $manifestFolder = Join-Path -Path '$(System.ArtifactsDirectory)/mainBuild' -ChildPath '_manifest'\n\n if (-not (Test-Path $manifestFolder)) {\n throw "_manifest folder does not exist under $(System.ArtifactsDirectory)/mainBuild"\n }\n\n $null = New-Item -Path "$manifestFolder/spdx_2.2/bsi.json" -Verbose -Force\n $null = New-Item -Path "$manifestFolder/spdx_2.2/manifest.cat" -Verbose -Force\n\n displayName: Create fake SBOM manifest signed files\n\n - pwsh: |\n Import-Module .\tools\ci.psm1\n New-CodeCoverageAndTestPackage\n Invoke-CIFinish -Runtime ${{ parameters.runtimePrefix }}-${{ parameters.architecture }} -channel ${{ parameters.channel }} -Stage Package\n displayName: Package and Test\n workingDirectory: $(repoPath)\n
dataset_sample\yaml\PowerShell_PowerShell\.vsts-ci\windows\templates\windows-packaging.yml
windows-packaging.yml
YAML
3,300
0.8
0.009009
0.01087
python-kit
455
2024-04-16T23:34:37.814041
BSD-3-Clause
false
a2bdbdb1703b58dfd67063f576f9f903
clone_depth: 1\nversion: '{branch}-{build}'\nimage: Visual Studio 2022\ncache:\n - '%LOCALAPPDATA%\NuGet\v3-cache -> appveyor.yml'\n\ndotnet_csproj:\n patch: true\n file: 'osu.Game\osu.Game.csproj' # Use wildcard when it's able to exclude Xamarin projects\n version: '0.0.{build}'\n\nbefore_build:\n - cmd: dotnet --info # Useful when version mismatch between CI and local\n - cmd: dotnet workload install maui-android # Change to `dotnet workload restore` once there's no old projects\n - cmd: dotnet workload install maui-ios # Change to `dotnet workload restore` once there's no old projects\n - cmd: nuget restore -verbosity quiet # Only nuget.exe knows both new (.NET Core) and old (Xamarin) projects\n\nbuild:\n project: osu.sln\n parallel: true\n verbosity: minimal\n publish_nuget: true\n\nafter_build:\n - ps: .\InspectCode.ps1\n\ntest:\n assemblies:\n except:\n - '**\*Android*'\n - '**\*iOS*'\n - 'build\**\*'\n
dataset_sample\yaml\ppy_osu\appveyor.yml
appveyor.yml
YAML
922
0.8
0
0
python-kit
644
2025-01-08T04:45:59.135727
BSD-3-Clause
false
1398916d843c8fb3efccc0f950ceaaf8
clone_depth: 1\nversion: '{build}'\nimage: Visual Studio 2022\ntest: off\nskip_non_tags: true\nconfiguration: Release\n\nenvironment:\n matrix:\n - job_name: osu-game\n - job_name: osu-ruleset\n job_depends_on: osu-game\n - job_name: taiko-ruleset\n job_depends_on: osu-game\n - job_name: catch-ruleset\n job_depends_on: osu-game\n - job_name: mania-ruleset\n job_depends_on: osu-game\n - job_name: templates\n job_depends_on: osu-game\n\nnuget:\n project_feed: true\n\nfor:\n -\n matrix:\n only:\n - job_name: osu-game\n build_script:\n - cmd: dotnet pack osu.Game\osu.Game.csproj /p:Version=%APPVEYOR_REPO_TAG_NAME%\n -\n matrix:\n only:\n - job_name: osu-ruleset\n build_script:\n - cmd: dotnet remove osu.Game.Rulesets.Osu\osu.Game.Rulesets.Osu.csproj reference osu.Game\osu.Game.csproj\n - cmd: dotnet add osu.Game.Rulesets.Osu\osu.Game.Rulesets.Osu.csproj package ppy.osu.Game -v %APPVEYOR_REPO_TAG_NAME%\n - cmd: dotnet pack osu.Game.Rulesets.Osu\osu.Game.Rulesets.Osu.csproj /p:Version=%APPVEYOR_REPO_TAG_NAME%\n -\n matrix:\n only:\n - job_name: taiko-ruleset\n build_script:\n - cmd: dotnet remove osu.Game.Rulesets.Taiko\osu.Game.Rulesets.Taiko.csproj reference osu.Game\osu.Game.csproj\n - cmd: dotnet add osu.Game.Rulesets.Taiko\osu.Game.Rulesets.Taiko.csproj package ppy.osu.Game -v %APPVEYOR_REPO_TAG_NAME%\n - cmd: dotnet pack osu.Game.Rulesets.Taiko\osu.Game.Rulesets.Taiko.csproj /p:Version=%APPVEYOR_REPO_TAG_NAME%\n -\n matrix:\n only:\n - job_name: catch-ruleset\n build_script:\n - cmd: dotnet remove osu.Game.Rulesets.Catch\osu.Game.Rulesets.Catch.csproj reference osu.Game\osu.Game.csproj\n - cmd: dotnet add osu.Game.Rulesets.Catch\osu.Game.Rulesets.Catch.csproj package ppy.osu.Game -v %APPVEYOR_REPO_TAG_NAME%\n - cmd: dotnet pack osu.Game.Rulesets.Catch\osu.Game.Rulesets.Catch.csproj /p:Version=%APPVEYOR_REPO_TAG_NAME%\n -\n matrix:\n only:\n - job_name: mania-ruleset\n build_script:\n - cmd: dotnet remove osu.Game.Rulesets.Mania\osu.Game.Rulesets.Mania.csproj reference osu.Game\osu.Game.csproj\n - cmd: dotnet add osu.Game.Rulesets.Mania\osu.Game.Rulesets.Mania.csproj package ppy.osu.Game -v %APPVEYOR_REPO_TAG_NAME%\n - cmd: dotnet pack osu.Game.Rulesets.Mania\osu.Game.Rulesets.Mania.csproj /p:Version=%APPVEYOR_REPO_TAG_NAME%\n -\n matrix:\n only:\n - job_name: templates\n build_script:\n - cmd: dotnet remove Templates\Rulesets\ruleset-empty\osu.Game.Rulesets.EmptyFreeform\osu.Game.Rulesets.EmptyFreeform.csproj reference osu.Game\osu.Game.csproj\n - cmd: dotnet remove Templates\Rulesets\ruleset-example\osu.Game.Rulesets.Pippidon\osu.Game.Rulesets.Pippidon.csproj reference osu.Game\osu.Game.csproj\n - cmd: dotnet remove Templates\Rulesets\ruleset-scrolling-empty\osu.Game.Rulesets.EmptyScrolling\osu.Game.Rulesets.EmptyScrolling.csproj reference osu.Game\osu.Game.csproj\n - cmd: dotnet remove Templates\Rulesets\ruleset-scrolling-example\osu.Game.Rulesets.Pippidon\osu.Game.Rulesets.Pippidon.csproj reference osu.Game\osu.Game.csproj\n\n - cmd: dotnet add Templates\Rulesets\ruleset-empty\osu.Game.Rulesets.EmptyFreeform\osu.Game.Rulesets.EmptyFreeform.csproj package ppy.osu.Game -v %APPVEYOR_REPO_TAG_NAME%\n - cmd: dotnet add Templates\Rulesets\ruleset-example\osu.Game.Rulesets.Pippidon\osu.Game.Rulesets.Pippidon.csproj package ppy.osu.Game -v %APPVEYOR_REPO_TAG_NAME%\n - cmd: dotnet add Templates\Rulesets\ruleset-scrolling-empty\osu.Game.Rulesets.EmptyScrolling\osu.Game.Rulesets.EmptyScrolling.csproj package ppy.osu.Game -v %APPVEYOR_REPO_TAG_NAME%\n - cmd: dotnet add Templates\Rulesets\ruleset-scrolling-example\osu.Game.Rulesets.Pippidon\osu.Game.Rulesets.Pippidon.csproj package ppy.osu.Game -v %APPVEYOR_REPO_TAG_NAME%\n\n - cmd: dotnet pack Templates\osu.Game.Templates.csproj /p:Version=%APPVEYOR_REPO_TAG_NAME%\n\nartifacts:\n - path: '**\*.nupkg'\n\ndeploy:\n - provider: Environment\n name: nuget\n
dataset_sample\yaml\ppy_osu\appveyor_deploy.yml
appveyor_deploy.yml
YAML
4,052
0.7
0.034884
0
react-lib
642
2024-04-08T21:12:53.832299
Apache-2.0
false
f2fc944541e88866f961ed0c8cc7c3ab
version: 2\nupdates:\n- package-ecosystem: nuget\n directory: "/"\n schedule:\n interval: monthly\n time: "17:00"\n open-pull-requests-limit: 0 # disabled until https://github.com/dependabot/dependabot-core/issues/369 is resolved.\n ignore:\n - dependency-name: Microsoft.EntityFrameworkCore.Design\n versions:\n - "> 2.2.6"\n - dependency-name: Microsoft.EntityFrameworkCore.Sqlite\n versions:\n - "> 2.2.6"\n - dependency-name: Microsoft.EntityFrameworkCore.Sqlite.Core\n versions:\n - "> 2.2.6"\n - dependency-name: Microsoft.Extensions.DependencyInjection\n versions:\n - ">= 5.a, < 6"\n - dependency-name: NUnit3TestAdapter\n versions:\n - ">= 3.16.a, < 3.17"\n - dependency-name: Microsoft.NET.Test.Sdk\n versions:\n - 16.9.1\n - dependency-name: Microsoft.Extensions.DependencyInjection\n versions:\n - 3.1.11\n - 3.1.12\n - dependency-name: Microsoft.AspNetCore.SignalR.Protocols.NewtonsoftJson\n versions:\n - 3.1.11\n - dependency-name: Microsoft.NETCore.Targets\n versions:\n - 5.0.0\n - dependency-name: Microsoft.AspNetCore.SignalR.Protocols.MessagePack\n versions:\n - 5.0.2\n - dependency-name: NUnit\n versions:\n - 3.13.1\n - dependency-name: Microsoft.AspNetCore.SignalR.Client\n versions:\n - 3.1.11\n
dataset_sample\yaml\ppy_osu\.github\dependabot.yml
dependabot.yml
YAML
1,271
0.8
0
0
vue-tools
253
2023-11-26T06:03:30.860189
GPL-3.0
false
c97044b9dc156de63f7a864de545359b
name: Bug report\ndescription: Report a very clearly broken issue.\nbody:\n - type: markdown\n attributes:\n value: |\n # osu! bug report\n\n Important to note that your issue may have already been reported before. Please check:\n - Pinned issues, at the top of https://github.com/ppy/osu/issues.\n - Current open `priority:0` issues, filterable [here](https://github.com/ppy/osu/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc+label%3Apriority%3A0).\n - And most importantly, search for your issue both in the [issue listing](https://github.com/ppy/osu/issues) and the [Q&A discussion listing](https://github.com/ppy/osu/discussions/categories/q-a). If you find that it already exists, respond with a reaction or add any further information that may be helpful.\n\n # ATTENTION LINUX USERS\n\n If you are having an issue and it is hardware related, **please open a [q&a discussion](https://github.com/ppy/osu/discussions/categories/q-a)** instead of an issue. There's a high chance your issue is due to your system configuration, and not our software.\n\n - type: dropdown\n attributes:\n label: Type\n options:\n - Crash to desktop\n - Game behaviour\n - Performance\n - Cosmetic\n - Other\n validations:\n required: true\n - type: textarea\n attributes:\n label: Bug description\n description: How did you find the bug? Any additional details that might help?\n validations:\n required: true\n - type: textarea\n attributes:\n label: Screenshots or videos\n description: Add screenshots or videos that show the bug here.\n placeholder: Drag and drop the screenshots/videos into this box.\n validations:\n required: false\n - type: input\n attributes:\n label: Version\n description: The version you encountered this bug on. This is shown at the end of the settings overlay.\n validations:\n required: true\n - type: markdown\n attributes:\n value: |\n ## Logs\n\n Attaching log files is required for **every** issue, regardless of whether you deem them required or not. See instructions below on how to find them.\n\n ### Desktop platforms\n\n If the game has not yet been closed since you found the bug:\n 1. Head on to game settings and click on "Export logs"\n 2. Click the notification to locate the file\n 3. Drag the generated `.zip` files into the github issue window\n\n ![export logs button](https://github.com/ppy/osu/assets/191335/cbfa5550-b7ed-4c5c-8dd0-8b87cc90ad9b)\n\n ### Mobile platforms\n\n The places to find the logs on mobile platforms are as follows:\n - *On Android*, navigate to `Android/data/sh.ppy.osulazer/files/logs` using a file browser app.\n - *On iOS*, connect your device to a PC and copy the `logs` directory from the app's document storage using iTunes. (https://support.apple.com/en-us/HT201301#copy-to-computer)\n\n - type: textarea\n attributes:\n label: Logs\n placeholder: Drag and drop the log files into this box.\n validations:\n required: true\n
dataset_sample\yaml\ppy_osu\.github\ISSUE_TEMPLATE\bug-issue.yml
bug-issue.yml
YAML
3,130
0.95
0.026667
0.078125
react-lib
388
2024-01-05T20:43:13.034661
BSD-3-Clause
false
670e5f54712ad36386d07bbd97fb2659
blank_issues_enabled: false\ncontact_links:\n - name: Help\n url: https://github.com/ppy/osu/discussions/categories/q-a\n about: osu! not working or performing as you'd expect? Not sure it's a bug? Check the Q&A section!\n - name: Suggestions or feature request\n url: https://github.com/ppy/osu/discussions/categories/ideas\n about: Got something you think should change or be added? Search for or start a new discussion!\n - name: osu!stable issues\n url: https://github.com/ppy/osu-stable-issues\n about: For osu!(stable) - ie. the current "live" game version, check out the dedicated repository. Note that this is for serious bug reports only, not tech support.\n\n
dataset_sample\yaml\ppy_osu\.github\ISSUE_TEMPLATE\config.yml
config.yml
YAML
696
0.8
0.166667
0
react-lib
901
2023-08-22T04:25:23.906388
MIT
false
579a290d01a1a776a36c64a864cc1c5e
on: [push, pull_request]\nname: Continuous Integration\nconcurrency:\n group: ${{ github.workflow }}-${{ github.ref }}\n cancel-in-progress: true\n\npermissions:\n contents: read # to fetch code (actions/checkout)\n\njobs:\n inspect-code:\n name: Code Quality\n runs-on: ubuntu-latest\n steps:\n - name: Checkout\n uses: actions/checkout@v4\n\n - name: Install .NET 8.0.x\n uses: actions/setup-dotnet@v4\n with:\n dotnet-version: "8.0.x"\n\n - name: Restore Tools\n run: dotnet tool restore\n\n - name: Restore Packages\n run: dotnet restore osu.Desktop.slnf\n\n - name: Restore inspectcode cache\n uses: actions/cache@v4\n with:\n path: ${{ github.workspace }}/inspectcode\n key: inspectcode-${{ hashFiles('.config/dotnet-tools.json', '.github/workflows/ci.yml', 'osu.sln*', 'osu*.slnf', '.editorconfig', '.globalconfig', 'CodeAnalysis/*', '**/*.csproj', '**/*.props') }}\n\n - name: Dotnet code style\n run: dotnet build -c Debug -warnaserror osu.Desktop.slnf -p:EnforceCodeStyleInBuild=true\n\n - name: CodeFileSanity\n run: |\n # TODO: Add ignore filters and GitHub Workflow Command Reporting in CFS. That way we don't have to do this workaround.\n # FIXME: Suppress warnings from templates project\n exit_code=0\n while read -r line; do\n if [[ ! -z "$line" ]]; then\n echo "::error::$line"\n exit_code=1\n fi\n done <<< $(dotnet codefilesanity)\n exit $exit_code\n\n - name: InspectCode\n run: dotnet jb inspectcode $(pwd)/osu.Desktop.slnf --no-build --output="inspectcodereport.xml" --caches-home="inspectcode" --verbosity=WARN\n\n - name: NVika\n run: dotnet nvika parsereport "${{github.workspace}}/inspectcodereport.xml" --treatwarningsaserrors\n\n test:\n name: Test\n runs-on: ${{matrix.os.fullname}}\n env:\n OSU_EXECUTION_MODE: ${{matrix.threadingMode}}\n strategy:\n fail-fast: false\n matrix:\n os:\n - { prettyname: Windows, fullname: windows-latest }\n # macOS runner performance has gotten unbearably slow so let's turn them off temporarily.\n # - { prettyname: macOS, fullname: macos-latest }\n - { prettyname: Linux, fullname: ubuntu-latest }\n threadingMode: ['SingleThread', 'MultiThreaded']\n timeout-minutes: 120\n steps:\n - name: Checkout\n uses: actions/checkout@v4\n\n - name: Install .NET 8.0.x\n uses: actions/setup-dotnet@v4\n with:\n dotnet-version: "8.0.x"\n\n - name: Compile\n run: dotnet build -c Debug -warnaserror osu.Desktop.slnf\n\n - name: Test\n run: >\n dotnet test\n osu.Game.Tests/bin/Debug/**/osu.Game.Tests.dll\n osu.Game.Rulesets.Osu.Tests/bin/Debug/**/osu.Game.Rulesets.Osu.Tests.dll\n osu.Game.Rulesets.Taiko.Tests/bin/Debug/**/osu.Game.Rulesets.Taiko.Tests.dll\n osu.Game.Rulesets.Catch.Tests/bin/Debug/**/osu.Game.Rulesets.Catch.Tests.dll\n osu.Game.Rulesets.Mania.Tests/bin/Debug/**/osu.Game.Rulesets.Mania.Tests.dll\n osu.Game.Tournament.Tests/bin/Debug/**/osu.Game.Tournament.Tests.dll\n Templates/**/*.Tests/bin/Debug/**/*.Tests.dll\n --logger "trx;LogFileName=TestResults-${{matrix.os.prettyname}}-${{matrix.threadingMode}}.trx"\n --\n NUnit.ConsoleOut=0\n\n # Attempt to upload results even if test fails.\n # https://docs.github.com/en/actions/reference/context-and-expression-syntax-for-github-actions#always\n - name: Upload Test Results\n uses: actions/upload-artifact@v4\n if: ${{ always() }}\n with:\n name: osu-test-results-${{matrix.os.prettyname}}-${{matrix.threadingMode}}\n path: ${{github.workspace}}/TestResults/TestResults-${{matrix.os.prettyname}}-${{matrix.threadingMode}}.trx\n\n build-only-android:\n name: Build only (Android)\n runs-on: windows-latest\n timeout-minutes: 60\n steps:\n - name: Checkout\n uses: actions/checkout@v4\n\n - name: Setup JDK 11\n uses: actions/setup-java@v4\n with:\n distribution: microsoft\n java-version: 11\n\n - name: Install .NET 8.0.x\n uses: actions/setup-dotnet@v4\n with:\n dotnet-version: "8.0.x"\n\n - name: Install .NET workloads\n run: dotnet workload install android\n\n - name: Compile\n run: dotnet build -c Debug osu.Android.slnf\n\n build-only-ios:\n name: Build only (iOS)\n runs-on: macos-latest\n timeout-minutes: 60\n steps:\n - name: Checkout\n uses: actions/checkout@v4\n\n - name: Install .NET 8.0.x\n uses: actions/setup-dotnet@v4\n with:\n dotnet-version: "8.0.x"\n\n - name: Install .NET Workloads\n run: dotnet workload install ios --from-rollback-file https://raw.githubusercontent.com/ppy/osu-framework/refs/heads/master/workloads.json\n\n - name: Build\n run: dotnet build -c Debug osu.iOS.slnf\n
dataset_sample\yaml\ppy_osu\.github\workflows\ci.yml
ci.yml
YAML
5,056
0.8
0.033557
0.048
react-lib
696
2024-09-15T13:02:35.959678
Apache-2.0
false
7065479806f1646909fab2e140572732
# ## Description\n#\n# Uses [diffcalc-sheet-generator](https://github.com/smoogipoo/diffcalc-sheet-generator) to run two builds of osu and generate an SR/PP/Score comparison spreadsheet.\n#\n# ## Requirements\n#\n# Self-hosted runner with installed:\n# - `docker >= 20.10.16`\n# - `docker-compose >= 2.5.1`\n# - `lbzip2`\n# - `jq`\n#\n# ## Usage\n#\n# The workflow can be run in two ways:\n# 1. Via workflow dispatch.\n# 2. By an owner of the repository posting a pull request or issue comment containing `!diffcalc`.\n# For pull requests, the workflow will assume the pull request as the target to compare against (i.e. the `OSU_B` variable).\n# Any lines in the comment of the form `KEY=VALUE` are treated as variables for the generator.\n#\n# ## Google Service Account\n#\n# Spreadsheets are uploaded to a Google Service Account, and exposed with read-only permissions to the wider audience.\n#\n# 1. Create a project at https://console.cloud.google.com\n# 2. Enable the `Google Sheets` and `Google Drive` APIs.\n# 3. Create a Service Account\n# 4. Generate a key in the JSON format.\n# 5. Encode the key as base64 and store as an **actions secret** with name **`DIFFCALC_GOOGLE_CREDENTIALS`**\n#\n# ## Environment variables\n#\n# The default environment may be configured via **actions variables**.\n#\n# Refer to [the sample environment](https://github.com/smoogipoo/diffcalc-sheet-generator/blob/master/.env.sample), and prefix each variable with `DIFFCALC_` (e.g. `DIFFCALC_THREADS`, `DIFFCALC_INNODB_BUFFER_SIZE`, etc...).\n\nname: Run difficulty calculation comparison\n\nrun-name: "${{ github.event_name == 'workflow_dispatch' && format('Manual run: {0}', inputs.osu-b) || 'Automatic comment trigger' }}"\n\non:\n issue_comment:\n types: [ created ]\n workflow_dispatch:\n inputs:\n osu-b:\n description: "The target build of ppy/osu"\n type: string\n required: true\n ruleset:\n description: "The ruleset to process"\n type: choice\n required: true\n options:\n - osu\n - taiko\n - catch\n - mania\n converts:\n description: "Include converted beatmaps"\n type: boolean\n required: false\n default: true\n ranked-only:\n description: "Only ranked beatmaps"\n type: boolean\n required: false\n default: true\n generators:\n description: "Comma-separated list of generators (available: [sr, pp, score])"\n type: string\n required: false\n default: 'pp,sr'\n osu-a:\n description: "The source build of ppy/osu"\n type: string\n required: false\n default: 'latest'\n difficulty-calculator-a:\n description: "The source build of ppy/osu-difficulty-calculator"\n type: string\n required: false\n default: 'latest'\n difficulty-calculator-b:\n description: "The target build of ppy/osu-difficulty-calculator"\n type: string\n required: false\n default: 'latest'\n score-processor-a:\n description: "The source build of ppy/osu-queue-score-statistics"\n type: string\n required: false\n default: 'latest'\n score-processor-b:\n description: "The target build of ppy/osu-queue-score-statistics"\n type: string\n required: false\n default: 'latest'\n\npermissions:\n pull-requests: write\n\nenv:\n EXECUTION_ID: execution-${{ github.run_id }}-${{ github.run_number }}-${{ github.run_attempt }}\n\ndefaults:\n run:\n shell: bash -euo pipefail {0}\n\njobs:\n check-permissions:\n name: Check permissions\n runs-on: ubuntu-latest\n if: ${{ github.event_name == 'workflow_dispatch' || contains(github.event.comment.body, '!diffcalc') }}\n steps:\n - name: Check permissions\n run: |\n ALLOWED_USERS=(smoogipoo peppy bdach frenzibyte tsunyoku stanriders)\n for i in "${ALLOWED_USERS[@]}"; do\n if [[ "${{ github.actor }}" == "$i" ]]; then\n exit 0\n fi\n done\n exit 1\n\n run-diffcalc:\n name: Run spreadsheet generator\n needs: check-permissions\n uses: ./.github/workflows/_diffcalc_processor.yml\n with:\n # Can't reference env... Why GitHub, WHY?\n id: execution-${{ github.run_id }}-${{ github.run_number }}-${{ github.run_attempt }}\n head-sha: https://github.com/${{ github.repository }}/commit/${{ github.event.pull_request.head.sha || github.sha }}\n pr-url: ${{ github.event.issue.pull_request.html_url || '' }}\n pr-text: ${{ github.event.comment.body || '' }}\n dispatch-inputs: ${{ (github.event.type == 'workflow_dispatch' && toJSON(inputs)) || '' }}\n secrets:\n DIFFCALC_GOOGLE_CREDENTIALS: ${{ secrets.DIFFCALC_GOOGLE_CREDENTIALS }}\n\n create-comment:\n name: Create PR comment\n needs: check-permissions\n runs-on: ubuntu-latest\n if: ${{ github.event_name == 'issue_comment' && github.event.issue.pull_request }}\n steps:\n - name: Create comment\n uses: thollander/actions-comment-pull-request@fabd468d3a1a0b97feee5f6b9e499eab0dd903f6 # v2.5.0\n with:\n comment_tag: ${{ env.EXECUTION_ID }}\n message: |\n Difficulty calculation queued -- please wait! (${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }})\n\n *This comment will update on completion*\n\n output-cli:\n name: Info\n needs: run-diffcalc\n runs-on: ubuntu-latest\n steps:\n - name: Output info\n run: |\n echo "Target: ${{ needs.run-diffcalc.outputs.target }}"\n echo "Spreadsheet: ${{ needs.run-diffcalc.outputs.sheet }}"\n\n update-comment:\n name: Update PR comment\n needs: [ create-comment, run-diffcalc ]\n runs-on: ubuntu-latest\n if: ${{ always() && needs.create-comment.result == 'success' }}\n steps:\n - name: Update comment on success\n if: ${{ needs.run-diffcalc.result == 'success' }}\n uses: thollander/actions-comment-pull-request@fabd468d3a1a0b97feee5f6b9e499eab0dd903f6 # v2.5.0\n with:\n comment_tag: ${{ env.EXECUTION_ID }}\n mode: recreate\n message: |\n Target: ${{ needs.run-diffcalc.outputs.target }}\n Spreadsheet: ${{ needs.run-diffcalc.outputs.sheet }}\n\n - name: Update comment on failure\n if: ${{ needs.run-diffcalc.result == 'failure' }}\n uses: thollander/actions-comment-pull-request@fabd468d3a1a0b97feee5f6b9e499eab0dd903f6 # v2.5.0\n with:\n comment_tag: ${{ env.EXECUTION_ID }}\n mode: recreate\n message: |\n Difficulty calculation failed: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}\n\n - name: Update comment on cancellation\n if: ${{ needs.run-diffcalc.result == 'cancelled' }}\n uses: thollander/actions-comment-pull-request@fabd468d3a1a0b97feee5f6b9e499eab0dd903f6 # v2.5.0\n with:\n comment_tag: ${{ env.EXECUTION_ID }}\n mode: delete\n message: '.' # Appears to be required by this action for non-error status code.\n
dataset_sample\yaml\ppy_osu\.github\workflows\diffcalc.yml
diffcalc.yml
YAML
7,074
0.95
0.056122
0.203297
node-utils
347
2023-10-07T17:03:59.360956
GPL-3.0
false
b608a9a4be988409b563e1a55ce8b7b3
# This is a workaround to allow PRs to report their coverage. This will run inside the base repository.\n# See:\n# * https://github.com/dorny/test-reporter#recommended-setup-for-public-repositories\n# * https://docs.github.com/en/actions/reference/authentication-in-a-workflow#permissions-for-the-github_token\nname: Annotate CI run with test results\non:\n workflow_run:\n workflows: [ "Continuous Integration" ]\n types:\n - completed\n\npermissions:\n contents: read\n actions: read\n checks: write\n\njobs:\n annotate:\n name: Annotate CI run with test results\n runs-on: ubuntu-latest\n if: ${{ github.event.workflow_run.conclusion != 'cancelled' }}\n timeout-minutes: 5\n steps:\n - name: Checkout\n uses: actions/checkout@v4\n with:\n repository: ${{ github.event.workflow_run.repository.full_name }}\n ref: ${{ github.event.workflow_run.head_sha }}\n\n - name: Download results\n uses: actions/download-artifact@v4\n with:\n pattern: osu-test-results-*\n merge-multiple: true\n run-id: ${{ github.event.workflow_run.id }}\n github-token: ${{ github.token }}\n\n - name: Annotate CI run with test results\n uses: dorny/test-reporter@v1.8.0\n with:\n name: Results\n path: "*.trx"\n reporter: dotnet-trx\n list-suites: 'failed'\n list-tests: 'failed'\n
dataset_sample\yaml\ppy_osu\.github\workflows\report-nunit.yml
report-nunit.yml
YAML
1,404
0.8
0.066667
0.097561
vue-tools
616
2023-12-07T09:54:46.800176
GPL-3.0
false
1164c1b0b573b554ad69e5d94cad86d8
name: Add Release to Sentry\n\non:\n push:\n tags:\n - '*'\n\npermissions:\n contents: read # to fetch code (actions/checkout)\n\njobs:\n sentry_release:\n runs-on: ubuntu-latest\n steps:\n - name: Checkout\n uses: actions/checkout@v4\n with:\n fetch-depth: 0\n\n - name: Create Sentry release\n uses: getsentry/action-release@v1\n env:\n SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}\n SENTRY_ORG: ppy\n SENTRY_PROJECT: osu\n SENTRY_URL: https://sentry.ppy.sh/\n with:\n environment: production\n version: osu@${{ github.ref_name }}\n
dataset_sample\yaml\ppy_osu\.github\workflows\sentry-release.yml
sentry-release.yml
YAML
637
0.8
0
0
node-utils
550
2024-12-29T05:56:43.643257
MIT
false
5dbd109f7bb3687bf544d358d1dd8857
name: Update osu-web mod definitions\non:\n push:\n tags:\n - '*'\n\npermissions:\n contents: read # to fetch code (actions/checkout)\n\njobs:\n update-mod-definitions:\n name: Update osu-web mod definitions\n runs-on: ubuntu-latest\n steps:\n - name: Install .NET 8.0.x\n uses: actions/setup-dotnet@v4\n with:\n dotnet-version: "8.0.x"\n\n - name: Checkout ppy/osu\n uses: actions/checkout@v4\n with:\n path: osu\n\n - name: Checkout ppy/osu-tools\n uses: actions/checkout@v4\n with:\n repository: ppy/osu-tools\n path: osu-tools\n\n - name: Checkout ppy/osu-web\n uses: actions/checkout@v4\n with:\n repository: ppy/osu-web\n path: osu-web\n\n - name: Setup local game checkout for tools\n run: ./UseLocalOsu.sh\n working-directory: ./osu-tools\n\n - name: Regenerate mod definitions\n run: dotnet run --project PerformanceCalculator -- mods > ../osu-web/database/mods.json\n working-directory: ./osu-tools\n\n - name: Create pull request with changes\n uses: peter-evans/create-pull-request@v6\n with:\n title: Update mod definitions\n body: "This PR has been auto-generated to update the mod definitions to match ppy/osu@${{ github.ref_name }}."\n branch: update-mod-definitions\n commit-message: Update mod definitions\n path: osu-web\n token: ${{ secrets.OSU_WEB_PULL_REQUEST_PAT }}\n
dataset_sample\yaml\ppy_osu\.github\workflows\update-web-mod-definitions.yml
update-web-mod-definitions.yml
YAML
1,432
0.8
0.018868
0
awesome-app
827
2025-03-02T10:29:33.329292
BSD-3-Clause
false
96a9a58fedfb0eb1610254ca5a95dccd
name: "🔒diffcalc (do not use)"\n\non:\n workflow_call:\n inputs:\n id:\n type: string\n head-sha:\n type: string\n pr-url:\n type: string\n pr-text:\n type: string\n dispatch-inputs:\n type: string\n outputs:\n target:\n description: The comparison target.\n value: ${{ jobs.generator.outputs.target }}\n sheet:\n description: The comparison spreadsheet.\n value: ${{ jobs.generator.outputs.sheet }}\n secrets:\n DIFFCALC_GOOGLE_CREDENTIALS:\n required: true\n\nenv:\n GENERATOR_DIR: ${{ github.workspace }}/${{ inputs.id }}\n GENERATOR_ENV: ${{ github.workspace }}/${{ inputs.id }}/.env\n\ndefaults:\n run:\n shell: bash -euo pipefail {0}\n\njobs:\n generator:\n name: Run\n runs-on: self-hosted\n timeout-minutes: 720\n\n outputs:\n target: ${{ steps.run.outputs.target }}\n sheet: ${{ steps.run.outputs.sheet }}\n\n steps:\n - name: Checkout diffcalc-sheet-generator\n uses: actions/checkout@v4\n with:\n path: ${{ inputs.id }}\n repository: 'smoogipoo/diffcalc-sheet-generator'\n\n - name: Add base environment\n env:\n GOOGLE_CREDS_FILE: ${{ github.workspace }}/${{ inputs.id }}/google-credentials.json\n VARS_JSON: ${{ (vars != null && toJSON(vars)) || '' }}\n run: |\n # Required by diffcalc-sheet-generator\n cp '${{ env.GENERATOR_DIR }}/.env.sample' "${{ env.GENERATOR_ENV }}"\n\n # Add Google credentials\n echo '${{ secrets.DIFFCALC_GOOGLE_CREDENTIALS }}' | base64 -d > "${{ env.GOOGLE_CREDS_FILE }}"\n\n # Add repository variables\n echo "${VARS_JSON}" | jq -c '. | to_entries | .[]' | while read -r line; do\n opt=$(jq -r '.key' <<< ${line})\n val=$(jq -r '.value' <<< ${line})\n\n if [[ "${opt}" =~ ^DIFFCALC_ ]]; then\n optNoPrefix=$(echo "${opt}" | cut -d '_' -f2-)\n sed -i "s;^${optNoPrefix}=.*$;${optNoPrefix}=${val};" "${{ env.GENERATOR_ENV }}"\n fi\n done\n\n - name: Add HEAD environment\n run: |\n sed -i "s;^OSU_A=.*$;OSU_A=${{ inputs.head-sha }};" "${{ env.GENERATOR_ENV }}"\n\n - name: Add pull-request environment\n if: ${{ inputs.pr-url != '' }}\n run: |\n sed -i "s;^OSU_B=.*$;OSU_B=${{ inputs.pr-url }};" "${{ env.GENERATOR_ENV }}"\n\n - name: Add comment environment\n if: ${{ inputs.pr-text != '' }}\n env:\n PR_TEXT: ${{ inputs.pr-text }}\n run: |\n # Add comment environment\n echo "${PR_TEXT}" | sed -r 's/\r$//' | { grep -E '^\w+=' || true; } | while read -r line; do\n opt=$(echo "${line}" | cut -d '=' -f1)\n sed -i "s;^${opt}=.*$;${line};" "${{ env.GENERATOR_ENV }}"\n done\n\n - name: Add dispatch environment\n if: ${{ inputs.dispatch-inputs != '' }}\n env:\n DISPATCH_INPUTS_JSON: ${{ inputs.dispatch-inputs }}\n run: |\n function get_input() {\n echo "${DISPATCH_INPUTS_JSON}" | jq -r ".\"$1\""\n }\n\n osu_a=$(get_input 'osu-a')\n osu_b=$(get_input 'osu-b')\n ruleset=$(get_input 'ruleset')\n generators=$(get_input 'generators')\n difficulty_calculator_a=$(get_input 'difficulty-calculator-a')\n difficulty_calculator_b=$(get_input 'difficulty-calculator-b')\n score_processor_a=$(get_input 'score-processor-a')\n score_processor_b=$(get_input 'score-processor-b')\n converts=$(get_input 'converts')\n ranked_only=$(get_input 'ranked-only')\n\n sed -i "s;^OSU_B=.*$;OSU_B=${osu_b};" "${{ env.GENERATOR_ENV }}"\n sed -i "s/^RULESET=.*$/RULESET=${ruleset}/" "${{ env.GENERATOR_ENV }}"\n sed -i "s/^GENERATORS=.*$/GENERATORS=${generators}/" "${{ env.GENERATOR_ENV }}"\n\n if [[ "${osu_a}" != 'latest' ]]; then\n sed -i "s;^OSU_A=.*$;OSU_A=${osu_a};" "${{ env.GENERATOR_ENV }}"\n fi\n\n if [[ "${difficulty_calculator_a}" != 'latest' ]]; then\n sed -i "s;^DIFFICULTY_CALCULATOR_A=.*$;DIFFICULTY_CALCULATOR_A=${difficulty_calculator_a};" "${{ env.GENERATOR_ENV }}"\n fi\n\n if [[ "${difficulty_calculator_b}" != 'latest' ]]; then\n sed -i "s;^DIFFICULTY_CALCULATOR_B=.*$;DIFFICULTY_CALCULATOR_B=${difficulty_calculator_b};" "${{ env.GENERATOR_ENV }}"\n fi\n\n if [[ "${score_processor_a}" != 'latest' ]]; then\n sed -i "s;^SCORE_PROCESSOR_A=.*$;SCORE_PROCESSOR_A=${score_processor_a};" "${{ env.GENERATOR_ENV }}"\n fi\n\n if [[ "${score_processor_b}" != 'latest' ]]; then\n sed -i "s;^SCORE_PROCESSOR_B=.*$;SCORE_PROCESSOR_B=${score_processor_b};" "${{ env.GENERATOR_ENV }}"\n fi\n\n if [[ "${converts}" == 'true' ]]; then\n sed -i 's/^NO_CONVERTS=.*$/NO_CONVERTS=0/' "${{ env.GENERATOR_ENV }}"\n else\n sed -i 's/^NO_CONVERTS=.*$/NO_CONVERTS=1/' "${{ env.GENERATOR_ENV }}"\n fi\n\n if [[ "${ranked_only}" == 'true' ]]; then\n sed -i 's/^RANKED_ONLY=.*$/RANKED_ONLY=1/' "${{ env.GENERATOR_ENV }}"\n else\n sed -i 's/^RANKED_ONLY=.*$/RANKED_ONLY=0/' "${{ env.GENERATOR_ENV }}"\n fi\n\n - name: Query latest scores\n id: query-scores\n run: |\n ruleset=$(cat ${{ env.GENERATOR_ENV }} | grep -E '^RULESET=' | cut -d '=' -f2-)\n performance_data_name=$(curl -s "https://data.ppy.sh/" | grep "performance_${ruleset}_top_1000\b" | tail -1 | awk -F "'" '{print $2}' | sed 's/\.tar\.bz2//g')\n\n echo "TARGET_DIR=${{ env.GENERATOR_DIR }}/sql/${ruleset}" >> "${GITHUB_OUTPUT}"\n echo "DATA_NAME=${performance_data_name}" >> "${GITHUB_OUTPUT}"\n echo "DATA_PKG=${performance_data_name}.tar.bz2" >> "${GITHUB_OUTPUT}"\n\n - name: Restore score cache\n id: restore-score-cache\n uses: maxnowack/local-cache@720e69c948191660a90aa1cf6a42fc4d2dacdf30 # v2\n with:\n path: ${{ steps.query-scores.outputs.DATA_PKG }}\n key: ${{ steps.query-scores.outputs.DATA_NAME }}\n\n - name: Download scores\n if: steps.restore-score-cache.outputs.cache-hit != 'true'\n run: |\n wget -q -O "${{ steps.query-scores.outputs.DATA_PKG }}" "https://data.ppy.sh/${{ steps.query-scores.outputs.DATA_PKG }}"\n\n - name: Extract scores\n run: |\n tar -I lbzip2 -xf "${{ steps.query-scores.outputs.DATA_PKG }}"\n rm -r "${{ steps.query-scores.outputs.TARGET_DIR }}"\n mv "${{ steps.query-scores.outputs.DATA_NAME }}" "${{ steps.query-scores.outputs.TARGET_DIR }}"\n\n - name: Query latest beatmaps\n id: query-beatmaps\n run: |\n beatmaps_data_name=$(curl -s "https://data.ppy.sh/" | grep "osu_files" | tail -1 | awk -F "'" '{print $2}' | sed 's/\.tar\.bz2//g')\n\n echo "TARGET_DIR=${{ env.GENERATOR_DIR }}/beatmaps" >> "${GITHUB_OUTPUT}"\n echo "DATA_NAME=${beatmaps_data_name}" >> "${GITHUB_OUTPUT}"\n echo "DATA_PKG=${beatmaps_data_name}.tar.bz2" >> "${GITHUB_OUTPUT}"\n\n - name: Restore beatmap cache\n id: restore-beatmap-cache\n uses: maxnowack/local-cache@720e69c948191660a90aa1cf6a42fc4d2dacdf30 # v2\n with:\n path: ${{ steps.query-beatmaps.outputs.DATA_PKG }}\n key: ${{ steps.query-beatmaps.outputs.DATA_NAME }}\n\n - name: Download beatmap\n if: steps.restore-beatmap-cache.outputs.cache-hit != 'true'\n run: |\n wget -q -O "${{ steps.query-beatmaps.outputs.DATA_PKG }}" "https://data.ppy.sh/${{ steps.query-beatmaps.outputs.DATA_PKG }}"\n\n - name: Extract beatmap\n run: |\n tar -I lbzip2 -xf "${{ steps.query-beatmaps.outputs.DATA_PKG }}"\n rm -r "${{ steps.query-beatmaps.outputs.TARGET_DIR }}"\n mv "${{ steps.query-beatmaps.outputs.DATA_NAME }}" "${{ steps.query-beatmaps.outputs.TARGET_DIR }}"\n\n - name: Run\n id: run\n run: |\n # Add the GitHub token. This needs to be done here because it's unique per-job.\n sed -i 's/^GH_TOKEN=.*$/GH_TOKEN=${{ github.token }}/' "${{ env.GENERATOR_ENV }}"\n\n cd "${{ env.GENERATOR_DIR }}"\n\n docker compose up --build --detach\n docker compose logs --follow &\n docker compose wait generator\n\n link=$(docker compose logs --tail 10 generator | grep 'http' | sed -E 's/^.*(http.*)$/\1/')\n target=$(cat "${{ env.GENERATOR_ENV }}" | grep -E '^OSU_B=' | cut -d '=' -f2-)\n\n echo "target=${target}" >> "${GITHUB_OUTPUT}"\n echo "sheet=${link}" >> "${GITHUB_OUTPUT}"\n\n - name: Shutdown\n if: ${{ always() }}\n run: |\n cd "${{ env.GENERATOR_DIR }}"\n docker compose down --volumes\n rm -rf "${{ env.GENERATOR_DIR }}"\n
dataset_sample\yaml\ppy_osu\.github\workflows\_diffcalc_processor.yml
_diffcalc_processor.yml
YAML
8,901
0.95
0.074561
0.026455
node-utils
853
2023-09-10T00:03:43.192798
GPL-3.0
false
fb6bb1ec5f7ba754fbad08d919ab6358
cache_dir: /tmp/TranslationTool/\npaths:\n - classes\n - controllers\n - admin-dev\n - modules\n - src\n - override\n - install-dev\n - themes\n - pdf\n - mails/themes\nexclude_files:\n - src/PrestaShopBundle/Tests\n - classes/PrestaShopAutoload.php\n - var/cache/\n - var/logs\n - node_modules\n - vendor\n - tools\n - mails/[a-zA-Z]{2}/\n - js\n - modules/ps_themecusto\n
dataset_sample\yaml\PrestaShop_PrestaShop\.t9n.yml
.t9n.yml
YAML
370
0.7
0
0
python-kit
831
2025-01-25T15:24:02.700482
Apache-2.0
false
a3782f1dd6030d7a9b6c43fbda28ae3c
version: '2.1'\n\nvolumes:\n db-data:\n\nservices:\n mariadb:\n image: mariadb:11.4\n ports:\n - "3306:3306"\n volumes:\n - db-data:/var/lib/mysql\n environment:\n MARIADB_ROOT_PASSWORD: ${DB_PASSWD:-prestashop}\n MARIADB_DATABASE: ${DB_NAME:-prestashop}\n healthcheck:\n test: ["CMD", "healthcheck.sh", "--connect", "--innodb_initialized"]\n start_period: 10s\n interval: 5s\n timeout: 1s\n retries: 3\n restart: unless-stopped\n networks:\n - prestashop-network\n\n prestashop-git:\n hostname: ${PS_HOSTNAME:-localhost}\n build:\n dockerfile: .docker/Dockerfile\n context: .\n args:\n - VERSION=${VERSION:-8.1-apache}\n - USER_ID=${USER_ID:-1000}\n - GROUP_ID=${GROUP_ID:-1000}\n - NODE_VERSION=${NODE_VERSION:-16.20.1}\n - INSTALL_XDEBUG=${INSTALL_XDEBUG:-false}\n environment:\n DISABLE_MAKE: ${DISABLE_MAKE:-0}\n PS_INSTALL_AUTO: ${PS_INSTALL_AUTO:-1}\n DB_PASSWD: ${DB_PASSWD:-prestashop}\n DB_NAME: ${DB_NAME:-prestashop}\n DB_SERVER: ${DB_SERVER:-mariadb}\n DB_PREFIX: ${DB_PREFIX:-ps_}\n PS_DOMAIN: ${PS_DOMAIN:-localhost:8001}\n PS_FOLDER_INSTALL: ${PS_FOLDER_INSTALL:-install-dev}\n PS_FOLDER_ADMIN: ${PS_FOLDER_ADMIN:-admin-dev}\n PS_COUNTRY: ${PS_COUNTRY:-fr}\n PS_LANGUAGE: ${PS_LANGUAGE:-en}\n PS_DEV_MODE: ${PS_DEV_MODE:-1}\n PS_ENABLE_SSL: ${PS_ENABLE_SSL:-0}\n PS_ERASE_DB: ${PS_ERASE_DB:-0}\n PS_USE_DOCKER_MAILDEV: ${PS_USE_DOCKER_MAILDEV:-1}\n ADMIN_MAIL: ${ADMIN_MAIL:-demo@prestashop.com}\n ADMIN_PASSWD: ${ADMIN_PASSWD:-Correct Horse Battery Staple}\n BLACKFIRE_ENABLE: ${BLACKFIRE_ENABLE:-0}\n BLACKFIRE_SERVER_ID: ${BLACKFIRE_SERVER_ID:-0}\n BLACKFIRE_SERVER_TOKEN: ${BLACKFIRE_SERVER_TOKEN:-0}\n command: /tmp/docker_run_git.sh\n ports:\n - "8001:80"\n - "8002:443"\n depends_on:\n mariadb:\n condition: service_healthy\n volumes:\n - ./:/var/www/html:delegated\n networks:\n - prestashop-network\n\n maildev:\n image: 'maildev/maildev'\n ports:\n - "1080:1080"\n networks:\n - prestashop-network\n\nnetworks:\n prestashop-network:\n name: prestashop-network\n
dataset_sample\yaml\PrestaShop_PrestaShop\docker-compose.mariadb.yml
docker-compose.mariadb.yml
YAML
2,212
0.7
0
0
vue-tools
100
2024-12-18T18:38:36.546156
Apache-2.0
false
e146a1ee0d36d89f08ef1469f45a81ac
version: '2.1'\n\nvolumes:\n db-data:\n\nservices:\n mysql:\n image: mysql:8\n ports:\n - "3306:3306"\n volumes:\n - db-data:/var/lib/mysql\n environment:\n MYSQL_ROOT_PASSWORD: ${DB_PASSWD:-prestashop}\n MYSQL_DATABASE: ${DB_NAME:-prestashop}\n restart: unless-stopped\n networks:\n - prestashop-network\n\n prestashop-git:\n hostname: ${PS_HOSTNAME:-localhost}\n build:\n dockerfile: .docker/Dockerfile\n context: .\n args:\n - VERSION=${VERSION:-8.1-apache}\n - USER_ID=${USER_ID:-1000}\n - GROUP_ID=${GROUP_ID:-1000}\n - NODE_VERSION=${NODE_VERSION:-20.17.0}\n - INSTALL_XDEBUG=${INSTALL_XDEBUG:-false}\n environment:\n DISABLE_MAKE: ${DISABLE_MAKE:-0}\n PS_INSTALL_AUTO: ${PS_INSTALL_AUTO:-1}\n DB_PASSWD: ${DB_PASSWD:-prestashop}\n DB_NAME: ${DB_NAME:-prestashop}\n DB_SERVER: ${DB_SERVER:-mysql}\n DB_PREFIX: ${DB_PREFIX:-ps_}\n PS_DOMAIN: ${PS_DOMAIN:-localhost:8001}\n PS_FOLDER_INSTALL: ${PS_FOLDER_INSTALL:-install-dev}\n PS_FOLDER_ADMIN: ${PS_FOLDER_ADMIN:-admin-dev}\n PS_COUNTRY: ${PS_COUNTRY:-fr}\n PS_LANGUAGE: ${PS_LANGUAGE:-en}\n PS_DEV_MODE: ${PS_DEV_MODE:-1}\n PS_ENABLE_SSL: ${PS_ENABLE_SSL:-0}\n PS_ERASE_DB: ${PS_ERASE_DB:-0}\n PS_USE_DOCKER_MAILDEV: ${PS_USE_DOCKER_MAILDEV:-1}\n ADMIN_MAIL: ${ADMIN_MAIL:-demo@prestashop.com}\n ADMIN_PASSWD: ${ADMIN_PASSWD:-Correct Horse Battery Staple}\n BLACKFIRE_ENABLE: ${BLACKFIRE_ENABLE:-0}\n BLACKFIRE_SERVER_ID: ${BLACKFIRE_SERVER_ID:-0}\n BLACKFIRE_SERVER_TOKEN: ${BLACKFIRE_SERVER_TOKEN:-0}\n command: /tmp/wait-for-it.sh --timeout=60 --strict mysql:3306 -- /tmp/docker_run_git.sh\n ports:\n - "8001:80"\n - "8002:443"\n depends_on:\n - mysql\n volumes:\n - ./:/var/www/html:delegated\n networks:\n - prestashop-network\n\n maildev:\n image: 'maildev/maildev'\n ports:\n - "1080:1080"\n - "1025:1025"\n networks:\n - prestashop-network\n\nnetworks:\n prestashop-network:\n name: prestashop-network\n
dataset_sample\yaml\PrestaShop_PrestaShop\docker-compose.yml
docker-compose.yml
YAML
2,069
0.7
0.013699
0
react-lib
261
2024-03-01T12:56:54.923029
Apache-2.0
false
974042e176561ffc723baf38a8ee004c
# Configuration for sentiment-bot - https://github.com/behaviorbot/sentiment-bot\n\n# *Required* toxicity threshold between 0 and .99 with the higher numbers being the most toxic\n# Anything higher than this threshold will be marked as toxic and commented on\nsentimentBotToxicityThreshold: .7\n\n# *Required* Comment to reply with\nsentimentBotReplyComment: >\n Please be sure to review our Code of conduct and be respectful of other users. Repeated offenders will be banned.\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\config.yml
config.yml
YAML
472
0.8
0.111111
0.571429
react-lib
323
2024-11-08T03:18:28.501122
BSD-3-Clause
false
330a89dc2003214105981138a7fba7ed
version: 2\nupdates:\n - package-ecosystem: npm\n directory: "/tests/UI"\n schedule:\n interval: weekly\n day: monday\n time: "04:00"\n open-pull-requests-limit: 10\n target-branch: develop\n reviewers:\n - "PrestaShop/qa-automation"\n labels:\n - "dependencies"\n - "develop"\n - "E2E Tests"\n - "TE"\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\dependabot.yml
dependabot.yml
YAML
345
0.7
0
0
node-utils
868
2023-10-21T18:04:46.946310
MIT
false
06556bfc21e8c4d993bd4ddec16dd6bc
name: Setup PrestaShop Environment\ndescription: Setup a docker Environment for PrestaShop\n\ninputs:\n # PrestaShop Config inputs\n PHP_VERSION:\n required: true\n description: PHP Version For PrestaShop\n NODE_VERSION:\n required: false\n description: Node Version to Build Themes\n default: 16.20.1\n DB_SERVER:\n required: false\n description: Database Server for PrestaShop (mysql/mariadb)\n default: mysql\n ENABLE_SSL:\n required: false\n description: True to Run with SSL\n default: 'true'\n INSTALL_AUTO:\n required: false\n description: True To Auto Install\n default: 'true'\n CP_API_CONFIG:\n # Workaround until 8.1.x is supported\n required: false\n description: True To Copy API Config\n default: 'false'\n DEV_MODE:\n required: false\n description: True to enable Developer mode\n default: 'false'\n DISABLE_MAKE:\n required: false\n description: true to disable Make\n default: 'false'\n PRESTASHOP_DIR:\n required: false\n description: Prestashop folder\n default: '.'\n\nruns:\n using: 'composite'\n steps:\n # Certificate for SSL\n - name: Generate a Certificate\n if: inputs.ENABLE_SSL == 'true'\n shell: bash\n run: |\n ## Install MkCert\n sudo apt-get update\n sudo apt install libnss3-tools\n curl -JLO "https://dl.filippo.io/mkcert/latest?for=linux/amd64"\n chmod +x mkcert-v*-linux-amd64\n sudo cp mkcert-v*-linux-amd64 /usr/local/bin/mkcert\n ## Generate certificate\n mkcert -key-file ${{ inputs.PRESTASHOP_DIR }}/.docker/ssl.key -cert-file ${{ inputs.PRESTASHOP_DIR }}/.docker/ssl.crt localhost\n ## Link certificate to Chrome Trust Store\n mkdir -p $HOME/.pki/nssdb\n certutil -d $HOME/.pki/nssdb -N\n certutil -d sql:$HOME/.pki/nssdb -n localhost -A -t "TCu,Cu,Tu" -i ${{ inputs.PRESTASHOP_DIR }}/.docker/ssl.crt\n ## Add self-signed certificate to Chrome Trust Store\n mkcert -install\n\n # Run composer install outside of docker because inside it regularly has network issues\n - name: Composer Install\n if: inputs.DISABLE_MAKE != 'true'\n run: COMPOSER_PROCESS_TIMEOUT=600 composer install --ansi --prefer-dist --no-interaction --no-progress\n shell: bash\n\n # Docker to create the shop\n - name: Build and Run shop with docker\n shell: bash\n env:\n DISABLE_MAKE: ${{ (inputs.DISABLE_MAKE == 'true') && '1' || '0' }}\n PS_ENABLE_SSL: ${{ (inputs.ENABLE_SSL == 'true') && '1' || '0' }}\n PS_INSTALL_AUTO: ${{ (inputs.INSTALL_AUTO == 'true') && '1' || '0' }}\n PS_USE_DOCKER_MAILDEV: 0\n VERSION: ${{ inputs.PHP_VERSION }}-apache\n NODE_VERSION: ${{ inputs.NODE_VERSION }}\n URL_FO: ${{ (inputs.ENABLE_SSL == 'false') && 'http://localhost:8001/' || 'https://localhost:8002/' }}\n URL_PING: ${{ (inputs.INSTALL_AUTO == 'true') && 'en/' || 'install-dev/' }}\n PS_DOMAIN: ${{ (inputs.ENABLE_SSL == 'false') && 'localhost:8001' || 'localhost:8002' }}\n PS_DEV_MODE: ${{ (inputs.DEV_MODE == 'false') && '0' || '1' }}\n DB_SERVER: ${{ inputs.DB_SERVER }}\n DB_NAME: 'prestashop'\n DB_PREFIX: 'tst_'\n DB_USER: 'root'\n DB_PASSWD: 'prestashop'\n PS_LANGUAGE: 'en'\n ADMIN_PASSWD: 'Correct Horse Battery Staple'\n run: |\n cd ${{ inputs.PRESTASHOP_DIR }}\n USER_ID=$(id -u) GROUP_ID=$(id -g) \\n docker compose -f ${{ (inputs.DB_SERVER == 'mysql') && 'docker-compose.yml' || 'docker-compose.mariadb.yml' }} up -d prestashop-git --build\n bash -c 'while [[ "$(curl -L -s -o /dev/null -w %{http_code} ${{ env.URL_FO }}${{ env.URL_PING }})" != "200" ]]; do sleep 5; done'\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\actions\setup-env\action.yml
action.yml
YAML
3,726
0.95
0.072165
0.096774
python-kit
574
2024-10-01T17:36:25.842325
GPL-3.0
false
5029f515ab956f5b5bcda0ab1a685c1e
name: Export logs from the setup env action\ndescription: Export logs from the setup env action, usually on failure\n\ninputs:\n DOCKER_PREFIX:\n required: true\n description: Docker prefix for prestashop containers\n ARTIFACT_NAME:\n required: false\n description: Artifact exported name\n default: setup-logs\n DB_SERVER:\n required: false\n description: Database Server for PrestaShop (mysql/mariadb)\n default: mysql\n ENABLE_SSL:\n required: false\n description: True to Run with SSL\n default: 'true'\n INSTALL_AUTO:\n required: false\n description: True To Auto Install\n default: 'true'\n PRESTASHOP_DIR:\n required: false\n description: Prestashop folder\n default: '.'\n\nruns:\n using: 'composite'\n steps:\n - name: List dockers\n run: |\n cd ${{ inputs.PRESTASHOP_DIR }}\n docker ps\n shell: bash\n\n - name: Export docker logs\n run: |\n cd ${{ inputs.PRESTASHOP_DIR }}\n mkdir -p ./var/docker-logs\n docker logs ${{ inputs.DOCKER_PREFIX }}-${{ inputs.DB_SERVER }}-1 > ./var/docker-logs/${{ inputs.DB_SERVER }}.log\n docker logs ${{ inputs.DOCKER_PREFIX }}-prestashop-git-1 > ./var/docker-logs/prestashop.log\n shell: bash\n\n - name: Export front output\n shell: bash\n env:\n URL_FO: ${{ (inputs.ENABLE_SSL == 'false') && 'http://localhost:8001/' || 'https://localhost:8002/' }}\n URL_PING: ${{ (inputs.INSTALL_AUTO == 'true') && 'en/' || 'install-dev/' }}\n run: |\n wget -O ${{ inputs.PRESTASHOP_DIR }}/var/logs/front.html ${{ env.URL_FO }}${{ env.URL_PING }}\n\n - name: Sanitize artifact name\n id: sanitize-artifact-name\n run: echo "ARTIFACT_NAME=$( echo -e '${{ inputs.ARTIFACT_NAME }}' | tr ':' '-' )" >> $GITHUB_OUTPUT\n shell: bash\n\n - name: Save logs in case of error\n uses: actions/upload-artifact@v4\n with:\n name: ${{ steps.sanitize-artifact-name.outputs.ARTIFACT_NAME }}\n path: |\n ${{ inputs.PRESTASHOP_DIR }}/var/logs\n ${{ inputs.PRESTASHOP_DIR }}/var/docker-logs\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\actions\setup-env-export-logs\action.yml
action.yml
YAML
2,068
0.95
0.030769
0
python-kit
554
2023-11-19T07:28:22.316967
BSD-3-Clause
false
0571c69dfa705d516f2e2e3413d815f4
name: Setup Keycloak\ndescription: Checkout Keycloak Module for installation and to launch Keycloak docker\n\nruns:\n using: 'composite'\n steps:\n - uses: actions/checkout@v4\n name: Checkout Keycloak module\n with:\n repository: PrestaShop/keycloak_connector_demo\n ref: v1.1.0\n path: keycloak_connector_demo\n\n - name: Build Keycloak docker and install module via CLI command\n run: USER_ID=$(id -u) GROUP_ID=$(id -g) docker compose -f keycloak_connector_demo/docker-compose-ui.yml up -d\n shell: bash\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\actions\setup-keycloak\action.yml
action.yml
YAML
541
0.7
0.0625
0
react-lib
667
2024-04-20T18:31:41.961038
MIT
false
feeed677f6f839a0c6def2cfd1ebf65b
name: Setup and Run UI tests\ndescription: Setup a UI Tests Environment and run tests\n\ninputs:\n # TEST Config inputs\n TESTS_DIR:\n required: false\n description: Tests Folder on PrestaShop\n default: './tests/UI/'\n ENABLE_SSL:\n required: false\n description: True to Run with SSL\n default: 'true'\n TEST_CAMPAIGN:\n required: true\n description: Campaign To Run\n NODE_VERSION:\n required: false\n description: Node Version for tests\n default: '20'\n BROWSER:\n required: false\n description: Bowser for tests\n default: 'chromium'\n INSTALL_BROWSERS:\n required: false\n description: True To Install Browsers\n default: 'true'\n DB_SERVER:\n required: false\n description: Database Server (mysql/mariadb)\n default: 'mysql'\n TAKE_SCREENSHOT_AFTER_EACH_STEP:\n required: false\n description: Take screenshot after each step\n default: 'false'\n\nruns:\n using: 'composite'\n steps:\n - name: Setup Node\n uses: actions/setup-node@v4\n with:\n node-version: ${{ inputs.NODE_VERSION }}\n\n - name: Use .env.ci\n working-directory: ${{ inputs.TESTS_DIR }}\n shell: bash\n run: |\n cp .env.ci .env\n sed -i -e "s/TAKE_SCREENSHOT_AFTER_EACH_STEP.*/TAKE_SCREENSHOT_AFTER_EACH_STEP=${{ inputs.TAKE_SCREENSHOT_AFTER_EACH_STEP == 'false' && 'false' || 'true' }}/g" .env\n\n - name: Install dependencies\n working-directory: ${{ inputs.TESTS_DIR }}\n shell: bash\n run: npm ci\n\n - name: Install browsers\n if: inputs.INSTALL_BROWSERS == 'true'\n working-directory: ${{ inputs.TESTS_DIR }}\n shell: bash\n run: npx playwright install ${{ inputs.BROWSER }} --with-deps\n\n # Run tests\n - name: Run tests\n working-directory: ${{ inputs.TESTS_DIR }}\n env:\n BROWSER: ${{ inputs.BROWSER }}\n ENABLE_SSL: ${{ inputs.ENABLE_SSL }}\n URL_FO: ${{ (env.URL_FO != '') && env.URL_FO || ((inputs.ENABLE_SSL == 'false') && 'http://localhost:8001/' || 'https://localhost:8002/') }}\n URL_BO: ${{ (inputs.ENABLE_SSL == 'false') && 'http://localhost:8001/admin-dev/' || 'https://localhost:8002/admin-dev/' }}\n URL_API: ${{ (inputs.ENABLE_SSL == 'false') && 'http://localhost:8001/admin-api/' || 'https://localhost:8002/admin-api/' }}\n URL_INSTALL: ${{ (inputs.ENABLE_SSL == 'false') && 'http://localhost:8001/install-dev/' || 'https://localhost:8002/install-dev/' }}\n DB_SERVER: ${{ inputs.DB_SERVER }}\n LANG: 'en-GB'\n shell: bash\n run: npm run test:${{ inputs.TEST_CAMPAIGN }}\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\actions\ui-test\action.yml
action.yml
YAML
2,550
0.95
0.038961
0.028169
python-kit
225
2024-02-15T13:49:13.503546
Apache-2.0
true
f35a27e258b322b62c085c9b81f1efa6
title: "[Idea] "\nbody:\n - type: markdown\n attributes:\n value: |\n Thank you for sharing your ideas. Please take the time to provide as much detail as possible.\n - type: textarea\n id: problem\n attributes:\n label: The problem\n description: Describe what problem you would like to see solved.\n placeholder: I'm always frustrated when...\n validations:\n required: false\n - type: textarea\n id: solution\n attributes:\n label: The solution\n description: Describe the solution(s) that you imagine for the aforementioned problem.\n placeholder: Changing XYZ would help because...\n validations:\n required: true\n - type: textarea\n id: alternative\n attributes:\n label: Alternatives\n description: Are there any other solutions to that problem that you have considered?\n validations:\n required: false\n - type: textarea\n id: additional-context\n attributes:\n label: Additional context\n description: Add any other helpful information or screenshots here.\n validations:\n required: false\n - type: checkboxes\n attributes:\n label: Do you plan to work on this subject?\n description: While optional, taking matters into your own hands will significantly increase the chances that it gets done. Plase select all that apply for you.\n options:\n - label: I'm willing to contribute a [formal specification](https://github.com/PrestaShop/prestashop-specs).\n - label: I'm willing to provide any wireframes or design assets required for this feature.\n - label: I'm willing to submit a Pull Request that implements this feature.\n - label: I'm willing to help verify that the implemented feature works as intended and produces no unintended side effects.\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\DISCUSSION_TEMPLATE\ideas.yml
ideas.yml
YAML
1,791
0.95
0.088889
0
awesome-app
962
2024-10-16T19:46:38.965574
GPL-3.0
false
71c448138b49bc1f6d7adea02ad4c16c
name: 🐛 Bug Report\ndescription: Report an issue in PrestaShop or one of the native modules. DO NOT disclose security issues here, contact security@prestashop.com instead!\nlabels: [ "Bug", "New" ]\nbody:\n - type: markdown\n attributes:\n value: |\n ### ❗️ Read this before submitting your bug report:\n - **Write in English.** Reports in all other languages will be closed.\n - **Provide as much detail as possible** - error logs, screenshots, your exact configuration. If the issue cannot be reproduced, it cannot be fixed.\n - **Follow the [bug report guidelines](https://devdocs.prestashop-project.org/9/contribute/contribute-reporting-issues/#best-practices-for-writing-an-issue).** This will help issue managers qualify your report faster.\n - **Avoid reporting "error 500" or "white page" errors** - this is a universal error message that does not provide enough information to qualify the issue. Enable debug mode in the Performance section of PrestaShop or manually in `/config/defines.inc.php` and try again. You should get a proper error message.\n - If reporting a problem with the upgrade process, open `/admin/autoupgrade/tmp` and attach the last part of `log.txt` to the issue. It may contain information about the upgrade errors helpful in resolving the issue. Do not upload the entire `log.txt` as it contains sensitive data.\n - type: checkboxes\n attributes:\n label: Prerequisites\n options:\n - label: I understand and accept the project's [code of conduct](https://github.com/PrestaShop/PrestaShop/blob/develop/CODE_OF_CONDUCT.md).\n required: true\n - label: I have already [searched in existing issues](https://github.com/PrestaShop/PrestaShop/issues?q=is%3Aissue+label%3ABug) and found no previous report of this bug.\n required: true\n - type: textarea\n id: what-happened\n attributes:\n label: Describe the bug and add attachments\n description: What went wrong? If possible, add screenshots, error logs or screen recordings to help explain your problem.\n validations:\n required: true\n - type: textarea\n id: expected-behavior\n attributes:\n label: Expected behavior\n description: Explain what you expected to happen instead.\n validations:\n required: false\n - type: textarea\n id: steps-reproduce\n attributes:\n label: Steps to reproduce\n description: List the exact steps to reproduce the issue.\n placeholder: |\n 1. Go to '...'\n 2. Click on '....'\n 3. Scroll down to '....'\n 4. See error\n validations:\n required: true\n - type: input\n id: prestashop-version\n attributes:\n label: PrestaShop version(s) where the bug happened\n description: If the issue concerns upgrade, specify which versions you upgrading FROM and upgrading TO\n placeholder: "e.g., 1.7.5.2 or 1.7.8.0"\n validations:\n required: true\n - type: input\n id: php-version\n attributes:\n label: PHP version(s) where the bug happened\n placeholder: "e.g., 7.1 or 8.0"\n validations:\n required: false\n - type: input\n id: module\n attributes:\n label: If your bug is related to a module, specify its name and its version\n placeholder: "e.g., ps_facetedsearch v7.0"\n validations:\n required: false\n - type: input\n id: sponsor-company\n attributes:\n label: Your company or customer's name goes here (if applicable).\n validations:\n required: false\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\ISSUE_TEMPLATE\1_bug_report.yml
1_bug_report.yml
YAML
3,511
0.95
0.04
0.013333
node-utils
508
2024-11-25T12:19:34.109151
BSD-3-Clause
false
17796791e9d3febb2f4e2cdb4be9ce5d
blank_issues_enabled: false\ncontact_links:\n - name: 🚀 Idea / Feature request\n url: https://github.com/PrestaShop/PrestaShop/discussions/new?category=ideas\n about: Suggest an idea to improve PrestaShop\n - name: 🙏 I need help\n url: https://www.prestashop-project.org/support/\n about: If you have questions or need help\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\ISSUE_TEMPLATE\config.yml
config.yml
YAML
337
0.8
0
0
vue-tools
640
2024-06-24T15:52:59.416101
BSD-3-Clause
false
436f6ea94fa247547581af38848e6200
name: API Module tests\non:\n push:\n pull_request:\n\npermissions:\n contents: read # to clone the repos and get release assets (shivammathur/setup-php)\nconcurrency:\n group: ${{ github.event_name }}-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}\n cancel-in-progress: true\njobs:\n integration:\n permissions:\n contents: read # to clone the repos and get release assets (shivammathur/setup-php)\n name: API Module tests\n runs-on: ubuntu-latest\n strategy:\n matrix:\n php: [ '8.1', '8.2', '8.3', '8.4' ]\n fail-fast: false\n steps:\n - name: Setup PHP\n uses: shivammathur/setup-php@v2\n with:\n php-version: ${{ matrix.php }}\n extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv\n env:\n GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n - name: Setup MySQL\n uses: mirromutth/mysql-action@v1.1\n with:\n mysql version: '8.0'\n mysql database: 'prestashop'\n mysql root password: 'password'\n - name: Setup Node\n uses: actions/setup-node@v4\n with:\n node-version: '20'\n\n - uses: actions/checkout@v4\n\n - name: PrestaShop Configuration\n run: |\n cp .github/workflows/phpunit/parameters.yml app/config/parameters.yml\n cp .github/workflows/phpunit/parameters.php app/config/parameters.php\n\n - name: Get Composer Cache Directory\n id: composer-cache\n run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT\n\n - name: Cache Node Directory\n uses: actions/cache@v4\n with:\n path: ~/.npm\n key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}\n restore-keys: ${{ runner.os }}-node-\n\n - name: Cache Composer Directory\n uses: actions/cache@v4\n with:\n path: ${{ steps.composer-cache.outputs.dir }}\n key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}\n restore-keys: ${{ runner.os }}-composer-\n\n - name: Composer Install\n run: COMPOSER_PROCESS_TIMEOUT=600 composer install --ansi --prefer-dist --no-interaction --no-progress\n\n - name: Update phpunit version\n if: ${{ startsWith(matrix.php, '8.') }}\n run: COMPOSER_PROCESS_TIMEOUT=600 composer update -w --ignore-platform-reqs --no-interaction phpunit/phpunit\n\n # Front assets are needed for the theme to be installed and image types to be inserted in DB, admin assets required\n # because some built files (like preload.html.twig) are included and cause errors when absent\n - name: Build all assets\n run: make assets\n\n - name: Change MySQL authentication method\n run: mysql -h127.0.0.1 -uroot -ppassword -e "ALTER USER 'root'@'%' IDENTIFIED WITH mysql_native_password BY 'password'; FLUSH PRIVILEGES;"\n\n - name: Run integration-tests\n run: composer run-script api-module-tests --timeout=0\n env:\n SYMFONY_DEPRECATIONS_HELPER: disabled\n\n - name: Test git versionned files unchanged\n if: ${{ !startsWith(matrix.php, '8.') }} # composer.lock changes when updating phpunit version\n run: git diff --exit-code\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\api-module.yml
api-module.yml
YAML
3,234
0.95
0.034483
0.026667
vue-tools
199
2025-06-05T13:27:35.972157
MIT
false
e1588eca71b2f751114d66c7cf6f6a61
name: Behaviour tests\non:\n push:\n pull_request:\n\npermissions:\n contents: read # to clone the repos and get release assets (shivammathur/setup-php)\nconcurrency:\n group: ${{ github.event_name }}-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}\n cancel-in-progress: true\njobs:\n behaviour:\n permissions:\n contents: read # to clone the repos and get release assets (shivammathur/setup-php)\n name: Behaviour tests\n runs-on: ubuntu-latest\n strategy:\n matrix:\n php: [ '8.1', '8.2', '8.3', '8.4' ]\n fail-fast: false\n steps:\n - name: Setup PHP\n uses: shivammathur/setup-php@v2\n with:\n php-version: ${{ matrix.php }}\n extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv\n env:\n GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n - name: Setup MySQL\n uses: mirromutth/mysql-action@v1.1\n with:\n mysql version: '8.0'\n mysql database: 'prestashop'\n mysql root password: 'password'\n - name: Setup Node\n uses: actions/setup-node@v4\n with:\n node-version: '20'\n\n - uses: actions/checkout@v4\n\n - name: PrestaShop Configuration\n run: |\n cp .github/workflows/phpunit/parameters.yml app/config/parameters.yml\n cp .github/workflows/phpunit/parameters.php app/config/parameters.php\n\n - name: Get Composer Cache Directory\n id: composer-cache\n run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT\n\n - name: Cache Node Directory\n uses: actions/cache@v4\n with:\n path: ~/.npm\n key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}\n restore-keys: ${{ runner.os }}-node-\n\n - name: Cache Composer Directory\n uses: actions/cache@v4\n with:\n path: ${{ steps.composer-cache.outputs.dir }}\n key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}\n restore-keys: ${{ runner.os }}-composer-\n\n - name: Composer Install\n run: COMPOSER_PROCESS_TIMEOUT=600 composer install --ansi --prefer-dist --no-interaction --no-progress\n\n - name: Build theme assets\n run: make front-classic\n\n - name: Change MySQL authentication method\n run: mysql -h127.0.0.1 -uroot -ppassword -e "ALTER USER 'root'@'%' IDENTIFIED WITH mysql_native_password BY 'password'; FLUSH PRIVILEGES;"\n\n - name: Install maildev\n run: |\n docker run -d -p 1080:1080 -p 1025:1025 maildev/maildev\n bash -c 'while [[ "$(curl -L -s -o /dev/null -w %{http_code} http://localhost:1080)" != "200" ]]; do echo "Wait for maildev"; sleep 5; done'\n\n - name: Run integration-behaviour-tests\n run: composer run-script integration-behaviour-tests --timeout=0\n env:\n SYMFONY_DEPRECATIONS_HELPER: disabled\n\n - name: Upload logs\n uses: actions/upload-artifact@v4\n if: failure()\n with:\n name: behaviour-${{ matrix.php }}\n path: |\n ./var/logs\n\n - name: Test git versionned files unchanged\n run: git diff --exit-code\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\behaviour.yml
behaviour.yml
YAML
3,183
0.8
0.032258
0
react-lib
884
2023-08-11T14:59:35.023565
BSD-3-Clause
false
61be05d7c607b419bdf822c0f1a0ac67
# This workflow allows you to check potential changes to the structure of the database,\n# and to apply the “Needs autoupgrade PR” label if this is the case\nname: Create diff for 'Needs autoupgrade PR' label\n\non: pull_request\n\njobs:\n\n check_is_merge:\n name: Check is merge PR\n runs-on: ubuntu-latest\n steps:\n - name: Check is merge PR\n id: check-is-merge\n run: |\n description=$(\n cat <<"EOF"\n ${{ toJSON(github.event.pull_request.body) }}\n EOF\n )\n if [[ $description =~ \|?[[:space:]]*Category\?[[:space:]]*\|[[:space:]]*ME([[:space:]]|(\\[rn]))+ ]]; then\n echo "isMerge=true" >> $GITHUB_OUTPUT\n fi\n outputs:\n isMerge: ${{ steps.check-is-merge.outputs.isMerge }}\n\n install_prestashop_and_dump:\n name: Install Prestashop and create database dump\n runs-on: ubuntu-latest\n needs: [ check_is_merge ]\n if: needs.check_is_merge.outputs.isMerge != 'true'\n strategy:\n matrix:\n branch: [ base, head ]\n fail-fast: false\n env:\n DUMP_TABLES_FOR_DIFF: "ps_hook ps_feature_flag ps_tab"\n steps:\n - uses: actions/checkout@v4\n with:\n fetch-depth: ${{ matrix.branch == 'head' && '0' || '1' }}\n ref: ${{ matrix.branch == 'base' && github.event.pull_request.base.ref || github.event.pull_request.head.ref }}\n repository: ${{ matrix.branch == 'base' && github.event.pull_request.base.repo.full_name || github.event.pull_request.head.repo.full_name }}\n\n - name: Rebase head\n if: ${{ matrix.branch == 'head' }}\n run: |\n git config --global user.email "prestashop@prestashop.com"\n git config --global user.name "Bot"\n git pull --rebase ${{ github.event.pull_request.base.repo.clone_url }} ${{ github.event.pull_request.base.ref }}\n\n - name: Docker build\n run: docker compose build prestashop-git\n\n - name: Fetch dependencies\n run: COMPOSER_PROCESS_TIMEOUT=600 docker compose run --rm prestashop-git composer install --ansi --prefer-dist --no-interaction --no-progress --no-dev\n\n - name: Waiting for database\n run: docker compose run --rm prestashop-git /tmp/wait-for-it.sh --timeout=60 --strict mysql:3306\n\n - name: Create base database\n run: docker compose run --rm mysql mysql -hmysql -uroot -pprestashop -e "CREATE DATABASE presta_${{ matrix.branch }};"\n\n - name: Install shop\n run: docker compose run --rm prestashop-git php install-dev/index_cli.php \\n --step=database --db_server=mysql:3306 --db_name=presta_${{ matrix.branch }} \\n --db_user=root --db_password=prestashop --prefix=ps_ --db_clear=1 \\n --domain=localhost:8001 --firstname="Marc" --lastname="Beier" \\n --password=Toto123! --email=demo@prestashop.com --language=fr --country=fr \\n --newsletter=0 --send_email=0 --ssl=0\n\n - name: Export dump\n run: |\n docker compose run --rm mysql sh -c "exec mysqldump -hmysql -uroot --no-data --compact -pprestashop presta_${{ matrix.branch }}" > dump_${{ matrix.branch }}.sql\n docker compose run --rm mysql sh -c "exec mysqldump -hmysql -uroot --no-create-info --compact -pprestashop presta_${{ matrix.branch }} ${{ env.DUMP_TABLES_FOR_DIFF }}" >> dump_${{ matrix.branch }}.sql\n\n - name: Upload dump\n uses: actions/upload-artifact@v4\n with:\n name: dump_${{ matrix.branch }}\n path: |\n dump_${{ matrix.branch }}.sql\n\n create_diff:\n name: Create database dumps diff\n needs: [ install_prestashop_and_dump ]\n runs-on: ubuntu-latest\n steps:\n - uses: actions/download-artifact@v4\n\n - name: Create diff\n run: git diff ./dump_head/dump_head.sql ./dump_base/dump_base.sql > sql-diff.txt | true\n\n - name: Save PR number\n run: |\n mkdir -p ./pr\n echo ${{ github.event.number }} > ./pr_number\n\n - name: Upload diff\n uses: actions/upload-artifact@v4\n with:\n name: sql_diff\n path: |\n sql-diff.txt\n pr_number\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\create_diff_for_autoupgrade_pr_label.yml
create_diff_for_autoupgrade_pr_label.yml
YAML
4,119
0.8
0.066667
0.022472
node-utils
477
2024-07-18T18:39:01.010705
MIT
false
67d369b3b42fb1f365c1db32a5465821
# This tests the build for development\nname: Cron docker build\n\non:\n schedule:\n - cron: '0 1 * * *'\n\njobs:\n docker-build:\n name: Docker build\n\n runs-on: ubuntu-latest\n\n strategy:\n matrix:\n version:\n - 8.1\n base:\n - apache\n - fpm\n\n steps:\n - uses: actions/checkout@v4\n with:\n fetch-depth: 0\n\n - name: Running latest prestashop with docker\n run: docker compose build --build-arg VERSION=${{ matrix.version }}-${{ matrix.base }}\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\cron_docker_build.yml
cron_docker_build.yml
YAML
522
0.8
0.035714
0.045455
awesome-app
736
2025-03-13T08:32:10.785711
GPL-3.0
false
a83db550b8f49bfe4efba97cc360a29a
name: Cron Update JS Routing\non:\n schedule:\n - cron: '0 23 * * *'\n workflow_dispatch:\n\npermissions: { }\njobs:\n js-routing-dump:\n permissions:\n contents: write # to create branch (peter-evans/create-pull-request)\n pull-requests: write # to create a PR (peter-evans/create-pull-request)\n\n runs-on: ubuntu-latest\n name: Update JS Routing\n strategy:\n fail-fast: false\n matrix:\n BRANCH:\n - develop\n - 9.0.x\n - 8.2.x\n - 8.1.x\n - 8.0.x\n include:\n - BRANCH: develop\n node: 20\n - BRANCH: 9.0.x\n node: 20\n - BRANCH: 8.2.x\n node: 16\n\n env:\n PHP_VERSION: '7.4'\n NODE_VERSION: ${{ matrix.node }}\n GH_BRANCH: ${{ matrix.BRANCH }}\n\n steps:\n - name: Setup PHP\n uses: shivammathur/setup-php@v2\n with:\n php-version: ${{ env.PHP_VERSION }}\n extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv, simplexml\n env:\n GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n\n - name: Setup MySQL\n uses: mirromutth/mysql-action@v1.1\n with:\n mysql version: '5.7'\n mysql database: 'prestashop'\n mysql root password: 'password'\n\n - name: Setup Node\n uses: actions/setup-node@v4\n with:\n node-version: ${{ env.NODE_VERSION }}\n\n - name: Checkout\n uses: actions/checkout@v4\n with:\n fetch-depth: 0\n ref: ${{ env.GH_BRANCH }}\n\n - name: PrestaShop Configuration\n run: cp .github/workflows/phpunit/parameters.yml app/config/parameters.yml\n\n - name: Get Composer Cache Directory\n id: composer-cache\n run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT\n\n - name: Cache Node Directory\n uses: actions/cache@v4\n with:\n path: ~/.npm\n key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}\n restore-keys: |\n ${{ runner.os }}-node-\n\n - name: Cache Composer Directory\n uses: actions/cache@v4\n with:\n path: ${{ steps.composer-cache.outputs.dir }}\n key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}\n restore-keys: |\n ${{ runner.os }}-composer-\n\n - name: Install Composer dependencies\n run: COMPOSER_PROCESS_TIMEOUT=600 composer install --ansi --prefer-dist --no-interaction --no-progress\n\n - name: Build assets\n run: make assets\n\n - name: Install PrestaShop\n # yamllint disable-line rule:line-length\n run: php install-dev/index_cli.php --language=en --country=fr --domain=localhost --db_server=127.0.0.1 --db_password=password --db_name=prestashop --db_create=1 --name=prestashop.unit.test --email=demo@prestashop.com --password=prestashop_demo\n\n - name: Dump JS Routing file\n # yamllint disable-line rule:line-length\n run: php bin/console fos:js-routing:dump --format=json --target=admin-dev/themes/new-theme/js/fos_js_routes.json\n\n - name: Create Pull Request\n uses: peter-evans/create-pull-request@v3\n with:\n token: ${{ secrets.GITHUB_TOKEN }}\n branch: cron-js-routing\n add-paths: |\n admin-dev/themes/new-theme/js/fos_js_routes.json\n commit-message: Updated JS Routing file\n committer: PrestonBot <noreply@github.com>\n author: prestonBot <prestonBot@users.noreply.github.com>\n title: 'Updated JS Routing file'\n body: |\n | Questions | Answers\n | ----------------- | -------------------------------------------------------\n | Branch? | ${{ env.GH_BRANCH }}\n | Description? | Updated JS Routing file\n | Type? | improvement\n | Category? | CO\n | BC breaks? | no\n | Deprecations? | no\n | Fixed ticket? | N/A\n | How to test? | N/A\n | Possible impacts? | N/A\n base: ${{ env.GH_BRANCH }}\n delete-branch: true\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\cron_js_routing.yml
cron_js_routing.yml
YAML
4,238
0.8
0
0.018182
python-kit
764
2025-01-11T10:27:01.330402
GPL-3.0
false
bfbf288bd22fb7e2c8bb01e66d6b46fc
# This workflow aim to create nightly builds on active branches\nname: Nightly Build\n\non:\n schedule:\n - cron: '0 0 * * *'\n workflow_dispatch:\n\npermissions:\n contents: read\n\njobs:\n nightly-build:\n name: Nightly Build\n\n runs-on: ubuntu-latest\n\n strategy:\n fail-fast: false\n matrix:\n BRANCH:\n - develop\n - 9.0.x\n - 8.2.x\n - 8.1.x\n - 8.0.x\n - 1.7.8.x\n include:\n - BRANCH: develop\n node: 20\n - BRANCH: 9.0.x\n node: 20\n - BRANCH: 8.2.x\n node: 16\n - BRANCH: 8.1.x\n node: 16\n - BRANCH: 8.0.x\n node: 14\n - BRANCH: 1.7.8.x\n node: 14\n\n env:\n PHP_VERSION: '7.4'\n NODE_VERSION: ${{ matrix.node }}\n RELEASE_DIR: '/tmp/ps-release'\n GH_BRANCH: ${{ matrix.BRANCH }}\n GC_PROJECT_ID: ${{ secrets.GC_PROJECT_ID }}\n GC_SERVICE_KEY: ${{ secrets.GC_SERVICE_KEY }}\n XML_FILE: ${{ matrix.BRANCH == 'develop' && 'nightly.xml' || format('nightly_{0}.xml', matrix.BRANCH)}}\n ZIP_FILE: ${{ matrix.BRANCH == 'develop' && 'nightly.zip' || format('nightly_{0}.zip', matrix.BRANCH)}}\n\n steps:\n - uses: actions/checkout@v4\n with:\n fetch-depth: 0\n ref: ${{ env.GH_BRANCH }}\n\n - name: Setup PHP\n uses: shivammathur/setup-php@v2\n with:\n php-version: ${{ env.PHP_VERSION }}\n extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv\n env:\n GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n\n - name: Setup Node\n uses: actions/setup-node@v4\n with:\n node-version: ${{ env.NODE_VERSION }}\n\n - name: Create Release directory\n run: mkdir -p ${{ env.RELEASE_DIR }}\n\n - name: Create build\n run: php tools/build/CreateRelease.php --destination-dir=${{ env.RELEASE_DIR }}\n\n - name: Rename build\n run: today=`date +%Y-%m-%d`; for i in *; do mv $i $today-$GH_BRANCH-$i; done\n working-directory: ${{ env.RELEASE_DIR }}\n\n - name: Create nightly.(zip & xml) for each branch\n run: |\n today=`date +%Y-%m-%d`\n cp $today-$GH_BRANCH*.zip ${{ env.ZIP_FILE }}\n cp $today-$GH_BRANCH*.xml ${{ env.XML_FILE }}\n working-directory: ${{ env.RELEASE_DIR }}\n\n - name: Auth Cloud Sdk\n uses: google-github-actions/auth@v1\n with:\n credentials_json: ${{ env.GC_SERVICE_KEY }}\n project_id: ${{ env.GC_PROJECT_ID }}\n\n - name: Setup Cloud Sdk\n uses: google-github-actions/setup-gcloud@v1\n\n - name: Delete last Nightly zip for each branch\n run: gsutil rm -rf gs://prestashop-core-nightly/${{ env.ZIP_FILE }}\n\n - name: Delete last Nightly xml for each branch\n run: gsutil rm -rf gs://prestashop-core-nightly/${{ env.XML_FILE }}\n\n - name: Upload to Google Cloud Storage (GCS)\n if: always()\n run: gsutil cp -r "${{ env.RELEASE_DIR }}/**" gs://prestashop-core-nightly\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\cron_nightly_build.yml
cron_nightly_build.yml
YAML
3,049
0.8
0.047619
0.011494
python-kit
215
2024-03-11T12:22:08.593337
GPL-3.0
false
07ddc2d16e7743417249e58ca79a22f5
name: Cron Update PHP Modules\non:\n schedule:\n - cron: '0 23 * * *'\n workflow_dispatch:\n\npermissions:\n contents: read\n\njobs:\n update-composer-modules:\n permissions:\n contents: write # for peter-evans/create-pull-request to create branch\n pull-requests: write # for peter-evans/create-pull-request to create a PR\n runs-on: ubuntu-latest\n name: Update PHP Modules\n strategy:\n fail-fast: false\n matrix:\n BRANCH:\n - develop\n - 9.0.x\n - 8.2.x\n env:\n GH_BRANCH: ${{ matrix.BRANCH }}\n\n steps:\n - name: Setup PHP\n uses: shivammathur/setup-php@v2\n with:\n extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv, simplexml\n env:\n GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n\n - name: Checkout\n uses: actions/checkout@v4\n with:\n fetch-depth: 0\n ref: ${{ env.GH_BRANCH }}\n\n - name: Install Composer dependencies\n run: |\n composer self-update --stable\n COMPOSER_PROCESS_TIMEOUT=600 composer install --ansi --prefer-dist --no-interaction --no-progress\n\n - name: Execute script for updating modules\n run: php .github/workflows/cron_update_modules/script.php ${{ env.GH_BRANCH }}\n\n - name: Update PrestaShop packages\n id: updated-packages\n run: |\n if [[ -f cron_php_update_modules.txt ]]; then\n FILE_CONTENT=$(cat cron_php_update_modules.txt)\n echo PR_BODY=$FILE_CONTENT >> $GITHUB_OUTPUT\n rm cron_php_update_modules.txt\n else\n echo 'Nothing to update'\n fi\n\n - name: Create Pull Request\n uses: peter-evans/create-pull-request@v3\n if: ${{steps.updated-packages.outputs.PR_BODY}} != ''\n with:\n token: ${{ secrets.GITHUB_TOKEN }}\n branch: cron-php-update-modules-${{ env.GH_BRANCH }}\n commit-message: Updated PrestaShop Packages\n committer: PrestonBot <noreply@github.com>\n author: prestonBot <prestonBot@users.noreply.github.com>\n title: 'Updated PrestaShop Packages'\n body: ${{steps.updated-packages.outputs.PR_BODY}}\n base: ${{ env.GH_BRANCH }}\n delete-branch: true\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\cron_php_update_modules.yml
cron_php_update_modules.yml
YAML
2,272
0.8
0.069444
0
vue-tools
176
2024-05-20T02:19:19.462282
Apache-2.0
false
66f3b5026068dac25f753f4f215a7eeb
name: Integration tests\non:\n push:\n pull_request:\n\npermissions:\n contents: read # to clone the repos and get release assets (shivammathur/setup-php)\nconcurrency:\n group: ${{ github.event_name }}-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}\n cancel-in-progress: true\njobs:\n integration:\n permissions:\n contents: read # to clone the repos and get release assets (shivammathur/setup-php)\n name: Integration tests\n runs-on: ubuntu-latest\n strategy:\n matrix:\n php: [ '8.1', '8.2', '8.3', '8.4' ]\n fail-fast: false\n steps:\n - name: Setup PHP\n uses: shivammathur/setup-php@v2\n with:\n php-version: ${{ matrix.php }}\n extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv\n env:\n GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n - name: Setup MySQL\n uses: mirromutth/mysql-action@v1.1\n with:\n mysql version: '8.0'\n mysql database: 'prestashop'\n mysql root password: 'password'\n - name: Setup Node\n uses: actions/setup-node@v4\n with:\n node-version: '20'\n\n - uses: actions/checkout@v4\n\n - name: PrestaShop Configuration\n run: |\n cp .github/workflows/phpunit/parameters.yml app/config/parameters.yml\n cp .github/workflows/phpunit/parameters.php app/config/parameters.php\n\n - name: Get Composer Cache Directory\n id: composer-cache\n run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT\n\n - name: Cache Node Directory\n uses: actions/cache@v4\n with:\n path: ~/.npm\n key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}\n restore-keys: ${{ runner.os }}-node-\n\n - name: Cache Composer Directory\n uses: actions/cache@v4\n with:\n path: ${{ steps.composer-cache.outputs.dir }}\n key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}\n restore-keys: ${{ runner.os }}-composer-\n\n - name: Composer Install\n run: COMPOSER_PROCESS_TIMEOUT=600 composer install --ansi --prefer-dist --no-interaction --no-progress\n\n - name: Update phpunit version\n if: ${{ startsWith(matrix.php, '8.') }}\n run: COMPOSER_PROCESS_TIMEOUT=600 composer update -w --ignore-platform-reqs --no-interaction phpunit/phpunit\n\n # Front assets are needed for the theme to be installed and image types to be inserted in DB, admin assets required especially\n # because some built files (like preload.html.twig) are included and cause errors when absent\n - name: Build all assets\n run: make assets\n\n - name: Change MySQL authentication method\n run: mysql -h127.0.0.1 -uroot -ppassword -e "ALTER USER 'root'@'%' IDENTIFIED WITH mysql_native_password BY 'password'; FLUSH PRIVILEGES;"\n\n - name: Run integration-tests\n run: composer run-script integration-tests --timeout=0\n env:\n SYMFONY_DEPRECATIONS_HELPER: disabled\n\n - name: Test git versionned files unchanged\n if: ${{ !startsWith(matrix.php, '8.') }} # composer.lock changes when updating phpunit version\n run: git diff --exit-code\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\integration.yml
integration.yml
YAML
3,248
0.95
0.034483
0.026667
python-kit
107
2024-02-14T16:07:20.194068
GPL-3.0
false
5b8b1030553df2971dd380f7a479a5dd
name: Js\non:\n push:\n pull_request:\n\npermissions:\n contents: read\nconcurrency:\n group: ${{ github.event_name }}-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}\n cancel-in-progress: true\njobs:\n js-unit-tests:\n runs-on: ubuntu-latest\n name: Run unit tests\n strategy:\n matrix:\n js: [ '20' ]\n steps:\n - name: Setup Node\n uses: actions/setup-node@v4\n with:\n node-version: ${{ matrix.js }}\n\n - name: Checkout\n uses: actions/checkout@v4\n\n - name: Cache Node Directory\n uses: actions/cache@v4\n with:\n path: ~/.npm\n key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}\n restore-keys: ${{ runner.os }}-node-\n\n - name: Run tests\n run: npm ci && npm run test\n working-directory: ./admin-dev/themes/new-theme\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\js.yml
js.yml
YAML
874
0.7
0
0
awesome-app
174
2025-05-09T18:01:57.276804
BSD-3-Clause
false
9e3895babd4bf08fa2cd9773b7d47797
name: Lint\non:\n push:\n pull_request:\n\npermissions:\n contents: read\nconcurrency:\n group: ${{ github.event_name }}-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}\n cancel-in-progress: true\njobs:\n stylelint:\n name: SCSS Lint\n runs-on: ubuntu-latest\n steps:\n - uses: actions/checkout@v4\n\n - name: Setup Node\n uses: actions/setup-node@v4\n with:\n node-version: '16.x'\n\n - name: BackOffice Theme `new-theme`\n run: cd ./admin-dev/themes/new-theme && npm ci && npm run scss-lint\n\n - name: BackOffice Theme `default`\n run: cd ./admin-dev/themes/default && npm ci && npm run scss-lint\n\n eslint:\n name: ESLint\n runs-on: ubuntu-latest\n steps:\n - uses: actions/checkout@v4\n\n - name: Setup Node\n uses: actions/setup-node@v4\n with:\n node-version: '16.x'\n\n - name: Validate npm config\n run: >-\n (cd admin-dev/themes/default && npm ci)\n && (cd admin-dev/themes/new-theme && npm ci)\n && (cd themes && npm ci)\n\n - name: BackOffice Theme `default`\n run: cd ./admin-dev/themes/default && npm ci && npm run lint\n\n - name: BackOffice Theme `new-theme`\n run: cd ./admin-dev/themes/new-theme && npm ci && npm run lint\n\n yamllint_sf:\n name: YAML Lint (Symfony Check)\n runs-on: ubuntu-latest\n steps:\n - name: Setup PHP\n uses: shivammathur/setup-php@v2\n with:\n extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv, simplexml\n env:\n GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n - uses: actions/checkout@v4\n\n - name: Get Composer Cache Directory\n id: composer-cache\n run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT\n\n - name: Cache Composer Directory\n uses: actions/cache@v4\n with:\n path: ${{ steps.composer-cache.outputs.dir }}\n key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}\n restore-keys: |\n ${{ runner.os }}-composer-\n\n - name: Composer Install\n run: COMPOSER_PROCESS_TIMEOUT=600 composer install --ansi --prefer-dist --no-interaction --no-progress\n\n - name: Run Lint Yaml on `app`\n run: php bin/console lint:yaml app --parse-tags\n\n - name: Run Lint Yaml on `src` tags are allowed\n run: php bin/console lint:yaml src --parse-tags\n\n - name: Run Lint Yaml on `.t9n.yml`\n run: php bin/console lint:yaml .t9n.yml\n\n yamllint:\n name: YAML Lint (YamlLint Check)\n runs-on: ubuntu-latest\n steps:\n - uses: actions/setup-python@v5\n with:\n python-version: '3.x'\n - name: Install YAMLLint\n run: |\n pip install --user yamllint\n - uses: actions/checkout@v4\n\n - name: yamllint on `.github`\n run: yamllint -c .github/workflows/yamllint/.yamllint.yml .github\n\n - name: yamllint on `app`\n run: yamllint -c .github/workflows/yamllint/.yamllint.yml app\n\n - name: yamllint on `src`\n run: yamllint -c .github/workflows/yamllint/.yamllint.yml src\n\n - name: yamllint on `.t9n.yml`\n run: yamllint -c .github/workflows/yamllint/.yamllint.yml .t9n.yml\n\n legacy_link_lint:\n name: Legacy Link Lint\n runs-on: ubuntu-latest\n steps:\n - name: Setup PHP\n uses: shivammathur/setup-php@v2\n with:\n extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv, simplexml\n env:\n GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n - uses: actions/checkout@v4\n\n - name: Get Composer Cache Directory\n id: composer-cache\n run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT\n\n - name: Cache Composer Directory\n uses: actions/cache@v4\n with:\n path: ${{ steps.composer-cache.outputs.dir }}\n key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}\n restore-keys: |\n ${{ runner.os }}-composer-\n\n - name: Composer Install\n run: COMPOSER_PROCESS_TIMEOUT=600 composer install --ansi --prefer-dist --no-interaction --no-progress\n\n - name: Run Legacy Link Lint\n run: php bin/console prestashop:linter:legacy-link\n\n security_attribute_lint:\n name: Admin Security Attribute Linter\n runs-on: ubuntu-latest\n steps:\n - name: Setup PHP\n uses: shivammathur/setup-php@v2\n with:\n extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv, simplexml\n env:\n GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n - uses: actions/checkout@v4\n\n - name: Get Composer Cache Directory\n id: composer-cache\n run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT\n\n - name: Cache Composer Directory\n uses: actions/cache@v4\n with:\n path: ${{ steps.composer-cache.outputs.dir }}\n key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}\n restore-keys: |\n ${{ runner.os }}-composer-\n\n - name: Composer Install\n run: COMPOSER_PROCESS_TIMEOUT=600 composer install --ansi --prefer-dist --no-interaction --no-progress\n\n # Now install the shop so that modules controllers are also checked\n - name: Setup Environment\n timeout-minutes: 15\n uses: ./.github/actions/setup-env\n with:\n PHP_VERSION: 8.1\n ENABLE_SSL: 'true'\n INSTALL_AUTO: 'true'\n - name: Setup Environment failure\n uses: ./.github/actions/setup-env-export-logs\n with:\n DOCKER_PREFIX: prestashop\n ARTIFACT_NAME: setup-symfony-console-${{ matrix.app-id }}\n ENABLE_SSL: 'true'\n INSTALL_AUTO: 'false'\n if: failure()\n\n - name: Run Admin Security Attribute Linter (inside the docker so installed modules are also scanned)\n run: |\n echo Searching for routes without security\n docker exec prestashop-prestashop-git-1 php bin/console prestashop:linter:security-attribute find-missing\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\lint.yml
lint.yml
YAML
6,110
0.8
0.010582
0.006369
vue-tools
726
2023-09-30T10:01:44.520338
Apache-2.0
false
050f598da284f21497aa163dc30014dc
# This workflow allows you to add a comment to the pull request if the label "Needs autoupgrade PR" is present and there are at least 2 approves\nname: Notify for 'Needs autoupgrade PR' label\n\non:\n workflow_run:\n workflows: [ Verify 'Needs autoupgrade PR' label and approvals ]\n types:\n - completed\n\njobs:\n add_comment:\n name: Add comment\n runs-on: ubuntu-latest\n steps:\n - id: download_artifact\n name: Download artifact\n uses: actions/github-script@v6\n with:\n script: |\n const allArtifacts = await github.rest.actions.listWorkflowRunArtifacts({\n owner: context.repo.owner,\n repo: context.repo.repo,\n run_id: context.payload.workflow_run.id,\n });\n const matchArtifact = allArtifacts.data.artifacts.filter((artifact) => {\n return artifact.name == "approval_count"\n })[0];\n if (!matchArtifact) {\n throw new Error("Artifact 'approval_count' not found.");\n }\n const download = await github.rest.actions.downloadArtifact({\n owner: context.repo.owner,\n repo: context.repo.repo,\n artifact_id: matchArtifact.id,\n archive_format: 'zip',\n });\n\n const fs = require('fs');\n fs.writeFileSync(`${process.env.GITHUB_WORKSPACE}/approval_count.zip`, Buffer.from(download.data));\n\n - name: Unzip artifact\n run: |\n unzip approval_count.zip\n echo "approvals=$(cat ./approvals)" >> $GITHUB_ENV\n echo "label_present=$(cat ./label)" >> $GITHUB_ENV\n echo "pr_number=$(cat ./pr_number)" >> $GITHUB_ENV\n echo "author=$(cat ./author)" >> $GITHUB_ENV\n\n - name: Check diff for label\n if: ${{ env.approvals >= 2 && env.label_present == '1' }}\n run: |\n PR_NUMBER=${{ env.pr_number }}\n PR_CREATOR=${{ env.author }}\n\n COMMENT="Hello @$PR_CREATOR,<br/>\n Please note that the “Needs autoupgrade PR” label has been automatically added to your Pull Request. This means that the changes made in your PR must also be reported in the Autoupgrade module, responsible for running the update process of PrestaShop stores.<br/>\n When there's a modification to the \`db-structure.sql\` file or if a Doctrine entity has been modified, added, or deleted, it impacts the database structure. Modifying the list of hooks and feature flags has consequences on the update process as well. These changes can affect how the application interacts with the database and how update procedures are handled. It's important to consider these aspects when contributing to ensure a smooth update experience for users.<br/>\n That's why this contribution should be backported, with another corresponding PR, on the Autoupgrade module's GitHub repository which is available here: [Autoupgrade Repository](https://github.com/PrestaShop/autoupgrade)\n Contribution to the Autoupgrade module documentation: [Documentation Link](https://devdocs.prestashop-project.org/9/contribute/contribution-guidelines/upgrade-module/)<br/>\n Don't forget to add a comment in this current thread with the link to this PR once it has been created.<br/>\n If you are sure that your Pull Request doesn’t require additional actions, ping [committers](https://www.prestashop-project.org/project-organization/people-and-roles/#committers) and it will be checked.<br/>\n Thank you."\n\n gh api repos/${{ github.repository }}/issues/$PR_NUMBER/comments \\n -f body="$COMMENT"\n env:\n GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n GH_REPO: ${{ github.repository }}\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\notify_for_autoupgrade_pr_label.yml
notify_for_autoupgrade_pr_label.yml
YAML
3,772
0.95
0.117647
0.016393
awesome-app
467
2025-03-16T17:27:43.244003
Apache-2.0
false
4c3538247c9177532ac82f0cfbe4d094
name: PHP\non:\n push:\n pull_request:\n\npermissions:\n contents: read\nconcurrency:\n group: ${{ github.event_name }}-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}\n cancel-in-progress: true\njobs:\n php-cs-fixer:\n permissions:\n contents: read # for actions/checkout to fetch code\n name: PHP CS Fixer\n runs-on: ubuntu-latest\n steps:\n - name: Setup PHP\n uses: shivammathur/setup-php@v2\n with:\n php-version: 8.1\n extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv\n env:\n GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n - uses: actions/checkout@v4\n\n - name: Get Composer Cache Directory\n id: composer-cache\n run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT\n\n - name: Cache Composer Directory\n uses: actions/cache@v4\n with:\n path: ${{ steps.composer-cache.outputs.dir }}\n key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}\n restore-keys: ${{ runner.os }}-composer-\n\n - name: Validate composer config\n run: composer validate --strict\n\n - name: Composer Install\n run: COMPOSER_PROCESS_TIMEOUT=600 composer install --ansi --prefer-dist --no-interaction --no-progress\n\n - name: Run PHPCSFixer\n run: ./vendor/bin/php-cs-fixer fix --dry-run --diff\n\n - name: Run ergebnis/composer-normalize\n run: composer normalize --dry-run --no-check-lock\n phpstan:\n permissions:\n contents: read # for actions/checkout to fetch code\n name: PHP Static Analysis\n runs-on: ubuntu-latest\n strategy:\n matrix:\n php: [ '8.1', '8.2', '8.3', '8.4' ]\n fail-fast: false\n steps:\n - name: Setup PHP\n uses: shivammathur/setup-php@v2\n with:\n php-version: '8.1' # will be overriden by platform.php in composer.json see https://phpstan.org/config-reference#phpversion\n extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv, simplexml\n coverage: none # disable coverage to disable xdebug in the action.\n env:\n GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n\n - uses: actions/checkout@v4\n\n - name: Get Composer Cache Directory\n id: composer-cache\n run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT\n\n - name: Cache Composer Directory\n uses: actions/cache@v4\n with:\n path: ${{ steps.composer-cache.outputs.dir }}\n key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}\n restore-keys: ${{ runner.os }}-composer-\n\n - name: Composer Install\n run: |\n COMPOSER_PROCESS_TIMEOUT=600 composer install --ansi --prefer-dist --no-interaction --no-progress\n rm composer.lock\n composer config platform.php ${{ matrix.php }}\n\n - name: Run phpstan\n run: ./vendor/bin/phpstan analyse -c phpstan.neon.dist\n phpunit:\n permissions:\n contents: read # for actions/checkout to fetch code\n name: PHPUnit\n runs-on: ubuntu-latest\n strategy:\n matrix:\n php: [ '8.1', '8.2', '8.3', '8.4' ]\n fail-fast: false\n steps:\n - name: Setup PHP\n uses: shivammathur/setup-php@v2\n with:\n php-version: ${{ matrix.php }}\n extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv, simplexml\n env:\n GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n\n - uses: actions/checkout@v4\n\n - name: PrestaShop Configuration\n run: cp .github/workflows/phpunit/parameters.yml app/config/parameters.yml\n\n - name: Get Composer Cache Directory\n id: composer-cache\n run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT\n\n - name: Cache Composer Directory\n uses: actions/cache@v4\n with:\n path: ${{ steps.composer-cache.outputs.dir }}\n key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}\n restore-keys: ${{ runner.os }}-composer-\n\n - name: Composer Install\n run: COMPOSER_PROCESS_TIMEOUT=600 composer install --ansi --prefer-dist --no-interaction --no-progress\n\n - name: Update phpunit version\n if: ${{ startsWith(matrix.php, '8.') }}\n run: COMPOSER_PROCESS_TIMEOUT=600 composer update -w --ignore-platform-reqs --no-interaction phpunit/phpunit\n\n - name: Run phpunit\n run: ./vendor/phpunit/phpunit/phpunit -c tests/Unit/phpunit.xml\n env:\n SYMFONY_DEPRECATIONS_HELPER: disabled\n\n - name: Test git versionned files unchanged\n if: ${{ !startsWith(matrix.php, '8.') }} # composer.lock changes when updating phpunit version\n run: git diff --exit-code\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\php.yml
php.yml
YAML
4,777
0.8
0.036496
0
python-kit
470
2025-06-29T16:50:53.842499
BSD-3-Clause
false
1099fe55e3c67795822bc19f867610c8
name: Pull Request Validator\non: pull_request\nconcurrency:\n group: ${{ github.event_name }}-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}\n cancel-in-progress: true\njobs:\n message-check:\n name: Block Merge Commits\n\n runs-on: ubuntu-latest\n\n steps:\n - name: Check is merge PR\n id: check-is-merge\n run: |\n description=$(\n cat <<"EOF"\n ${{ toJSON(github.event.pull_request.body) }}\n EOF\n )\n if [[ $description =~ \|?[[:space:]]*Category\?[[:space:]]*\|[[:space:]]*ME([[:space:]]|(\\[rn]))+ ]]; then\n echo "isMerge=true" >> $GITHUB_OUTPUT\n fi\n\n - name: Block Merge Commits\n if: steps.check-is-merge.outputs.isMerge != 'true'\n uses: Morishiri/block-merge-commits-action@v1.0.1\n with:\n repo-token: ${{ secrets.GITHUB_TOKEN }}\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\pr.yml
pr.yml
YAML
892
0.7
0.068966
0
vue-tools
991
2024-04-01T13:11:19.981223
MIT
false
30cd1e5c9931458e8fd77459ef4ebad0
name: UI tests\n\non: [ push, pull_request ]\n\npermissions:\n contents: read # to fetch code (actions/checkout)\n\nconcurrency:\n group: ${{ github.event_name }}-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}\n cancel-in-progress: true\n\nenv:\n TEST_CAMPAIGN: 'sanity:fast-fail'\n\njobs:\n sanity:\n permissions:\n contents: read # to fetch code (actions/checkout)\n runs-on: ubuntu-latest\n name: Sanity\n strategy:\n matrix:\n include:\n ## Check all PHP versions\n - php: 8.1\n browser: chromium\n db: mysql\n - php: 8.2\n browser: chromium\n db: mysql\n - php: 8.3\n browser: chromium\n db: mysql\n - php: 8.4\n browser: chromium\n db: mysql\n\n ## Check all browsers (except Chrome)\n - php: 8.4\n browser: firefox\n db: mysql\n ## @todo : https://github.com/PrestaShop/PrestaShop/issues/37680\n # - php: 8.4\n # browser: webkit\n # db: mysql\n\n ## Check all DB supported\n # MySQL is checked in sanity\n # MariaDB is check in nightly\n fail-fast: false\n\n steps:\n - uses: actions/checkout@v4\n\n - name: Setup Environment\n timeout-minutes: 15\n uses: ./.github/actions/setup-env\n with:\n PHP_VERSION: ${{ matrix.php }}\n ENABLE_SSL: 'true'\n INSTALL_AUTO: 'false'\n DB_SERVER: ${{ matrix.db }}\n\n - name: Setup Environment failure\n uses: ./.github/actions/setup-env-export-logs\n with:\n DOCKER_PREFIX: prestashop\n ARTIFACT_NAME: setup-sanity-${{ matrix.php }}-${{ matrix.browser }}-${{ matrix.db }}\n DB_SERVER: ${{ matrix.db }}\n ENABLE_SSL: 'true'\n INSTALL_AUTO: 'false'\n if: failure()\n\n - name: Run Tests\n uses: ./.github/actions/ui-test\n with:\n TEST_CAMPAIGN: ${{ env.TEST_CAMPAIGN }}\n BROWSER: ${{ matrix.browser }}\n DB_SERVER: ${{ matrix.db }}\n\n - name: Export docker logs\n if: failure()\n run: |\n mkdir -p ./var/docker-logs\n docker logs prestashop-${{ matrix.db }}-1 > ./var/docker-logs/${{ matrix.db }}.log\n docker logs prestashop-prestashop-git-1 > ./var/docker-logs/prestashop.log\n\n - name: Upload Screenshots and logs\n uses: actions/upload-artifact@v4\n if: failure()\n with:\n name: sanity-${{ matrix.php }}-${{ matrix.browser }}-${{ matrix.db }}\n path: |\n ./tests/UI/screenshots/\n ./var/logs\n ./var/docker-logs\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\sanity.yml
sanity.yml
YAML
2,695
0.8
0.03125
0.108434
node-utils
789
2024-07-27T11:42:30.227259
GPL-3.0
false
fde225311eb4034e8ffd730e615c1f91
name: Symfony Console\non:\n push:\n pull_request:\n\npermissions:\n contents: read\nconcurrency:\n group: ${{ github.event_name }}-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}\n cancel-in-progress: true\njobs:\n symfony-console:\n strategy:\n matrix:\n app-id: [ admin, admin-api, front ]\n fail-fast: false\n permissions:\n contents: read # for actions/checkout to fetch code\n name: Symfony Console\n runs-on: ubuntu-latest\n steps:\n - name: Setup PHP\n uses: shivammathur/setup-php@v2\n with:\n php-version: 8.1\n extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv\n env:\n GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n - uses: actions/checkout@v4\n\n - name: Get Composer Cache Directory\n id: composer-cache\n run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT\n\n - name: Cache Composer Directory\n uses: actions/cache@v4\n with:\n path: ${{ steps.composer-cache.outputs.dir }}\n key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}\n restore-keys: ${{ runner.os }}-composer-\n\n - name: Composer Install\n run: COMPOSER_PROCESS_TIMEOUT=600 composer install --ansi --prefer-dist --no-interaction --no-progress\n\n - name: Check bin/console can run without shop install and cache clear without app ID (only for admin job since it is the default value)\n if: matrix.app-id == 'admin'\n run: |\n ./bin/console\n ./bin/console cache:clear --env=dev\n ./bin/console cache:clear --env=prod\n ./bin/console cache:clear --env=dev --no-warmup\n ./bin/console cache:clear --env=prod --no-warmup\n\n - name: Check bin/console can run without shop install and cache clear for application ${{ matrix.app-id }}\n run: |\n ./bin/console --app-id=${{ matrix.app-id }}\n ./bin/console cache:clear --env=dev --app-id=${{ matrix.app-id }}\n ./bin/console cache:clear --env=prod --app-id=${{ matrix.app-id }}\n ./bin/console cache:clear --env=dev --no-warmup --app-id=${{ matrix.app-id }}\n ./bin/console cache:clear --env=prod --no-warmup --app-id=${{ matrix.app-id }}\n\n - name: Check app listeners for OAuth API\n if: matrix.app-id == 'admin-api'\n run: |\n apiListeners=$(./bin/console debug:event-dispatcher kernel.request --app-id=admin-api | grep 'PrestaShopBundle\\EventListener\\API' | wc -l)\n adminListeners=$(./bin/console debug:event-dispatcher kernel.request --app-id=admin-api | grep 'PrestaShopBundle\\EventListener\\Admin' | wc -l)\n echo $apiListeners API listeners detected\n echo $adminListeners Admin listeners detected\n if [ $adminListeners -ne 0 ]; then\n echo No admin listeners should be present\n exit 1\n fi\n if [ $apiListeners -eq 0 ]; then\n echo No API listeners detected\n exit 1\n fi\n\n - name: Check app listeners for Admin\n if: matrix.app-id == 'admin'\n run: |\n apiListeners=$(./bin/console debug:event-dispatcher kernel.request --app-id=admin | grep 'PrestaShopBundle\\EventListener\\API' | wc -l)\n adminListeners=$(./bin/console debug:event-dispatcher kernel.request --app-id=admin | grep 'PrestaShopBundle\\EventListener\\Admin' | wc -l)\n echo $apiListeners API listeners detected\n echo $adminListeners Admin listeners detected\n if [ $adminListeners -eq 0 ]; then\n echo No admin listeners detected\n exit 1\n fi\n if [ $apiListeners -ne 0 ]; then\n echo No API listeners should be present\n exit 1\n fi\n\n # Now install the shop\n - name: Setup Environment\n timeout-minutes: 15\n uses: ./.github/actions/setup-env\n with:\n PHP_VERSION: 8.1\n ENABLE_SSL: 'true'\n INSTALL_AUTO: 'false'\n - name: Setup Environment failure\n uses: ./.github/actions/setup-env-export-logs\n with:\n DOCKER_PREFIX: prestashop\n ARTIFACT_NAME: setup-symfony-console-${{ matrix.app-id }}\n ENABLE_SSL: 'true'\n INSTALL_AUTO: 'false'\n if: failure()\n\n # Retest the console after shop install\n - name: Check bin/console and cache:clear can run after shop install\n run: |\n docker exec prestashop-prestashop-git-1 php ./bin/console --app-id=${{ matrix.app-id }}\n docker exec prestashop-prestashop-git-1 php -d memory_limit=-1 ./bin/console cache:clear --env=dev --app-id=${{ matrix.app-id }}\n docker exec prestashop-prestashop-git-1 php -d memory_limit=-1 ./bin/console cache:clear --env=prod --app-id=${{ matrix.app-id }}\n docker exec prestashop-prestashop-git-1 php ./bin/console cache:clear --env=dev --no-warmup --app-id=${{ matrix.app-id }}\n docker exec prestashop-prestashop-git-1 php ./bin/console cache:clear --env=prod --no-warmup --app-id=${{ matrix.app-id }}\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\symfony-console.yml
symfony-console.yml
YAML
5,114
0.8
0.110169
0.018519
python-kit
944
2024-12-22T18:12:04.855944
Apache-2.0
false
4aaf73fabfa6e78f9e91a48fc51229a0
name: Twig\non:\n push:\n pull_request:\n\npermissions:\n contents: read\nconcurrency:\n group: ${{ github.event_name }}-${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}\n cancel-in-progress: true\n\njobs:\n twig-cs-check:\n name: Twig CS Check\n runs-on: ubuntu-latest\n\n steps:\n - name: Setup PHP\n uses: shivammathur/setup-php@v2\n with:\n extensions: mbstring, intl, gd, xml, dom, json, fileinfo, curl, zip, iconv, simplexml\n env:\n GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n\n - name: Checkout code\n uses: actions/checkout@v4\n\n - name: Get Composer Cache Directory\n id: composer-cache\n run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT\n\n - name: Cache Composer Directory\n uses: actions/cache@v4\n with:\n path: ${{ steps.composer-cache.outputs.dir }}\n key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}\n restore-keys: |\n ${{ runner.os }}-composer-\n\n - name: Composer Install\n run: COMPOSER_PROCESS_TIMEOUT=600 composer install --ansi --prefer-dist --no-interaction --no-progress\n\n - name: Run Twig CS Fixer Check\n run: |\n composer run twig || {\n echo "::error::Twig CS Fixer check failed. Run 'composer run twig:fix' to fix the issues.";\n exit 1;\n }\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\twig.yml
twig.yml
YAML
1,408
0.7
0
0
awesome-app
977
2025-05-18T18:23:41.296541
Apache-2.0
false
64d1ee4302c1798d28ec3d44310b8d5c
name: Verify 'Needs autoupgrade PR' label and approvals\n\non:\n pull_request_review:\n types: [ submitted ]\n\njobs:\n check_label_and_appoval:\n runs-on: ubuntu-latest\n steps:\n\n - name: Check if comment already exist\n id: check_comment\n env:\n GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n run: |\n PR_NUMBER=$(jq --raw-output .pull_request.number < $GITHUB_EVENT_PATH)\n COMMENTS=$(gh api repos/${{ github.repository }}/issues/$PR_NUMBER/comments --jq '.[].body')\n if echo "$COMMENTS" | grep -q "This means that the changes made in your PR must also be reported in the Autoupgrade module"; then\n echo "comment_exists=true" >> $GITHUB_ENV\n fi\n\n - name: Verify approvals and label\n id: check_approvals_and_labels\n if: ${{ !env.comment_exists }}\n env:\n GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n LABELS: Needs autoupgrade PR\n run: |\n PR_NUMBER=$(jq --raw-output .pull_request.number < $GITHUB_EVENT_PATH)\n\n APPROVAL_COUNT=$(gh api repos/${{ github.repository }}/pulls/$PR_NUMBER/reviews \\n --jq '[.[] | select(.state == "APPROVED")] | length')\n\n PR_AUTHOR=$(gh api repos/${{ github.repository }}/pulls/$PR_NUMBER --jq '.user.login')\n\n LABEL_PRESENT=$(gh api repos/${{ github.repository }}/issues/$PR_NUMBER/labels \\n --jq '[.[] | select(.name == "${{ env.LABELS }}")] | length')\n\n echo $APPROVAL_COUNT > ./approvals\n echo $LABEL_PRESENT > ./label\n echo $PR_NUMBER > ./pr_number\n echo $PR_AUTHOR > ./author\n\n - name: Upload\n uses: actions/upload-artifact@v4\n with:\n name: approval_count\n path: |\n approvals\n label\n pr_number\n author\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\verify_autoupgrade_label_and_approvals.yml
verify_autoupgrade_label_and_approvals.yml
YAML
1,838
0.7
0.056604
0
vue-tools
969
2023-08-20T05:41:19.665095
GPL-3.0
false
8654d1be4fda41c8346d76f84381de9e
# This workflow allows you to check potential changes to the structure of the database,\n# and to apply the “Needs autoupgrade PR” label if this is the case\nname: Verify diff for 'Needs autoupgrade PR' label\n\non:\n workflow_run:\n workflows: [ Create diff for 'Needs autoupgrade PR' label ]\n types:\n - completed\n\njobs:\n update_label:\n name: Update Needs autoupgrade PR label\n runs-on: ubuntu-latest\n steps:\n - name: Download artifact\n uses: actions/github-script@v6\n with:\n script: |\n let allArtifacts = await github.rest.actions.listWorkflowRunArtifacts({\n owner: context.repo.owner,\n repo: context.repo.repo,\n run_id: context.payload.workflow_run.id,\n });\n let matchArtifact = allArtifacts.data.artifacts.filter((artifact) => {\n return artifact.name == "sql_diff"\n })[0];\n let download = await github.rest.actions.downloadArtifact({\n owner: context.repo.owner,\n repo: context.repo.repo,\n artifact_id: matchArtifact.id,\n archive_format: 'zip',\n });\n let fs = require('fs');\n fs.writeFileSync(`${process.env.GITHUB_WORKSPACE}/sql_diff.zip`, Buffer.from(download.data));\n\n - name: Unzip artifact\n run: unzip sql_diff.zip\n\n - name: Check diff for label\n run: |\n NUMBER=$(cat ./pr_number)\n if [ -s sql-diff.txt ]; then\n gh pr edit "$NUMBER" --add-label "$LABELS"\n else\n gh pr edit "$NUMBER" --remove-label "$LABELS"\n fi\n env:\n GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n GH_REPO: ${{ github.repository }}\n LABELS: Needs autoupgrade PR\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\verify_diff_for_autoupgrade_pr_label.yml
verify_diff_for_autoupgrade_pr_label.yml
YAML
1,793
0.95
0.098039
0.042553
vue-tools
658
2025-02-17T13:21:05.847992
MIT
false
f1f46e1fbd0bd6d4a4e66588142c0b69
# This file is used by GitHub Actions.\nparameters:\n database_host: localhost\n database_port: ~\n database_name: prestashop\n database_user: root\n database_password: password\n database_prefix: ps_\n database_engine: InnoDB\n # You should uncomment this if you want use pdo_sqlite\n # database_path: "%kernel.project_dir%/data.db3"\n\n mailer_transport: smtp\n mailer_host: localhost\n mailer_user: ~\n mailer_password: ~\n\n # A secret key that's used to generate certain security-related tokens\n secret: ThisTokenIsNotSoSecretChangeIt\n ps_caching: CacheMemcache\n ps_cache_enable: true\n ps_creation_date: ~\n locale: en-US\n cookie_key: ThisTokenIsNotSoSecretChangeIt\n cookie_iv: ThisTokenIsNotSoSecretChangeIt\n\n use_debug_toolbar: false\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\phpunit\parameters.yml
parameters.yml
YAML
745
0.8
0.037037
0.166667
node-utils
578
2024-02-26T04:57:05.630985
MIT
false
4a616fea043668248ef9f9e64621d96e
extends: default\n\nignore: |\n /themes/classic/_dev/node_modules/\n /themes/node_modules/\n\nrules:\n braces:\n min-spaces-inside: 1\n max-spaces-inside: 1\n brackets:\n min-spaces-inside: 1\n max-spaces-inside: 1\n document-start: disable\n indentation:\n ## Check .editorconfig\n spaces: 2\n line-length: disable\n truthy: disable\n
dataset_sample\yaml\PrestaShop_PrestaShop\.github\workflows\yamllint\.yamllint.yml
.yamllint.yml
YAML
342
0.8
0
0.058824
python-kit
307
2024-06-10T12:18:51.801481
GPL-3.0
false
6f448f59f6036bd0abb23a7d5615a097
imports:\n - { resource: set_parameters.php }\n - { resource: services.yml }\n - { resource: addons/*.yml }\n - { resource: doctrine.yml }\n - { resource: messenger.yml }\n\n# Put parameters here that don't need to change on each machine where the app is deployed\n# http://symfony.com/doc/current/best_practices/configuration.html#application-related-configuration\nparameters:\n env(PS_THEME_NAME): "classic"\n translator.class: PrestaShopBundle\Translation\Translator\n translator.data_collector: PrestaShopBundle\Translation\DataCollectorTranslator\n prestashop_views: "%kernel.project_dir%/src/PrestaShopBundle/Resources/views"\n admin_page: "%prestashop_views%/Admin"\n env(PS_LOG_OUTPUT): "%kernel.logs_dir%/%kernel.environment%.log"\n env(PS_LOG_MAX_FILES): '30'\n env(PS_TRUSTED_PROXIES): ''\n mail_themes_uri: "/mails/themes"\n mail_themes_dir: "%kernel.project_dir%%mail_themes_uri%"\n modules_translation_paths: [ ]\n prestashop.controllers_all_shop_context:\n - AdminAccess\n - AdminFeatureFlag\n - AdminLanguages\n - AdminProfiles\n - AdminSpecificPriceRule\n - AdminStatuses\n - AdminSecurity\n - AdminSecuritySessionEmployee\n - AdminSecuritySessionCustomer\n - AdminTranslations\n\n# Autowires Core controllers\nservices:\n logger:\n alias: monolog.logger\n public: true\n\nframework:\n # proxies configuration, see https://symfony.com/doc/current/deployment/proxies.html\n trusted_proxies: '%env(PS_TRUSTED_PROXIES)%'\n\n assets:\n version: !php/const PrestaShop\PrestaShop\Core\Version::VERSION\n packages:\n front_js:\n base_path: '../js'\n\n # esi: ~\n secret: "%secret%"\n translator:\n fallbacks: [ "default" ]\n paths: "%modules_translation_paths%"\n form: ~\n csrf_protection: ~\n validation: { enable_attributes: true }\n serializer: { enable_attributes: true }\n default_locale: "%locale%"\n trusted_hosts: ~\n session:\n handler_id: ~\n fragments: ~\n http_method_override: true\n http_client: ~\n cache:\n pools:\n '%cache.driver%':\n adapter: '%cache.adapter%'\n\n# Monolog configuration\nmonolog:\n handlers:\n main:\n type: rotating_file\n max_files: '%env(PS_LOG_MAX_FILES)%'\n path: '%env(PS_LOG_OUTPUT)%'\n level: notice\n legacy:\n type: service\n id: prestashop.handler.log\n level: warning\n channels: [ app ]\n\n# Twig Configuration\ntwig:\n autoescape: "name"\n debug: "%kernel.debug%"\n strict_variables: "%kernel.debug%"\n exception_controller: null\n form_themes:\n - '@PrestaShop/Admin/TwigTemplateForm/bootstrap_4_horizontal_layout.html.twig'\n paths:\n '%admin_page%/TwigTemplateForm': Twig\n '%admin_page%/Common': Common\n '%admin_page%/Configure/AdvancedParameters': AdvancedParameters\n '%admin_page%/Configure/ShopParameters': ShopParameters\n '%kernel.project_dir%/modules': Modules\n '%mail_themes_dir%': MailThemes\n '%prestashop_views%': PrestaShopCore\n '%prestashop.admin_dir%/themes/new-theme': AdminNewTheme\n globals:\n ps: '@PrestaShopBundle\Twig\Layout\PrestaShopLayoutGlobalVariables'\n webpack_server: false\n multistore_field_prefix: !php/const PrestaShopBundle\Service\Form\MultistoreCheckboxEnabler::MULTISTORE_FIELD_PREFIX\n modify_all_shops_prefix: !php/const PrestaShopBundle\Form\Extension\ModifyAllShopsExtension::MODIFY_ALL_SHOPS_PREFIX\n disabling_switch_prefix: !php/const PrestaShopBundle\Form\Extension\DisablingSwitchExtension::FIELD_PREFIX\n\napi_platform:\n # API docs is disabled in the Admin environment, it is accessible via the oauth dedicated endpoint\n enable_docs: false\n enable_entrypoint: false\n enable_swagger: false\n enable_swagger_ui: false\n # We define mapping in this common config because even though the API routes are only accessible via the admin-api endpoint we still need\n # to parse the Api Platform resources to extract the scopes in the back-office\n mapping:\n paths:\n - '%kernel.project_dir%/src/PrestaShopBundle/ApiPlatform/Resources'\n
dataset_sample\yaml\PrestaShop_PrestaShop\app\config\config.yml
config.yml
YAML
3,954
0.95
0.008403
0.09009
vue-tools
381
2025-05-23T01:57:57.661051
MIT
false
550ed2912c430432a92c2196ca8e2795
imports:\n - { resource: config.yml }\n\nweb_profiler:\n toolbar: '%use_debug_toolbar%'\n intercept_redirects: false\n\nmonolog:\n handlers:\n main:\n type: rotating_file\n max_files: '%env(PS_LOG_MAX_FILES)%'\n path: '%env(PS_LOG_OUTPUT)%'\n level: debug\n channels: [ "!event" ]\n console:\n type: console\n bubble: false\n verbosity_levels:\n VERBOSITY_VERBOSE: INFO\n VERBOSITY_VERY_VERBOSE: DEBUG\n channels: [ "!doctrine" ]\n console_very_verbose:\n type: console\n bubble: false\n verbosity_levels:\n VERBOSITY_VERBOSE: NOTICE\n VERBOSITY_VERY_VERBOSE: NOTICE\n VERBOSITY_DEBUG: DEBUG\n channels: [ "doctrine" ]\n # uncomment to get logging in your browser\n # you may have to allow bigger header sizes in your Web server configuration\n # firephp:\n # type: firephp\n # level: info\n # chromephp:\n # type: chromephp\n # level: info\n\nprestashop:\n addons:\n api_client:\n ttl: 300 # 5min\n
dataset_sample\yaml\PrestaShop_PrestaShop\app\config\config_dev.yml
config_dev.yml
YAML
1,029
0.95
0
0.2
react-lib
294
2025-06-14T10:35:33.952446
GPL-3.0
false
6dca4219d02695752354ace7ddac68ee