Skip to content

Commit

Permalink
Merge pull request #4220 from hashicorp/b-operator
Browse files Browse the repository at this point in the history
Generate all structs in structs packages
  • Loading branch information
dadgar committed Apr 26, 2018
2 parents e224e83 + 7fd28ce commit a305101
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 1 deletion.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ BUG FIXES:
[[GH-4216](https://github.com/hashicorp/nomad/issues/4216)]
* 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)]
* 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
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
Expand Down
3 changes: 3 additions & 0 deletions GNUmakefile
Original file line number Diff line number Diff line change
Expand Up @@ -261,6 +261,9 @@ clean: ## Remove build artifacts

.PHONY: travis
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"

.PHONY: testcluster
Expand Down
5 changes: 5 additions & 0 deletions nomad/structs/generate.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/bin/bash
set -e

FILES="$(ls *[!_test].go | tr '\n' ' ')"
codecgen -d 100 -o structs.generated.go ${FILES}
2 changes: 1 addition & 1 deletion nomad/structs/structs_codegen.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
package structs

//go:generate codecgen -d 100 -o structs.generated.go structs.go
//go:generate ./generate.sh

0 comments on commit a305101

Please sign in to comment.