Commit Graph

9 Commits

Author SHA1 Message Date
Nic Cope 0c7b1eb549 Bump golangci-lint, copy config from c/c
This copies the latest config from c/c and addresses all the linter
errors that config produces.

Signed-off-by: Nic Cope <nicc@rk0n.org>
2024-02-20 03:45:27 -08:00
Nic Cope 3de55a4a72 Update module github.com/imdario/mergo to v1
Signed-off-by: Nic Cope <nicc@rk0n.org>
2023-06-22 00:26:15 -07:00
Aditya Sharma 1deb753676 s/interface{}/any/g
Signed-off-by: Aditya Sharma <git@adi.run>
2022-07-21 21:46:18 -07:00
Nic Cope af4e148a11 Replace github.com/pkg/errors with our own pkg/errors.
Signed-off-by: Nic Cope <negz@rk0n.org>
2021-09-09 07:50:57 +00:00
Alper Rifat Ulucinar 0127cd0781
Improve comments on fieldpath.merge
Signed-off-by: Alper Rifat Ulucinar <ulucinar@users.noreply.github.com>
2021-08-05 18:22:32 +03:00
Alper Rifat Ulucinar 4d6ec580be
Do not append duplicate slice elements when MergeOptions.AppendSlice is set
- Move resource.WithMergeOptions to core Crossplane and unexport
- Move fieldpath.object functions to core Crossplane and unexport
- Move fieldpath.MergeValue & related functions to its own file
- Add tests for fieldpath.MergeValue

Signed-off-by: Alper Rifat Ulucinar <ulucinar@users.noreply.github.com>
2021-08-04 21:38:43 +03:00
Alper Rifat Ulucinar e7b4a22e42
Add Paved.MargeValue method
- Add "fieldpath/object" package that deals with runtime.Objects
- Move MergeOptions struct to package "apis/common/v1".

Signed-off-by: Alper Rifat Ulucinar <ulucinar@users.noreply.github.com>
2021-08-02 14:19:03 +03:00
Alper Rifat Ulucinar fcbfd04067
Add tests for merge.go
- Add MergeReplace in fieldpath package for
  ease of writing tests.

Signed-off-by: Alper Rifat Ulucinar <ulucinar@users.noreply.github.com>
2021-08-02 14:19:02 +03:00
Alper Rifat Ulucinar 6f106aac89
Support merging in addition to replacing objects in patches
Signed-off-by: Alper Rifat Ulucinar <ulucinar@users.noreply.github.com>
2021-08-02 14:18:53 +03:00