Compare commits

...

55 Commits

Author SHA1 Message Date
dependabot[bot] 0515e78ab5 build(deps): bump golang.org/x/net from 0.17.0 to 0.23.0
Bumps [golang.org/x/net](https://github.com/golang/net) from 0.17.0 to 0.23.0.
- [Commits](https://github.com/golang/net/compare/v0.17.0...v0.23.0)

---
updated-dependencies:
- dependency-name: golang.org/x/net
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-04-19 16:18:35 +02:00
renovate[bot] cf47a5d77a module: update module github.com/stretchr/testify to v1.9.0 2024-03-14 09:59:28 +01:00
renovate[bot] 7670aeb280 ci: update actions/setup-go action to v5 2023-12-08 09:14:37 +01:00
dependabot[bot] e17644b015 build(deps): bump golang.org/x/net from 0.8.0 to 0.17.0
Bumps [golang.org/x/net](https://github.com/golang/net) from 0.8.0 to 0.17.0.
- [Commits](https://github.com/golang/net/compare/v0.8.0...v0.17.0)

---
updated-dependencies:
- dependency-name: golang.org/x/net
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-10-17 12:36:31 +02:00
renovate[bot] 451b9544e1 ci: update actions/checkout action to v4 2023-09-07 08:51:24 +02:00
renovate[bot] 4b16705cdb module: update module github.com/eclipse/paho.mqtt.golang to v1.4.3 2023-07-13 08:46:19 +02:00
renovate[bot] 82f2ca35af module: update module github.com/stretchr/testify to v1.8.4 2023-06-01 08:50:55 +02:00
renovate[bot] 065c578982 ci: update actions/setup-go action to v4 2023-03-16 08:58:49 +01:00
renovate[bot] 391baa4d06 module: update module github.com/stretchr/testify to v1.8.2 2023-03-02 09:10:40 +01:00
renovate[bot] 7cb36807ef module: update module github.com/stretchr/testify to v1.8.1 2023-02-23 09:50:28 +01:00
cn 4fce9d222e module: update deps 2023-02-21 12:48:48 +01:00
Christian Nicolai 36d6563db0
ci: test Go 1.20 2023-02-03 10:56:44 +01:00
cn 0089a3dd2c module: bump minimum Go version to 1.19 2022-08-03 16:44:46 +02:00
renovate[bot] d5020103f3 module: update module github.com/stretchr/testify to v1.8.0 2022-06-30 08:53:25 +02:00
renovate[bot] 1ee6adbf42 module: update module github.com/stretchr/testify to v1.7.5 2022-06-30 08:45:54 +02:00
renovate[bot] 15c187f3d8 module: update module github.com/stretchr/testify to v1.7.4 2022-06-23 08:12:36 +02:00
Renovate Bot 4a635752d8 module: update module github.com/eclipse/paho.mqtt.golang to v1.4.1 2022-06-10 10:43:04 +02:00
Renovate Bot 2e9361ceea module: update module github.com/stretchr/testify to v1.7.2 2022-06-09 08:27:11 +02:00
Christian Nicolai fcc9cd18e7 ci: add actionlint 2022-05-04 20:32:51 +02:00
Renovate Bot 36cb063a42 ci: update actions/setup-go action to v3 2022-05-04 20:29:14 +02:00
Renovate Bot 9781213858 ci: update actions/checkout action to v3 2022-05-04 20:28:30 +02:00
Christian Nicolai 21f139d3cc module: switch to Renovate again 2022-05-04 20:25:51 +02:00
cn 72c4c94cb7 module: bump minimum Go version to 1.18 and use debug.ReadBuildInfo() 2022-03-18 00:21:53 +01:00
dependabot[bot] 0268126d70
module: update github.com/stretchr/testify to version 1.7.1
Bumps [github.com/stretchr/testify](https://github.com/stretchr/testify) from 1.7.0 to 1.7.1 (#72).
- [Release notes](https://github.com/stretchr/testify/releases)
- [Commits](https://github.com/stretchr/testify/compare/v1.7.0...v1.7.1)

---
updated-dependencies:
- dependency-name: github.com/stretchr/testify
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-03-17 15:17:23 +01:00
cn 23c2371649 module: bump minimum Go version to 1.17 2022-01-07 12:07:14 +01:00
dependabot[bot] fb076d3a66
module: update github.com/eclipse/paho.mqtt.golang to version 1.3.5
Bumps [github.com/eclipse/paho.mqtt.golang](https://github.com/eclipse/paho.mqtt.golang) from 1.3.4 to 1.3.5 (#71).
- [Release notes](https://github.com/eclipse/paho.mqtt.golang/releases)
- [Commits](https://github.com/eclipse/paho.mqtt.golang/compare/v1.3.4...v1.3.5)

---
updated-dependencies:
- dependency-name: github.com/eclipse/paho.mqtt.golang
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-06-10 16:23:08 +02:00
dependabot[bot] 717496be57
module: update github.com/eclipse/paho.mqtt.golang to version 1.3.4
Bumps [github.com/eclipse/paho.mqtt.golang](https://github.com/eclipse/paho.mqtt.golang) from 1.3.3 to 1.3.4 (#70).
- [Release notes](https://github.com/eclipse/paho.mqtt.golang/releases)
- [Commits](https://github.com/eclipse/paho.mqtt.golang/compare/v1.3.3...v1.3.4)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-05-06 15:01:17 +02:00
cn f995734bc9 module: bump minimum Go version to 1.16 2021-04-05 21:48:44 +02:00
dependabot[bot] e8c1b0b37e
module: update github.com/eclipse/paho.mqtt.golang to version 1.3.3
Bumps [github.com/eclipse/paho.mqtt.golang](https://github.com/eclipse/paho.mqtt.golang) from 1.3.2 to 1.3.3. (#69)
- [Release notes](https://github.com/eclipse/paho.mqtt.golang/releases)
- [Commits](https://github.com/eclipse/paho.mqtt.golang/compare/v1.3.2...v1.3.3)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-04-01 14:06:54 +02:00
dependabot[bot] 5530c139f4
module: update github.com/eclipse/paho.mqtt.golang to version 1.3.2
Bumps [github.com/eclipse/paho.mqtt.golang](https://github.com/eclipse/paho.mqtt.golang) from 1.3.1 to 1.3.2 (#68).
- [Release notes](https://github.com/eclipse/paho.mqtt.golang/releases)
- [Commits](https://github.com/eclipse/paho.mqtt.golang/compare/v1.3.1...v1.3.2)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-02-11 15:59:55 +01:00
dependabot[bot] 092f2c747c
module: update github.com/stretchr/testify to version 1.7.0
Bumps [github.com/stretchr/testify](https://github.com/stretchr/testify) from 1.6.1 to 1.7.0 (#67).
- [Release notes](https://github.com/stretchr/testify/releases)
- [Commits](https://github.com/stretchr/testify/compare/v1.6.1...v1.7.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-01-14 16:10:21 +01:00
dependabot[bot] fb5b12df53
module: update github.com/eclipse/paho.mqtt.golang to version 1.3.1
Bumps [github.com/eclipse/paho.mqtt.golang](https://github.com/eclipse/paho.mqtt.golang) from 1.3.0 to 1.3.1 (#66).
- [Release notes](https://github.com/eclipse/paho.mqtt.golang/releases)
- [Commits](https://github.com/eclipse/paho.mqtt.golang/compare/v1.3.0...v1.3.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-12-31 14:05:07 +01:00
dependabot[bot] f05b4e8105 module: update github.com/eclipse/paho.mqtt.golang to version 1.3.0
Bumps [github.com/eclipse/paho.mqtt.golang](https://github.com/eclipse/paho.mqtt.golang) from 1.2.0 to 1.3.0.
- [Release notes](https://github.com/eclipse/paho.mqtt.golang/releases)
- [Commits](https://github.com/eclipse/paho.mqtt.golang/compare/v1.2.0...v1.3.0)

Signed-off-by: dependabot[bot] <support@github.com>
2020-12-10 14:15:32 +01:00
cn 5508b0dff3 miflorad: fix some linter errors 2020-12-06 13:18:48 +01:00
cn a6d6a14149 module: bump minimum Go version to 1.15 2020-12-06 13:18:04 +01:00
cn ecab1a41f5 module: refactor Makefile, add help 2020-08-30 20:42:58 +02:00
cn 1a0a661fab ci: update go versions and github actions 2020-08-21 16:53:56 +02:00
dependabot[bot] 898dcfed50
module: update github.com/stretchr/testify to version 1.6.1
Bumps [github.com/stretchr/testify](https://github.com/stretchr/testify) from 1.6.0 to 1.6.1 (#63).
- [Release notes](https://github.com/stretchr/testify/releases)
- [Commits](https://github.com/stretchr/testify/compare/v1.6.0...v1.6.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-06-11 14:47:10 +02:00
dependabot[bot] a7c8b40a4c
module: update github.com/stretchr/testify to version 1.6.0
Bumps [github.com/stretchr/testify](https://github.com/stretchr/testify) from 1.5.1 to 1.6.0 (#62).
- [Release notes](https://github.com/stretchr/testify/releases)
- [Commits](https://github.com/stretchr/testify/compare/v1.5.1...v1.6.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-06-05 08:45:23 +02:00
dependabot-preview[bot] 40e165a045
module: add Dependabot config file v2
Create Dependabot config file (#61)

Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Christian Nicolai <cn@mycrobase.de>
2020-06-05 08:14:56 +02:00
dependabot-preview[bot] 29d172d3e0
module: update github.com/stretchr/testify to 1.5.1
Bumps [github.com/stretchr/testify](https://github.com/stretchr/testify) from 1.4.0 to 1.5.1 (#59).
- [Release notes](https://github.com/stretchr/testify/releases)
- [Commits](https://github.com/stretchr/testify/compare/v1.4.0...v1.5.1)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-02-20 15:53:22 +01:00
cn 4ce572c0f6 module: add asdf .tool-versions 2020-01-24 16:00:37 +01:00
cn c20f510c8c module: update go-ble/ble and tidy 2020-01-20 19:42:21 +01:00
Renovate Bot 4b00f1ed0e module: update module pkg/errors to v0.9.1 2020-01-15 15:19:25 +01:00
cn ba77404d7f ci: use github actions 2019-12-21 10:09:59 +01:00
renovate[bot] 1bbaa6f6e1 module: update golang.org/x/net commit hash to c5a3c61
Update golang.org/x/net commit hash to c5a3c61 (#52)
2019-10-01 07:29:54 +02:00
renovate[bot] e91aa7be92 module: update module mattn/go-colorable to v0.1.4
Update module mattn/go-colorable to v0.1.4 (#51)
2019-09-30 20:00:25 +02:00
cn 97164bc4b8 module: support Go 1.13 2019-09-04 19:29:14 +02:00
renovate[bot] 9e0f892b23 module: update module mattn/go-isatty to v0.0.9
Update module mattn/go-isatty to v0.0.9 (#49)
2019-08-16 07:43:42 +02:00
renovate[bot] b5d9a412b2 module: update module stretchr/testify to v1.4.0
Update module stretchr/testify to v1.4.0 (#48)
2019-08-15 18:11:12 +02:00
cn 72e47578bb module: don't use proxy, fix timestamps as Go 1.13 starts validating them 2019-07-08 09:22:02 +02:00
renovate[bot] 22f796f22a module: update golang.org/x/net commit hash to da137c7
Update golang.org/x/net commit hash to da137c7 (#45)
2019-07-02 08:51:12 +02:00
renovate[bot] 161f07ed5b module: update github.com/coreos/go-systemd commit hash to e64a0ec
Update github.com/coreos/go-systemd commit hash to e64a0ec (#44)
2019-07-02 08:50:50 +02:00
cn 86ae169404 module: disable Go master Travis CI builds saving resources 2019-07-02 08:38:20 +02:00
renovate[bot] b848e814e3 module: update golang.org/x/net commit hash to f3200d1 (#43) 2019-06-01 10:19:05 +02:00
13 changed files with 254 additions and 142 deletions

17
.github/actionlint-matcher.json vendored Normal file
View File

@ -0,0 +1,17 @@
{
"problemMatcher": [
{
"owner": "actionlint",
"pattern": [
{
"regexp": "^(?:\\x1b\\[\\d+m)?(.+?)(?:\\x1b\\[\\d+m)*:(?:\\x1b\\[\\d+m)*(\\d+)(?:\\x1b\\[\\d+m)*:(?:\\x1b\\[\\d+m)*(\\d+)(?:\\x1b\\[\\d+m)*: (?:\\x1b\\[\\d+m)*(.+?)(?:\\x1b\\[\\d+m)* \\[(.+?)\\]$",
"file": 1,
"line": 2,
"column": 3,
"message": 4,
"code": 5
}
]
}
]
}

44
.github/renovate.json5 vendored Normal file
View File

@ -0,0 +1,44 @@
{
extends: [
"config:base",
":dependencyDashboard",
":prHourlyLimitNone",
":prConcurrentLimitNone",
":label(dependency-upgrade)",
],
schedule: ["before 8am on thursday"],
branchPrefix: "renovate-",
dependencyDashboardHeader: "View repository job log [here](https://app.renovatebot.com/dashboard#github/cmur2/miflorad).",
separateMinorPatch: true,
commitMessagePrefix: "module: ",
commitMessageAction: "update",
commitMessageTopic: "{{depName}}",
commitMessageExtra: "to {{#if isSingleVersion}}v{{{newVersion}}}{{else}}{{{newValue}}}{{/if}}",
packageRules: [
// Commit message formats
{
matchManagers: ["github-actions"],
commitMessagePrefix: "ci: ",
},
// less noisy updates
{
packageNames: [
"github.com/currantlabs/gatt",
"github.com/muka/ble",
"github.com/muka/go-bluetooth",
],
extends: ["schedule:weekly"],
},
{
packageNames: [
"github.com/coreos/go-systemd",
"github.com/mgutz/ansi",
"github.com/mgutz/logxi",
"golang.org/x/net",
],
extends: ["schedule:monthly"],
},
],
regexManagers: [],
}

40
.github/workflows/ci.yml vendored Normal file
View File

@ -0,0 +1,40 @@
---
name: ci
on:
push:
schedule:
- cron: '3 4 * * 4' # weekly on thursday morning
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
go:
- '1.19'
- '1.20'
fail-fast: false
env:
GO111MODULE: on
GOPROXY: direct
GOSUMDB: off
steps:
- uses: actions/checkout@v4
- name: Set up Go ${{ matrix.go }}
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go }}
- name: Build
run: |
make
actionlint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Check workflow files
run: |
echo "::add-matcher::.github/actionlint-matcher.json"
bash <(curl https://raw.githubusercontent.com/rhysd/actionlint/main/scripts/download-actionlint.bash)
./actionlint

1
.tool-versions Normal file
View File

@ -0,0 +1 @@
github-release 1.0

View File

@ -1,10 +0,0 @@
---
sudo: false
language: go
go:
- "1.11.x"
- "1.12.x"
- master
env:
- GO111MODULE=on

View File

@ -1,4 +1,13 @@
.POSIX:
# https://tech.davis-hansson.com/p/make/
SHELL := bash
.ONESHELL:
.SHELLFLAGS := -eux -o pipefail -c
.DELETE_ON_ERROR:
.SILENT:
.DEFAULT_GOAL := all
MAKEFLAGS += --warn-undefined-variables
MAKEFLAGS += --no-builtin-rules
MIFLORA_ADDR?=00:00:00:00:00:00 MIFLORA_ADDR?=00:00:00:00:00:00
MIFLORAD_VERSION?=master MIFLORAD_VERSION?=master
@ -7,49 +16,64 @@ RUN_COMMAND=miflorad
RUN_OPTIONS=$(MIFLORA_ADDR) RUN_OPTIONS=$(MIFLORA_ADDR)
.PHONY: all .PHONY: all
all: clean build test all: clean build test ## Run clean, build and test (default goal)
.PHONY: run .PHONY: run
run: clean build test run: clean build test ## Run clean, build, test and finally launch the $RUN_COMMAND as root
sudo cmd/$(RUN_COMMAND)/$(RUN_COMMAND) $(RUN_OPTIONS) sudo cmd/$(RUN_COMMAND)/$(RUN_COMMAND) $(RUN_OPTIONS)
.PHONY: clean .PHONY: clean
clean: clean: ## Remove all produced executables
rm -f cmd/miflorad/miflorad rm -f cmd/miflorad/miflorad
rm -f cmd/munin-miflora/munin-miflora rm -f cmd/munin-miflora/munin-miflora
rm -f cmd/munin-miflora-gatt/munin-miflora-gatt rm -f cmd/munin-miflora-gatt/munin-miflora-gatt
.PHONY: build .PHONY: build
build: cmd/miflorad/miflorad cmd/munin-miflora/munin-miflora cmd/munin-miflora-gatt/munin-miflora-gatt build: cmd/miflorad/miflorad cmd/munin-miflora/munin-miflora cmd/munin-miflora-gatt/munin-miflora-gatt ## Build all produced executables
.PHONY: test .PHONY: test
test: build test: build ## Run all tests
cd cmd/miflorad && go test -v -race && cd ../.. pushd cmd/miflorad
cd common && go test -v -race && cd .. go test -v -race
popd
pushd common
go test -v -race
popd
.PHONY: remote-run .PHONY: remote-run
remote-run: clean remote-run: clean ## Run clean, build $RUN_COMMAND for Linux on ARM and launch it via SSH on extzero
cd cmd/$(RUN_COMMAND) && CGO_ENABLED=0 GOOS=linux GOARCH=arm go build -ldflags="-s -w" && cd ../.. pushd cmd/$(RUN_COMMAND)
CGO_ENABLED=0 GOOS=linux GOARCH=arm go build -ldflags="-s -w"
popd
file cmd/$(RUN_COMMAND)/$(RUN_COMMAND) file cmd/$(RUN_COMMAND)/$(RUN_COMMAND)
scp cmd/$(RUN_COMMAND)/$(RUN_COMMAND) extzero:$(RUN_COMMAND) scp cmd/$(RUN_COMMAND)/$(RUN_COMMAND) extzero:$(RUN_COMMAND)
ssh extzero "./$(RUN_COMMAND) $(RUN_OPTIONS)" ssh extzero "./$(RUN_COMMAND) $(RUN_OPTIONS)"
.PHONY: release .PHONY: release
release: release: ## Build and upload release version of miflorad to Github
mkdir -p pkg mkdir -p pkg
cd cmd/miflorad && CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o "../../pkg/miflorad-$(MIFLORAD_VERSION)-linux-amd64" -ldflags="-s -w -X main.version=$(MIFLORAD_VERSION)" && cd ../.. pushd cmd/miflorad
cd cmd/miflorad && CGO_ENABLED=0 GOOS=linux GOARCH=arm go build -o "../../pkg/miflorad-$(MIFLORAD_VERSION)-linux-arm" -ldflags="-s -w -X main.version=$(MIFLORAD_VERSION)" && cd ../.. CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o "../../pkg/miflorad-$(MIFLORAD_VERSION)-linux-amd64" -ldflags="-s -w"
CGO_ENABLED=0 GOOS=linux GOARCH=arm go build -o "../../pkg/miflorad-$(MIFLORAD_VERSION)-linux-arm" -ldflags="-s -w"
popd
# github-release "v$(MIFLORAD_VERSION)" pkg/miflorad-$(MIFLORAD_VERSION)-* --commit "master" --tag "v$(MIFLORAD_VERSION)" --prerelease --github-repository "cmur2/miflorad" # github-release "v$(MIFLORAD_VERSION)" pkg/miflorad-$(MIFLORAD_VERSION)-* --commit "master" --tag "v$(MIFLORAD_VERSION)" --prerelease --github-repository "cmur2/miflorad"
github-release "v$(MIFLORAD_VERSION)" pkg/miflorad-$(MIFLORAD_VERSION)-* --commit "master" --tag "v$(MIFLORAD_VERSION)" --github-repository "cmur2/miflorad" github-release "v$(MIFLORAD_VERSION)" pkg/miflorad-$(MIFLORAD_VERSION)-* --commit "master" --tag "v$(MIFLORAD_VERSION)" --github-repository "cmur2/miflorad"
.PHONY: cmd/miflorad/miflorad .PHONY: cmd/miflorad/miflorad
cmd/miflorad/miflorad: cmd/miflorad/miflorad:
cd cmd/miflorad && CGO_ENABLED=0 go build -buildmode=pie -ldflags "-X main.version=$(MIFLORAD_VERSION)" && cd ../.. pushd cmd/miflorad
CGO_ENABLED=0 go build -buildmode=pie
.PHONY: cmd/munin-miflora/munin-miflora .PHONY: cmd/munin-miflora/munin-miflora
cmd/munin-miflora/munin-miflora: cmd/munin-miflora/munin-miflora:
cd cmd/munin-miflora && CGO_ENABLED=0 go build -buildmode=pie && cd ../.. pushd cmd/munin-miflora
CGO_ENABLED=0 go build -buildmode=pie
.PHONY: cmd/munin-miflora-gatt/munin-miflora-gatt .PHONY: cmd/munin-miflora-gatt/munin-miflora-gatt
cmd/munin-miflora-gatt/munin-miflora-gatt: cmd/munin-miflora-gatt/munin-miflora-gatt:
cd cmd/munin-miflora-gatt && CGO_ENABLED=0 go build -buildmode=pie && cd ../.. pushd cmd/munin-miflora-gatt
CGO_ENABLED=0 go build -buildmode=pie
.PHONY: help
help: ## Print this help text
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-15s\033[0m %s\n", $$1, $$2}'

View File

@ -1,6 +1,6 @@
# miflorad # miflorad
[![Build Status](https://travis-ci.org/cmur2/miflorad.svg?branch=master)](https://travis-ci.org/cmur2/miflorad) ![Build Status](https://github.com/cmur2/miflorad/workflows/ci/badge.svg)
This project aims to produce tools written in Go for interfacing with Xiaomi Flora sensors for IoT use cases. This project aims to produce tools written in Go for interfacing with Xiaomi Flora sensors for IoT use cases.

View File

@ -21,9 +21,6 @@ import (
const mqttConnectTimeout = 10 * time.Second const mqttConnectTimeout = 10 * time.Second
// program version, will be populated on build
var version string
var ( var (
scanTimeout = flag.Duration("scantimeout", 10*time.Second, "timeout after that a scan per peripheral will be aborted") scanTimeout = flag.Duration("scantimeout", 10*time.Second, "timeout after that a scan per peripheral will be aborted")
readRetries = flag.Int("readretries", 2, "number of times reading will be attempted per peripheral") readRetries = flag.Int("readretries", 2, "number of times reading will be attempted per peripheral")
@ -94,21 +91,14 @@ func checkTooShortInterval() error {
numPeripherals := int64(len(flag.Args())) numPeripherals := int64(len(flag.Args()))
numReadRetries := int64(*readRetries) numReadRetries := int64(*readRetries)
if (*scanTimeout).Nanoseconds()*numReadRetries*numPeripherals >= (*interval).Nanoseconds() { if (*scanTimeout).Nanoseconds()*numReadRetries*numPeripherals >= (*interval).Nanoseconds() {
return errors.New(fmt.Sprintf( return errors.Errorf(
"The interval of %s is too short given the scan timeout of %s for %d peripheral(s) with %d retries each! Exiting...\n", "The interval of %s is too short given the scan timeout of %s "+
*interval, *scanTimeout, numPeripherals, *readRetries)) "for %d peripheral(s) with %d retries each! Exiting...\n",
*interval, *scanTimeout, numPeripherals, *readRetries)
} }
return nil return nil
} }
func getVersion() string {
if version == "" {
return "dev"
} else {
return version
}
}
func getMQTTOptions() *mqtt.ClientOptions { func getMQTTOptions() *mqtt.ClientOptions {
if *brokerUseTLS { if *brokerUseTLS {
return mqtt.NewClientOptions(). return mqtt.NewClientOptions().
@ -156,7 +146,7 @@ func connectPeripheral(peripheral *peripheral, send chan mifloraMetric) error {
foundAdvertisementChannel := make(chan ble.Advertisement, 1) foundAdvertisementChannel := make(chan ble.Advertisement, 1)
filter := func(adv ble.Advertisement) bool { filter := func(adv ble.Advertisement) bool {
if strings.ToUpper(adv.Addr().String()) == strings.ToUpper(peripheral.id) { if strings.EqualFold(adv.Addr().String(), peripheral.id) {
foundAdvertisementChannel <- adv foundAdvertisementChannel <- adv
return true return true
} }
@ -194,7 +184,7 @@ func connectPeripheral(peripheral *peripheral, send chan mifloraMetric) error {
timeReadoutTook := time.Since(timeReadoutStart).Seconds() timeReadoutTook := time.Since(timeReadoutStart).Seconds()
client.CancelConnection() err3 := client.CancelConnection()
<-done <-done
@ -202,6 +192,10 @@ func connectPeripheral(peripheral *peripheral, send chan mifloraMetric) error {
return errors.Wrap(err2, "can't read data") return errors.Wrap(err2, "can't read data")
} }
if err3 != nil {
return errors.Wrap(err3, "can't disconnect after reading data")
}
send <- mifloraDataMetric{ send <- mifloraDataMetric{
peripheralId: common.MifloraGetAlphaNumericID(peripheral.id), peripheralId: common.MifloraGetAlphaNumericID(peripheral.id),
sensorData: sensorData, sensorData: sensorData,
@ -253,7 +247,8 @@ func readAllPeripherals(quit chan struct{}, send chan mifloraMetric) {
func main() { func main() {
flag.Parse() flag.Parse()
if len(flag.Args()) < 1 { if len(flag.Args()) < 1 {
fmt.Fprintf(os.Stderr, "Usage: %s [options] peripheral-id [peripheral-ids...] \n", os.Args[0]) fmt.Fprintf(os.Stderr,
"Usage: %s [options] peripheral-id [peripheral-ids...] \n", os.Args[0])
flag.PrintDefaults() flag.PrintDefaults()
os.Exit(1) os.Exit(1)
} }
@ -270,7 +265,8 @@ func main() {
case "influx": case "influx":
format = influxFormat format = influxFormat
default: default:
fmt.Fprintf(os.Stderr, "Unrecognized publish format %s! Exiting...\n", *publishFormatFlag) fmt.Fprintf(os.Stderr, "Unrecognized publish format %s! Exiting...\n",
*publishFormatFlag)
os.Exit(1) os.Exit(1)
} }

21
cmd/miflorad/version.go Normal file
View File

@ -0,0 +1,21 @@
package main
import (
"runtime/debug"
)
func getVersion() string {
info, ok := debug.ReadBuildInfo()
if !ok {
return "unknown"
}
for _, kv := range info.Settings {
switch kv.Key {
case "vcs.revision":
return kv.Value[0:8]
}
}
return "unknown"
}

12
common/misc_test.go Normal file
View File

@ -0,0 +1,12 @@
package common
import (
"testing"
"github.com/stretchr/testify/assert"
)
func TestMessage(t *testing.T) {
assert.Equal(t, "", MifloraGetAlphaNumericID(""))
assert.Equal(t, "1234567890ab", MifloraGetAlphaNumericID("12:34:56:78:90:ab"))
}

33
go.mod
View File

@ -1,17 +1,26 @@
module miflorad module miflorad
go 1.19
require ( require (
github.com/coreos/go-systemd v0.0.0-20190401025500-95778dfbb74e // indirect
github.com/currantlabs/gatt v0.0.0-20161006170101-f949eac78f4e github.com/currantlabs/gatt v0.0.0-20161006170101-f949eac78f4e
github.com/eclipse/paho.mqtt.golang v1.2.0 github.com/eclipse/paho.mqtt.golang v1.4.3
github.com/fatih/structs v1.1.0 // indirect github.com/go-ble/ble v0.0.0-20200120171844-0a73a9da88eb
github.com/go-ble/ble v0.0.0-20190515144946-e4c77014ff5a github.com/pkg/errors v0.9.1
github.com/mattn/go-colorable v0.1.1 // indirect github.com/stretchr/testify v1.9.0
github.com/mattn/go-isatty v0.0.7 // indirect )
github.com/mgutz/ansi v0.0.0-20170206155736-9520e82c474b // indirect
github.com/mgutz/logxi v0.0.0-20161027140823-aebf8a7d67ab // indirect require (
github.com/pkg/errors v0.8.1 github.com/davecgh/go-spew v1.1.1 // indirect
github.com/sirupsen/logrus v1.4.1 // indirect github.com/gorilla/websocket v1.5.0 // indirect
github.com/stretchr/testify v1.3.0 github.com/mattn/go-colorable v0.1.13 // indirect
golang.org/x/net v0.0.0-20190501013750-9ce7a6920f09 // indirect github.com/mattn/go-isatty v0.0.17 // indirect
github.com/mgutz/ansi v0.0.0-20200706080929-d51e80ef957d // indirect
github.com/mgutz/logxi v0.0.0-20161027140823-aebf8a7d67ab // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/raff/goble v0.0.0-20200327175727-d63360dcfd80 // indirect
golang.org/x/net v0.23.0 // indirect
golang.org/x/sync v0.1.0 // indirect
golang.org/x/sys v0.18.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
) )

101
go.sum
View File

@ -1,71 +1,56 @@
github.com/coreos/go-systemd v0.0.0-20180202092358-40e2722dffea/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
github.com/coreos/go-systemd v0.0.0-20181031085051-9002847aa142 h1:3jFq2xL4ZajGK4aZY8jz+DAF0FHjI51BXjjSwCzS1Dk= github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU=
github.com/coreos/go-systemd v0.0.0-20181031085051-9002847aa142/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4=
github.com/coreos/go-systemd v0.0.0-20190204113319-081494f7ee4f/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4=
github.com/coreos/go-systemd v0.0.0-20190222213131-93d5ec2c7f76/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4=
github.com/coreos/go-systemd v0.0.0-20190401025500-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4=
github.com/currantlabs/gatt v0.0.0-20161006170101-f949eac78f4e h1:qu1wqkuctiqRtgZu8kNMtFxQ7/xXuOxSJZ2kYoOxFM0= github.com/currantlabs/gatt v0.0.0-20161006170101-f949eac78f4e h1:qu1wqkuctiqRtgZu8kNMtFxQ7/xXuOxSJZ2kYoOxFM0=
github.com/currantlabs/gatt v0.0.0-20161006170101-f949eac78f4e/go.mod h1:GCdlaU9vOYeye8wQtSZNyZ4j5PhmnJ2HUqhRZO0KoZI= github.com/currantlabs/gatt v0.0.0-20161006170101-f949eac78f4e/go.mod h1:GCdlaU9vOYeye8wQtSZNyZ4j5PhmnJ2HUqhRZO0KoZI=
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/eclipse/paho.mqtt.golang v1.1.1 h1:iPJYXJLaViCshRTW/PSqImSS6HJ2Rf671WR0bXZ2GIU= github.com/eclipse/paho.mqtt.golang v1.4.3 h1:2kwcUGn8seMUfWndX0hGbvH8r7crgcJguQNCyp70xik=
github.com/eclipse/paho.mqtt.golang v1.1.1/go.mod h1:H9keYFcgq3Qr5OUJm/JZI/i6U7joQ8SYLhZwfeOo6Ts= github.com/eclipse/paho.mqtt.golang v1.4.3/go.mod h1:CSYvoAlsMkhYOXh/oKyxa8EcBci6dVkLCbo5tTC1RIE=
github.com/eclipse/paho.mqtt.golang v1.2.0 h1:1F8mhG9+aO5/xpdtFkW4SxOJB67ukuDC3t2y2qayIX0= github.com/go-ble/ble v0.0.0-20200120171844-0a73a9da88eb h1:YLbB9CgjUw1U9GxEqGvM2ld9YqHRoBeEEM7f8A8l9x0=
github.com/eclipse/paho.mqtt.golang v1.2.0/go.mod h1:H9keYFcgq3Qr5OUJm/JZI/i6U7joQ8SYLhZwfeOo6Ts= github.com/go-ble/ble v0.0.0-20200120171844-0a73a9da88eb/go.mod h1:nwmyxHsP2cqjashMTTAl3A5t6V3vzev1rLgMb/pZ7jc=
github.com/fatih/structs v1.0.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M= github.com/gorilla/websocket v1.5.0 h1:PPwGk2jz7EePpoHN/+ClbZu8SPxiqlu12wZP/3sWmnc=
github.com/fatih/structs v1.1.0 h1:Q7juDM0QtcnhCpeyLGQKyg4TOIghuNXrkL32pHAUMxo= github.com/gorilla/websocket v1.5.0/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE=
github.com/fatih/structs v1.1.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M= github.com/mattn/go-colorable v0.1.4/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE=
github.com/go-ble/ble v0.0.0-20181002102605-e78417b510a3 h1:rsLGztXl2QJvj4x/PAWzC1Zx6tnTDKlosaXAZfaXM8M= github.com/mattn/go-colorable v0.1.13 h1:fFA4WZxdEF4tXPZVKMLwD8oUnCTTo08duU7wxecdEvA=
github.com/go-ble/ble v0.0.0-20181002102605-e78417b510a3/go.mod h1:UMPB54/KFpdTdfH7Yovhk3J6kzgzE88e3QZi8cbayis= github.com/mattn/go-colorable v0.1.13/go.mod h1:7S9/ev0klgBDR4GtXTXX8a3vIGJpMovkB8vQcUbaXHg=
github.com/go-ble/ble v0.0.0-20190515144946-e4c77014ff5a h1:Di8pZP1T0FmSSK1x+TsKQnq3Wn1dZ5wbpvLcqgit9wo= github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s=
github.com/go-ble/ble v0.0.0-20190515144946-e4c77014ff5a/go.mod h1:UMPB54/KFpdTdfH7Yovhk3J6kzgzE88e3QZi8cbayis= github.com/mattn/go-isatty v0.0.10/go.mod h1:qgIWMr58cqv1PHHyhnkY9lrL7etaEgOFcMEpPG5Rm84=
github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/mattn/go-isatty v0.0.16/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM=
github.com/mattn/go-colorable v0.0.9 h1:UVL0vNpWh04HeJXV0KLcaT7r06gOH2l4OW6ddYRUIY4= github.com/mattn/go-isatty v0.0.17 h1:BTarxUcIeDqL27Mc+vyvdWYSL28zpIhv3RoTdsLMPng=
github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= github.com/mattn/go-isatty v0.0.17/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM=
github.com/mattn/go-colorable v0.1.0/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU=
github.com/mattn/go-colorable v0.1.1 h1:G1f5SKeVxmagw/IyvzvtZE4Gybcc4Tr1tf7I8z0XgOg=
github.com/mattn/go-colorable v0.1.1/go.mod h1:FuOcm+DKB9mbwrcAfNl7/TZVBZ6rcnceauSikq3lYCQ=
github.com/mattn/go-isatty v0.0.4 h1:bnP0vzxcAdeI1zdubAl5PjU6zsERjGZb7raWodagDYs=
github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4=
github.com/mattn/go-isatty v0.0.5/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s=
github.com/mattn/go-isatty v0.0.6/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s=
github.com/mattn/go-isatty v0.0.7 h1:UvyT9uN+3r7yLEYSlJsbQGdsaB/a0DlgWP3pql6iwOc=
github.com/mattn/go-isatty v0.0.7/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s=
github.com/mgutz/ansi v0.0.0-20170206155736-9520e82c474b h1:j7+1HpAFS1zy5+Q4qx1fWh90gTKwiN4QCGoY9TWyyO4=
github.com/mgutz/ansi v0.0.0-20170206155736-9520e82c474b/go.mod h1:01TrycV0kFyexm33Z7vhZRXopbI8J3TDReVlkTgMUxE= github.com/mgutz/ansi v0.0.0-20170206155736-9520e82c474b/go.mod h1:01TrycV0kFyexm33Z7vhZRXopbI8J3TDReVlkTgMUxE=
github.com/mgutz/ansi v0.0.0-20200706080929-d51e80ef957d h1:5PJl274Y63IEHC+7izoQE9x6ikvDFZS2mDVS3drnohI=
github.com/mgutz/ansi v0.0.0-20200706080929-d51e80ef957d/go.mod h1:01TrycV0kFyexm33Z7vhZRXopbI8J3TDReVlkTgMUxE=
github.com/mgutz/logxi v0.0.0-20161027140823-aebf8a7d67ab h1:n8cgpHzJ5+EDyDri2s/GC7a9+qK3/YEGnBsd0uS/8PY= github.com/mgutz/logxi v0.0.0-20161027140823-aebf8a7d67ab h1:n8cgpHzJ5+EDyDri2s/GC7a9+qK3/YEGnBsd0uS/8PY=
github.com/mgutz/logxi v0.0.0-20161027140823-aebf8a7d67ab/go.mod h1:y1pL58r5z2VvAjeG1VLGc8zOQgSOzbKN7kMHPvFXJ+8= github.com/mgutz/logxi v0.0.0-20161027140823-aebf8a7d67ab/go.mod h1:y1pL58r5z2VvAjeG1VLGc8zOQgSOzbKN7kMHPvFXJ+8=
github.com/pkg/errors v0.8.0 h1:WdK/asTD0HN+q6hsWO3/vpuAkAr+tw6aNJNDFFf0+qw=
github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
github.com/pkg/errors v0.8.1 h1:iURUrRGxPUNPdy5/HRSm+Yj6okJ6UtLINN0Q9M4+h3I=
github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/sirupsen/logrus v1.2.0 h1:juTguoYk5qI21pwyTXY3B3Y5cOTH3ZUyZCg1v/mihuo= github.com/raff/goble v0.0.0-20190909174656-72afc67d6a99/go.mod h1:CxaUhijgLFX0AROtH5mluSY71VqpjQBw9JXE2UKZmc4=
github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= github.com/raff/goble v0.0.0-20200327175727-d63360dcfd80 h1:IZkjNgPZXcE4USkGzmJQyHco3KFLmhcLyFdxCOiY6cQ=
github.com/sirupsen/logrus v1.3.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= github.com/raff/goble v0.0.0-20200327175727-d63360dcfd80/go.mod h1:CxaUhijgLFX0AROtH5mluSY71VqpjQBw9JXE2UKZmc4=
github.com/sirupsen/logrus v1.4.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
github.com/sirupsen/logrus v1.4.1/go.mod h1:ni0Sbl8bgC9z8RoU9G6nDWqqs/fq4eDPysMBDgk/93Q= github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc=
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4=
github.com/stretchr/testify v1.2.2 h1:bSDNvY7ZPG5RlJ8otE/7V6gMiyenm9RtJ7IUVIAoJ1w= github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg=
github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY=
github.com/stretchr/testify v1.3.0 h1:TivCn/peBQ7UY8ooIcPgZFpTNSz0Q2U6UrFlUfqbe0Q= github.com/urfave/cli v1.22.2/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0=
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= golang.org/x/net v0.23.0 h1:7EYJ93RZ9vYSZAIb2x3lnuvqO5zneoD6IvWjuhfxjTs=
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/net v0.23.0/go.mod h1:JKghWKKOSdJwpW2GEx0Ja7fmaKnMsbu+MWVZTokSYmg=
golang.org/x/net v0.0.0-20181220203305-927f97764cc3 h1:eH6Eip3UpmR+yM/qI9Ijluzb1bNv/cAU/n+6l8tRSis= golang.org/x/sync v0.1.0 h1:wsuoTGHzEhffawBOhz5CYhcrV4IdKZbEyZjBMuTp12o=
golang.org/x/net v0.0.0-20181220203305-927f97764cc3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/net v0.0.0-20190107174441-1a61f4433d85/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
golang.org/x/net v0.0.0-20190111034749-915654e7eabc/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
golang.org/x/net v0.0.0-20190301014737-92fc7df08ae7 h1:izsVbp6aRPsQs382yTgqgK3Sz5mgX1N/DQVRIYelTQE=
golang.org/x/net v0.0.0-20190301014737-92fc7df08ae7/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
golang.org/x/net v0.0.0-20190501013750-9ce7a6920f09 h1:5S8x497/nsQl7/BhsbJWW6AUJO4fVkqOQN8JOmPoiuM=
golang.org/x/net v0.0.0-20190501013750-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33 h1:I6FyU15t786LL7oL/hn43zqTuEGr4PN7F4XJ1p4E3Y8=
golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190213121743-983097b1a8a3/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223 h1:DH4skfRX4EBpamg7iV4ZlCpblAHI6s6TDM39bFZumv8=
golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/sys v0.0.0-20191008105621-543471e840be/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20191126131656-8a8471f7e56d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.18.0 h1:DBdB3niSjOA/O0blCZBqDefyWNYveAYMNF1Wum0DYQ4=
golang.org/x/sys v0.18.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=

View File

@ -1,27 +0,0 @@
{
"extends": [
"config:base"
],
"commitMessagePrefix": "module:",
"commitMessageAction": "update",
"rebaseStalePrs": true,
"packageRules": [
{
"packageNames": [
"github.com/currantlabs/gatt",
"github.com/muka/ble",
"github.com/muka/go-bluetooth"
],
"extends": ["schedule:weekly"]
},
{
"packageNames": [
"github.com/coreos/go-systemd",
"github.com/mgutz/ansi",
"github.com/mgutz/logxi",
"golang.org/x/net"
],
"extends": ["schedule:monthly"]
}
]
}