mirror of
https://github.com/mudler/luet.git
synced 2025-09-03 08:14:46 +00:00
Use goreleaser to build and release (#244)
Instead of using gox on one side and an action to release, we can merge them together with goreleaser which will build for extra targets (arm, mips if needed in the future) and it also takes care of creating checksums, a source archive, and a changelog and creating a release with all the artifacts. All binaries should respect the old naming convention, so any scripts out there should still work. Signed-off-by: Itxaka <igarcia@suse.com>
This commit is contained in:
21
vendor/github.com/mitchellh/reflectwalk/reflectwalk.go
generated
vendored
21
vendor/github.com/mitchellh/reflectwalk/reflectwalk.go
generated
vendored
@@ -69,6 +69,13 @@ type PointerWalker interface {
|
||||
PointerExit(bool) error
|
||||
}
|
||||
|
||||
// PointerValueWalker implementations are notified with the value of
|
||||
// a particular pointer when a pointer is walked. Pointer is called
|
||||
// right before PointerEnter.
|
||||
type PointerValueWalker interface {
|
||||
Pointer(reflect.Value) error
|
||||
}
|
||||
|
||||
// SkipEntry can be returned from walk functions to skip walking
|
||||
// the value of this field. This is only valid in the following functions:
|
||||
//
|
||||
@@ -130,6 +137,17 @@ func walk(v reflect.Value, w interface{}) (err error) {
|
||||
}
|
||||
|
||||
if pointerV.Kind() == reflect.Ptr {
|
||||
if pw, ok := w.(PointerValueWalker); ok {
|
||||
if err = pw.Pointer(pointerV); err != nil {
|
||||
if err == SkipEntry {
|
||||
// Skip the rest of this entry but clear the error
|
||||
return nil
|
||||
}
|
||||
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
pointer = true
|
||||
v = reflect.Indirect(pointerV)
|
||||
}
|
||||
@@ -230,7 +248,8 @@ func walkMap(v reflect.Value, w interface{}) error {
|
||||
ew.Enter(MapValue)
|
||||
}
|
||||
|
||||
if err := walk(kv, w); err != nil {
|
||||
// get the map value again as it may have changed in the MapElem call
|
||||
if err := walk(v.MapIndex(k), w); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user