mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-01-12 03:21:33 +00:00
Merge pull request #659 from apachelogger/fix-align-lint
fix linting by using new maligned linter instead of aligncheck
This commit is contained in:
@@ -592,7 +592,7 @@ func (repo *RemoteRepo) Decode(input []byte) error {
|
||||
if err != nil {
|
||||
if strings.HasPrefix(err.Error(), "codec.decoder: readContainerLen: Unrecognized descriptor byte: hex: 80") {
|
||||
// probably it is broken DB from go < 1.2, try decoding w/o time.Time
|
||||
var repo11 struct {
|
||||
var repo11 struct { // nolint: maligned
|
||||
UUID string
|
||||
Name string
|
||||
ArchiveRoot string
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
"staticcheck",
|
||||
"varcheck",
|
||||
"structcheck",
|
||||
"aligncheck",
|
||||
"maligned",
|
||||
"vetshadow",
|
||||
"goconst",
|
||||
"interfacer"
|
||||
|
||||
@@ -194,7 +194,7 @@ class BaseTest(object):
|
||||
def check_output(self):
|
||||
try:
|
||||
self.verify_match(self.get_gold(), self.output, match_prepare=self.outputMatchPrepare)
|
||||
except:
|
||||
except: # noqa: E722
|
||||
if self.captureResults:
|
||||
if self.outputMatchPrepare is not None:
|
||||
self.output = self.outputMatchPrepare(self.output)
|
||||
@@ -207,7 +207,7 @@ class BaseTest(object):
|
||||
output = self.run_cmd(command, expected_code=expected_code)
|
||||
try:
|
||||
self.verify_match(self.get_gold(gold_name), output, match_prepare)
|
||||
except:
|
||||
except: # noqa: E722
|
||||
if self.captureResults:
|
||||
if match_prepare is not None:
|
||||
output = match_prepare(output)
|
||||
@@ -228,7 +228,7 @@ class BaseTest(object):
|
||||
try:
|
||||
|
||||
self.verify_match(self.get_gold(gold_name), contents, match_prepare=match_prepare)
|
||||
except:
|
||||
except: # noqa: E722
|
||||
if self.captureResults:
|
||||
if match_prepare is not None:
|
||||
contents = match_prepare(contents)
|
||||
@@ -241,7 +241,7 @@ class BaseTest(object):
|
||||
contents = open(self.checkedFile, "r").read()
|
||||
try:
|
||||
self.verify_match(self.get_gold(), contents)
|
||||
except:
|
||||
except: # noqa: E722
|
||||
if self.captureResults:
|
||||
with open(self.get_gold_filename(), "w") as f:
|
||||
f.write(contents)
|
||||
|
||||
@@ -7,7 +7,7 @@ import (
|
||||
)
|
||||
|
||||
// ConfigStructure is structure of main configuration
|
||||
type ConfigStructure struct { // nolint: aligncheck
|
||||
type ConfigStructure struct { // nolint: maligned
|
||||
RootDir string `json:"rootDir"`
|
||||
DownloadConcurrency int `json:"downloadConcurrency"`
|
||||
DownloadLimit int64 `json:"downloadSpeedLimit"`
|
||||
|
||||
Reference in New Issue
Block a user