Skip to content

Commit

Permalink
Stably sort embed refs
Browse files Browse the repository at this point in the history
Signed-off-by: Alex Weaver <[email protected]>
  • Loading branch information
alexweav committed Nov 2, 2023
1 parent 3c40c01 commit a5339f5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion scripts/compress_assets.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,5 +33,5 @@ if ! [[ -d "${dist}" ]]; then
fi

find dist -type f -name '*.gz' -delete
find dist -type f -exec gzip $GZIP_OPTS '{}' \; -print0 | xargs -0 -I % echo %.gz | xargs echo //go:embed >> embed.go
find dist -type f -exec gzip $GZIP_OPTS '{}' \; -print0 | xargs -0 -I % echo %.gz | sort | xargs echo //go:embed >> embed.go
echo var embedFS embed.FS >> embed.go
2 changes: 1 addition & 1 deletion ui/react-app/embed.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ package reactApp

import "embed"

//go:embed dist/732.js.gz dist/732.js.map.gz dist/26.js.map.gz dist/main.js.map.gz dist/main.js.gz dist/index.html.gz dist/26.js.gz
//go:embed dist/26.js.gz dist/26.js.map.gz dist/732.js.gz dist/732.js.map.gz dist/index.html.gz dist/main.js.gz dist/main.js.map.gz
var embedFS embed.FS

0 comments on commit a5339f5

Please sign in to comment.