-
Notifications
You must be signed in to change notification settings - Fork 93
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
52 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
load("@io_bazel_rules_go//go:def.bzl", "go_library") | ||
|
||
# Minify the logo into a favicon. | ||
genrule( | ||
name = "favicon", | ||
srcs = [":buildbarn_logo.svg"], | ||
outs = ["favicon.svg"], | ||
# Remove embedded draw.io content attribute and svg comments. | ||
cmd = "tr -d '\n' < $(location :buildbarn_logo.svg) | sed -e 's/ content=\"[^\"]*\"//' -e 's/<!--[^!]*-->//g' > $@", | ||
) | ||
|
||
go_library( | ||
name = "logo", | ||
srcs = ["logo.go"], | ||
embedsrcs = [ | ||
"favicon.svg", | ||
], | ||
importpath = "github.com/buildbarn/bb-storage/pkg/logo", | ||
visibility = ["//visibility:public"], | ||
) |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package logo | ||
|
||
import ( | ||
_ "embed" // For "go:embed". | ||
) | ||
|
||
//go:embed favicon.svg | ||
var faviconSvg []byte | ||
|
||
// FaviconSvg holds the Buildbarn logo and can be used as favicon in web browsers. | ||
var FaviconSvg = faviconSvg |