mirror of
https://github.com/tailscale/tailscale.git
synced 2026-05-05 20:26:47 +02:00
QR codes are used by `tailscale up --qr` to provide an easy way to open a web-page without transcribing a difficult URI. However, there’s no need for this feature if the client will never be called interactively. So this PR adds the `ts_omit_qrcodes` build tag. Updates #18182 Signed-off-by: Simon Law <sfllaw@tailscale.com>
15 lines
371 B
Go
15 lines
371 B
Go
// Copyright (c) Tailscale Inc & AUTHORS
|
|
// SPDX-License-Identifier: BSD-3-Clause
|
|
|
|
//go:build !linux && !ts_omit_qrcodes
|
|
|
|
package qrcodes
|
|
|
|
import "io"
|
|
|
|
func detectFormat(w io.Writer, inverse bool) (Format, error) {
|
|
// Assume all terminals can support the full set of UTF-8 block
|
|
// characters: (█, ▀, ▄). See tailscale/tailscale#12935.
|
|
return FormatSmall, nil
|
|
}
|