Граф коммитов

4 Коммитов

Автор SHA1 Сообщение Дата
Dirkjan Bussink a56442af5c
Cleanup usage of go.rice in favor of go:embed (#10956)
* Cleanup usage of go.rice in favor of go:embed

The usage of go.rice predates the availability of go:embed, but we
should switch to using go:embed instead to ship specific assets like
config files that we need.

go.rice is also incompatible with Go 1.19 and while it might see a fix
in the future, it seems better to go with the recommended Go approach
that is available these days.

Signed-off-by: Dirkjan Bussink <d.bussink@gmail.com>

* Move vtctld to also use `go embed` instead of go.rice

Signed-off-by: Dirkjan Bussink <d.bussink@gmail.com>

* Remove last rice-box related comments

Signed-off-by: Dirkjan Bussink <d.bussink@gmail.com>

* Remove config moving

This right now breaks building the actual tests since the tests might
also end up loading the regular code which has a `go embed` and refers
to the package with the config embeds.

This doesn't mean that the config isn't properly included in the
binaries. Also with using `go embed` we have a build time dependency on
the files and we always know the latest is included, so we don't have
the issue of potentially outdated files either.

All in all, it seems simplest to remove this logic and trust that Go
itself works as advertised.

Signed-off-by: Dirkjan Bussink <d.bussink@gmail.com>
2022-08-09 14:15:19 +05:30
Rohit Nayak 6f728194fd
Unit test to confirm that the mysqlctl rice box is current (#10182)
* Unit test to confirm mysqlctl rice box is current

Signed-off-by: Rohit Nayak <rohit@planetscale.com>

* Test for all files in config directory

Signed-off-by: Rohit Nayak <rohit@planetscale.com>

* Flag rice box as generated file

Signed-off-by: Rohit Nayak <rohit@planetscale.com>

* Rename const per review comment

Signed-off-by: Rohit Nayak <rohit@planetscale.com>
2022-06-01 14:04:19 +02:00
Rohit Nayak 4fe8c36951
Hints to git cli and github diff to hide diffs in proto generated files by default (#10306)
* Tell both cli and github about generated proto files: hides diffs in 'git diff' in cli (but not in 'git status') and should improve not loading these files by default in github files diff

Signed-off-by: Rohit Nayak <rohit@planetscale.com>

* Move changes to root .gitattributes

Signed-off-by: Rohit Nayak <rohit@planetscale.com>

* Move changes to root .gitattributes

Signed-off-by: Rohit Nayak <rohit@planetscale.com>

* Add generated parser code

Signed-off-by: Rohit Nayak <rohit@planetscale.com>
2022-05-21 10:48:31 +02:00
doeg 4f9dbb4dfc
Mark web/vtadmin/src/proto/** as generated files in .gitattributes (#10303)
Signed-off-by: Sara Bee <855595+doeg@users.noreply.github.com>
2022-05-14 12:51:28 -04:00