-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Convert all projects to use Mage #9842
Conversation
}) | ||
} | ||
|
||
func (Test) Integ() error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
exported method Test.Integ should have comment or be unexported
}) | ||
} | ||
|
||
func (Test) Unit() error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
exported method Test.Unit should have comment or be unexported
|
||
type Test mg.Namespace | ||
|
||
func (Test) All() error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
exported method Test.All should have comment or be unexported
}) | ||
} | ||
|
||
type Test mg.Namespace |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
exported type Test should have comment or be unexported
Stage string | ||
} | ||
|
||
type Package mg.Namespace |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
exported type Package should have comment or be unexported
"update:fields", | ||
} | ||
|
||
func (Check) Targets() error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
exported method Check.Targets should have comment or be unexported
@@ -94,7 +172,372 @@ func addLicenseHeaders() error { | |||
) | |||
} | |||
|
|||
func (Check) Vet() error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
exported method Check.Vet should have comment or be unexported
|
||
type Check mg.Namespace | ||
|
||
// Check checks that code is formatted and generated files are up-to-date. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
comment on exported method Check.All should be of the form "All ..."
return mage.Clean(paths) | ||
} | ||
|
||
type Check mg.Namespace |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
exported type Check should have comment or be unexported
OutputFile: "build/distributions/dashboards/{{.Name}}-{{.Version}}{{if .Snapshot}}-SNAPSHOT{{end}}", | ||
// --- Targets --- | ||
|
||
func Clean() error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
exported function Clean should have comment or be unexported
Convert all projects to using Mage https://magefile.org for building. Generate the travis config based on what the root magefile specifies. Remove some unused scripts and files. Update jenkins scripts to use mage for testing. Add a mage docs target that generates docs and opens the browser when PREVIEW is set.
8e72c60
to
c3a6acb
Compare
} | ||
|
||
// BuildGoDaemon builds the go-daemon binary (use crossBuildGoDaemon). | ||
func BuildGoDaemon() error { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
func name will be used as build.BuildGoDaemon by other packages, and that stutters; consider calling this GoDaemon
// TODO: Add generators. | ||
} | ||
|
||
Aliases = map[string]interface{}{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
exported var Aliases should have comment or be unexported
@@ -6,6 +6,6 @@ REM | |||
REM After running this once you may invoke mage.exe directly. | |||
|
|||
WHERE mage | |||
IF %ERRORLEVEL% NEQ 0 go install github.com/ph/functionbeat/vendor/github.com/magefile/mage | |||
IF %ERRORLEVEL% NEQ 0 go install github.com/elastic/beats/vendor/github.com/magefile/mage |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🤦♂️
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change is great and I can't wait to get all this in. As usual to I will ask if we could split this up into multiple smaller PR's? I think there are quite a few changes in there that could happen separately to get it in quickly and make it more reviewable.
I hope most magefile commands could already be introduce by calling mage
from the make commands, for example for the docs and this could happen in separate PR's?
- name: check | ||
- name: test | ||
- name: crosscompile | ||
if: type != pull_request |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is the reason you do not want to have this on each PR?
@@ -1,3 +1,4 @@ | |||
--- |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could all the changes to k8s go into a separate PR?
@@ -0,0 +1,146 @@ | |||
# DO NOT EDIT - AUTO-GENERATED |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very nice. I hope we can also use this later on to generate the Jenkins Pipeline file or that the Pipeline file actually contains all this logic.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could this change also happen without mage?
@@ -0,0 +1,35 @@ | |||
// Licensed to Elasticsearch B.V. under one or more contributor |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Separate PR for changes in heartbeat?
Hi @andrewkroh, this PR seems to be stalled and quite out of date. Can we close this one? |
Convert all projects to use Mage https://magefile.org for building.
mage docs
target that generates docs and opens the browser when PREVIEW is set.TODO:
mage.BeatProjectType
.