mirror of https://github.com/jetkvm/kvm.git
chore: revert golangci-lint config and remove audio stub
- Revert .golangci.yml to dev branch state (removed custom build-tags) - Remove internal/audio/cgo_source_stub.go (not needed with proper cross-compilation) - Fix import ordering in ui/src/utils.ts Use 'make lint-go' for proper ARM cross-compilation environment.
This commit is contained in:
parent
68b1bc54ce
commit
450836daba
|
|
@ -1,12 +1,4 @@
|
||||||
version: "2"
|
version: "2"
|
||||||
run:
|
|
||||||
# JetKVM target: ARMv7 (Rockchip RK3308, Cortex-A7)
|
|
||||||
# NOTE: Run 'make lint-go' instead of 'golangci-lint run' directly
|
|
||||||
# Audio CGO code requires cross-compilation environment from Makefile
|
|
||||||
build-tags:
|
|
||||||
- netgo
|
|
||||||
- timetzdata
|
|
||||||
- nomsgpack
|
|
||||||
linters:
|
linters:
|
||||||
enable:
|
enable:
|
||||||
- forbidigo
|
- forbidigo
|
||||||
|
|
|
||||||
|
|
@ -1,50 +0,0 @@
|
||||||
//go:build !linux || (!arm && !arm64)
|
|
||||||
|
|
||||||
package audio
|
|
||||||
|
|
||||||
import "fmt"
|
|
||||||
|
|
||||||
// StubSource is a no-op implementation for platforms without CGO audio support
|
|
||||||
type StubSource struct {
|
|
||||||
direction string
|
|
||||||
alsaDevice string
|
|
||||||
}
|
|
||||||
|
|
||||||
// NewCgoOutputSource creates a stub audio source for output (unsupported platforms)
|
|
||||||
func NewCgoOutputSource(alsaDevice string) AudioSource {
|
|
||||||
return &StubSource{
|
|
||||||
direction: "output",
|
|
||||||
alsaDevice: alsaDevice,
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// NewCgoInputSource creates a stub audio source for input (unsupported platforms)
|
|
||||||
func NewCgoInputSource(alsaDevice string) AudioSource {
|
|
||||||
return &StubSource{
|
|
||||||
direction: "input",
|
|
||||||
alsaDevice: alsaDevice,
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Connect returns an error indicating CGO audio is not supported
|
|
||||||
func (s *StubSource) Connect() error {
|
|
||||||
return fmt.Errorf("CGO audio not supported on this platform")
|
|
||||||
}
|
|
||||||
|
|
||||||
// Disconnect is a no-op
|
|
||||||
func (s *StubSource) Disconnect() {}
|
|
||||||
|
|
||||||
// IsConnected returns false
|
|
||||||
func (s *StubSource) IsConnected() bool {
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
|
|
||||||
// ReadMessage returns an error
|
|
||||||
func (s *StubSource) ReadMessage() (uint8, []byte, error) {
|
|
||||||
return 0, nil, fmt.Errorf("CGO audio not supported on this platform")
|
|
||||||
}
|
|
||||||
|
|
||||||
// WriteMessage returns an error
|
|
||||||
func (s *StubSource) WriteMessage(msgType uint8, payload []byte) error {
|
|
||||||
return fmt.Errorf("CGO audio not supported on this platform")
|
|
||||||
}
|
|
||||||
|
|
@ -1,7 +1,6 @@
|
||||||
import { KeySequence } from "@hooks/stores";
|
import { KeySequence } from "@hooks/stores";
|
||||||
import { getLocale } from '@localizations/runtime.js';
|
import { getLocale , locales } from '@localizations/runtime.js';
|
||||||
import { m } from "@localizations/messages.js";
|
import { m } from "@localizations/messages.js";
|
||||||
import { locales } from '@localizations/runtime.js';
|
|
||||||
|
|
||||||
export const formatters = {
|
export const formatters = {
|
||||||
date: (date: Date, options?: Intl.DateTimeFormatOptions) =>
|
date: (date: Date, options?: Intl.DateTimeFormatOptions) =>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue