Merge pull request #4220 from hashicorp/b-operator

Generate all structs in structs packages
This commit is contained in:
Alex Dadgar 2018-04-26 15:26:17 -07:00 committed by GitHub
commit 8a128325f9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 11 additions and 1 deletions

View file

@ -15,6 +15,8 @@ BUG FIXES:
[[GH-4216](https://github.com/hashicorp/nomad/issues/4216)] [[GH-4216](https://github.com/hashicorp/nomad/issues/4216)]
* core: Improve tracking of node connections even if the address being used to * core: Improve tracking of node connections even if the address being used to
contact the server changes [[GH-4222](https://github.com/hashicorp/nomad/issues/4222)] contact the server changes [[GH-4222](https://github.com/hashicorp/nomad/issues/4222)]
* api: Fix an issue in which the autopilot configuration could not be updated
[GH-4220]
* client: Populate access time and modify time when unarchiving tar archives * client: Populate access time and modify time when unarchiving tar archives
that do not specify them explicitly [[GH-4217](https://github.com/hashicorp/nomad/issues/4217)] that do not specify them explicitly [[GH-4217](https://github.com/hashicorp/nomad/issues/4217)]
* driver/exec: Create process group for Windows process and send Ctrl-Break * driver/exec: Create process group for Windows process and send Ctrl-Break

View file

@ -261,6 +261,9 @@ clean: ## Remove build artifacts
.PHONY: travis .PHONY: travis
travis: ## Run Nomad test suites with output to prevent timeouts under Travis CI travis: ## Run Nomad test suites with output to prevent timeouts under Travis CI
@if [ ! $(SKIP_NOMAD_TESTS) ]; then \
make generate; \
fi
@sh -C "$(PROJECT_ROOT)/scripts/travis.sh" @sh -C "$(PROJECT_ROOT)/scripts/travis.sh"
.PHONY: testcluster .PHONY: testcluster

5
nomad/structs/generate.sh Executable file
View file

@ -0,0 +1,5 @@
#!/bin/bash
set -e
FILES="$(ls *[!_test].go | tr '\n' ' ')"
codecgen -d 100 -o structs.generated.go ${FILES}

View file

@ -1,3 +1,3 @@
package structs package structs
//go:generate codecgen -d 100 -o structs.generated.go structs.go //go:generate ./generate.sh