Skip to content

Commit

Permalink
Add Buildbarn logo svg
Browse files Browse the repository at this point in the history
  • Loading branch information
moroten committed Oct 20, 2023
1 parent ba53c0a commit ab5656d
Show file tree
Hide file tree
Showing 4 changed files with 52 additions and 0 deletions.
20 changes: 20 additions & 0 deletions pkg/logo/BUILD.bazel
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"],
)
Binary file added pkg/logo/buildbarn_logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
21 changes: 21 additions & 0 deletions pkg/logo/buildbarn_logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
11 changes: 11 additions & 0 deletions pkg/logo/logo.go
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

0 comments on commit ab5656d

Please sign in to comment.