Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AutoPR containerservice/mgmt/2016-09-30] [Mirror] [DO NOT MERGE] Compute 2019-07-01 version #362

Open
wants to merge 3 commits into
base: sdkAutomationPPE/containerservice_mgmt_2016-09-30
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
121 changes: 65 additions & 56 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
@@ -1,58 +1,67 @@
pool:
vmImage: 'Ubuntu 16.04'
jobs:
- job: Build_Test
strategy:
matrix:
Linux_Go112:
vm.image: 'ubuntu-18.04'
go.version: '1.12'
GOROOT: '/usr/local/go$(go.version)'
Linux_Go113:
vm.image: 'ubuntu-18.04'
go.version: '1.13'
GOROOT: '/usr/local/go$(go.version)'

variables:
GOROOT: '/usr/local/go1.12'
GOPATH: '$(system.defaultWorkingDirectory)/work'
sdkPath: '$(GOPATH)/src/github.com/$(build.repository.name)'
IGNORE_BREAKING_CHANGES: true
pool:
vmImage: $(vm.image)

steps:
- script: |
set -e
mkdir -p '$(GOPATH)/bin'
mkdir -p '$(sdkPath)'
shopt -s dotglob extglob
mv !(work) '$(sdkPath)'
echo '##vso[task.prependpath]$(GOROOT)/bin'
echo '##vso[task.prependpath]$(GOPATH)/bin'
displayName: 'Create Go Workspace'
- script: |
set -e
curl -sSL https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
dep ensure -v
go get -u golang.org/x/lint/golint
workingDirectory: '$(sdkPath)'
displayName: 'Install Dependencies'
- script: go vet $(go list ./... | grep -v vendor)
workingDirectory: '$(sdkPath)'
displayName: 'Vet'
- script: go build -v $(go list ./... | grep -v vendor)
workingDirectory: '$(sdkPath)'
displayName: 'Build'
- script: go test $(dirname $(find . -path ./vendor -prune -o -name '*_test.go' -print) | sort -u)
workingDirectory: '$(sdkPath)'
displayName: 'Run Tests'
- script: go run ./tools/apidiff/main.go packages ./services FETCH_HEAD~1 FETCH_HEAD --copyrepo --breakingchanges || $IGNORE_BREAKING_CHANGES
workingDirectory: '$(sdkPath)'
displayName: 'Display Breaking Changes'
- script: go run ./tools/pkgchk/main.go ./services --exceptions ./tools/pkgchk/exceptions.txt
workingDirectory: '$(sdkPath)'
displayName: 'Verify Package Directory'
- script: grep -L -r --include *.go --exclude-dir vendor -P "Copyright (\d{4}|\(c\)) Microsoft" ./ | tee >&2
workingDirectory: '$(sdkPath)'
displayName: 'Copyright Header Check'
failOnStderr: true
condition: succeededOrFailed()
- script: gofmt -s -l -w $(find . -path ./vendor -prune -o -name '*.go' -print) >&2
workingDirectory: '$(sdkPath)'
displayName: 'Format Check'
failOnStderr: true
condition: succeededOrFailed()
- script: |
golint ./storage/... >&2
golint ./tools/... >&2
workingDirectory: '$(sdkPath)'
displayName: 'Linter Check'
failOnStderr: true
condition: succeededOrFailed()
variables:
GOPATH: '$(system.defaultWorkingDirectory)/work'
sdkPath: '$(GOPATH)/src/github.com/Azure/azure-sdk-for-go'

steps:
- script: |
set -e
mkdir -p '$(GOPATH)/bin'
mkdir -p '$(sdkPath)'
shopt -s dotglob extglob
mv !(work) '$(sdkPath)'
echo '##vso[task.prependpath]$(GOROOT)/bin'
echo '##vso[task.prependpath]$(GOPATH)/bin'
displayName: 'Create Go Workspace'
- script: |
set -e
go version
curl -sSL https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
dep ensure -v
go get -u golang.org/x/lint/golint
workingDirectory: '$(sdkPath)'
displayName: 'Install Dependencies'
- script: go vet $(go list ./... | grep -v vendor)
workingDirectory: '$(sdkPath)'
displayName: 'Vet'
- script: go build -v $(go list ./... | grep -v vendor)
workingDirectory: '$(sdkPath)'
displayName: 'Build'
- script: go test $(dirname $(find . -path ./vendor -prune -o -name '*_test.go' -print) | sort -u)
workingDirectory: '$(sdkPath)'
displayName: 'Run Tests'
- script: go run ./tools/pkgchk/main.go ./services --exceptions ./tools/pkgchk/exceptions.txt
workingDirectory: '$(sdkPath)'
displayName: 'Verify Package Directory'
- script: grep -L -r --include *.go --exclude-dir vendor -P "Copyright (\d{4}|\(c\)) Microsoft" ./ | tee >&2
workingDirectory: '$(sdkPath)'
displayName: 'Copyright Header Check'
failOnStderr: true
condition: succeededOrFailed()
- script: gofmt -s -l -w $(find . -path ./vendor -prune -o -name '*.go' -print) >&2
workingDirectory: '$(sdkPath)'
displayName: 'Format Check'
failOnStderr: true
condition: succeededOrFailed()
- script: |
golint ./storage/... >&2
golint ./tools/... >&2
workingDirectory: '$(sdkPath)'
displayName: 'Linter Check'
failOnStderr: true
condition: succeededOrFailed()
95 changes: 95 additions & 0 deletions moduler-pipelines.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
pool:
vmImage: 'Ubuntu 18.04'

variables:
GOROOT: '/usr/local/go1.12'
GOPATH: '$(system.defaultWorkingDirectory)/work'
sdkPath: '$(GOPATH)/src/github.com/Azure/azure-sdk-for-go'

trigger:
batch: true
branches:
include:
- master

pr: none

steps:
- script: |
# Enable bash verbose logging
set -x
mkdir -p '$(GOPATH)/bin'
mkdir -p '$(sdkPath)'
shopt -s dotglob extglob
mv !(work) '$(sdkPath)'
echo '##vso[task.prependpath]$(GOROOT)/bin'
echo '##vso[task.prependpath]$(GOPATH)/bin'
displayName: 'Create Go Workspace'
- script: |
set -x
go version
curl -sSL https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
dep ensure -v
go get -u golang.org/x/lint/golint
workingDirectory: '$(sdkPath)'
displayName: 'Install Dependencies'
- script: |
# Echo error if github-pat is empty
[ -z $(github-pat) ] && echo "github-pat is empty!" && exit -1
echo $(Build.SourceBranchName)
# Enable bash verbose logging
set -x
git checkout $(Build.SourceBranchName)
git config user.email "azuresdkci@microsoft.com"
git config user.name "azuresdkci"
git config credential.helper store
echo https://$(github-pat):x-oauth-basic@github.com > ~/.git-credentials
displayName: 'Setup github'
workingDirectory: '$(sdkPath)'
- script: |
go generate ./profiles
gofmt -s -w ./profiles
workingDirectory: '$(sdkPath)'
displayName: 'Generate profiles'
- script: go vet $(go list ./... | grep -v vendor)
workingDirectory: '$(sdkPath)'
displayName: 'Vet'
- script: go build -v $(go list ./... | grep -v vendor)
workingDirectory: '$(sdkPath)'
displayName: 'Build'
- script: go test $(dirname $(find . -path ./vendor -prune -o -name '*_test.go' -print) | sort -u)
workingDirectory: '$(sdkPath)'
displayName: 'Run Tests'
- script: go run ./tools/pkgchk/main.go ./services --exceptions ./tools/pkgchk/exceptions.txt
workingDirectory: '$(sdkPath)'
displayName: 'Verify Package Directory'
- script: grep -L -r --include *.go --exclude-dir vendor -P "Copyright (\d{4}|\(c\)) Microsoft" ./ | tee >&2
workingDirectory: '$(sdkPath)'
displayName: 'Copyright Header Check'
failOnStderr: true
condition: succeededOrFailed()
- script: gofmt -s -l -w $(find . -path ./vendor -prune -o -name '*.go' -print) >&2
workingDirectory: '$(sdkPath)'
displayName: 'Format Check'
failOnStderr: true
condition: succeededOrFailed()
- script: |
golint ./storage/... >&2
golint ./tools/... >&2
workingDirectory: '$(sdkPath)'
displayName: 'Linter Check'
failOnStderr: true
condition: succeededOrFailed()
- script: |
# test if there are new profiles
if [ -z "$(git status --porcelain)" ]; then
echo no new profiles generated.
else
git commit -a -m "regenerated profiles"
git push origin $(Build.SourceBranchName)
fi
workingDirectory: '$(sdkPath)'
displayName: 'Push profiles'
- script: go run ./tools/moduler/main.go ./services -v
displayName: 'Detecting new tag and push'
workingDirectory: '$(sdkPath)'
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
No changes to exported content compared to the previous release.
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
module github.com/Azure/azure-sdk-for-go/services/containerservice/mgmt/2016-09-30/containerservice

go 1.12

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

13 changes: 7 additions & 6 deletions swagger_to_sdk_config.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
{
"$schema": "https://openapistorageprod.blob.core.windows.net/sdkautomation/prod/schemas/swagger_to_sdk_config.schema.json",
"meta": {
"after_scripts": [
"after_scripts_in_repo": [
"dep ensure",
"go generate ./profiles/generate.go",
"gofmt -w ./profiles/",
"go run ./tools/versioner/main.go ./services -v",
"gofmt -w ./services/"
],
"autorest_options": {
Expand All @@ -13,8 +12,10 @@
"verbose": "",
"sdkrel:go-sdk-folder": ".",
"multiapi": "",
"use-onever": "",
"preview-chk": ""
"preview-chk": "",
"go.clear-output-folder": false,
"stage": "",
"gomod-root": "github.com/Azure/azure-sdk-for-go"
},
"repotag": "azure-sdk-for-go",
"envs": {
Expand All @@ -27,4 +28,4 @@
},
"version": "0.2.0"
}
}
}
2 changes: 1 addition & 1 deletion tools/apidiff/repo/repo.go
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ func (wt WorkingTree) CreateTag(name string) error {

// ListTags calls "git tag -l <pattern>" to obtain the list of tags.
// If there are no tags the returned slice will have zero length.
// Tags are sorted in lexographic ascending order.
// Tags are sorted in lexicographic ascending order.
func (wt WorkingTree) ListTags(pattern string) ([]string, error) {
cmd := exec.Command("git", "tag", "-l", pattern)
cmd.Dir = wt.dir
Expand Down
Loading