golangci
No long description provided.
Installation
dagger install github.com/shykes/dagger/modules/golangci@564d076f9461914d579a320f5d875b142d43bf6cEntrypoint
Return Type
Golangci Example
dagger -m github.com/shykes/dagger/modules/golangci@564d076f9461914d579a320f5d875b142d43bf6c call \
func (m *MyModule) Example() *dagger.Golangci {
return dag.
Golangci()
}@function
def example() -> dagger.Golangci:
return (
dag.golangci()
)@func()
example(): Golangci {
return dag
.golangci()
}Types
Golangci 🔗
lint() 🔗
Lint a go codebase
Return Type
LintRun !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| source | Directory ! | - | The Go source directory to lint |
| path | String | - | Lint a specific path within the source directory |
| goModCache | CacheVolume | - | A cache volume to use for go module downloads |
| goBuildCache | CacheVolume | - | A cache volume to use for go build |
| goLintCache | CacheVolume | - | A cache volume to use for golangci-lint |
Example
dagger -m github.com/shykes/dagger/modules/golangci@564d076f9461914d579a320f5d875b142d43bf6c call \
lint --source DIR_PATHfunc (m *MyModule) Example(source *dagger.Directory) *dagger.GolangciLintRun {
return dag.
Golangci().
Lint(source)
}@function
def example(source: dagger.Directory) -> dagger.GolangciLintRun:
return (
dag.golangci()
.lint(source)
)@func()
example(source: Directory): GolangciLintRun {
return dag
.golangci()
.lint(source)
}LintRun 🔗
The result of running the GolangCI lint tool
issues() 🔗
Return Type
[Issue ! ] ! Example
dagger -m github.com/shykes/dagger/modules/golangci@564d076f9461914d579a320f5d875b142d43bf6c call \
lint --source DIR_PATH \
issuesfunc (m *MyModule) Example(source *dagger.Directory) []*dagger.GolangciIssue {
return dag.
Golangci().
Lint(source).
Issues()
}@function
def example(source: dagger.Directory) -> List[dagger.GolangciIssue]:
return (
dag.golangci()
.lint(source)
.issues()
)@func()
example(source: Directory): GolangciIssue[] {
return dag
.golangci()
.lint(source)
.issues()
}assert() 🔗
Return Type
Void ! Example
dagger -m github.com/shykes/dagger/modules/golangci@564d076f9461914d579a320f5d875b142d43bf6c call \
lint --source DIR_PATH \
assertfunc (m *MyModule) Example(ctx context.Context, source *dagger.Directory) {
return dag.
Golangci().
Lint(source).
Assert(ctx)
}@function
async def example(source: dagger.Directory) -> None:
return await (
dag.golangci()
.lint(source)
.assert_()
)@func()
async example(source: Directory): Promise<void> {
return dag
.golangci()
.lint(source)
.assert()
}errorCount() 🔗
Return Type
Integer ! Example
dagger -m github.com/shykes/dagger/modules/golangci@564d076f9461914d579a320f5d875b142d43bf6c call \
lint --source DIR_PATH \
error-countfunc (m *MyModule) Example(ctx context.Context, source *dagger.Directory) int {
return dag.
Golangci().
Lint(source).
ErrorCount(ctx)
}@function
async def example(source: dagger.Directory) -> int:
return await (
dag.golangci()
.lint(source)
.error_count()
)@func()
async example(source: Directory): Promise<number> {
return dag
.golangci()
.lint(source)
.errorCount()
}warningCount() 🔗
Return Type
Integer ! Example
dagger -m github.com/shykes/dagger/modules/golangci@564d076f9461914d579a320f5d875b142d43bf6c call \
lint --source DIR_PATH \
warning-countfunc (m *MyModule) Example(ctx context.Context, source *dagger.Directory) int {
return dag.
Golangci().
Lint(source).
WarningCount(ctx)
}@function
async def example(source: dagger.Directory) -> int:
return await (
dag.golangci()
.lint(source)
.warning_count()
)@func()
async example(source: Directory): Promise<number> {
return dag
.golangci()
.lint(source)
.warningCount()
}report() 🔗
Return a JSON report file for this run
Return Type
File ! Example
dagger -m github.com/shykes/dagger/modules/golangci@564d076f9461914d579a320f5d875b142d43bf6c call \
lint --source DIR_PATH \
reportfunc (m *MyModule) Example(source *dagger.Directory) *dagger.File {
return dag.
Golangci().
Lint(source).
Report()
}@function
def example(source: dagger.Directory) -> dagger.File:
return (
dag.golangci()
.lint(source)
.report()
)@func()
example(source: Directory): File {
return dag
.golangci()
.lint(source)
.report()
}Issue 🔗
text() 🔗
Return Type
String ! Example
Function GolangciIssue.text is not accessible from the golangci moduleFunction GolangciIssue.text is not accessible from the golangci moduleFunction GolangciIssue.text is not accessible from the golangci moduleFunction GolangciIssue.text is not accessible from the golangci modulefromLinter() 🔗
Return Type
String ! Example
Function GolangciIssue.fromLinter is not accessible from the golangci moduleFunction GolangciIssue.fromLinter is not accessible from the golangci moduleFunction GolangciIssue.fromLinter is not accessible from the golangci moduleFunction GolangciIssue.fromLinter is not accessible from the golangci modulesourceLines() 🔗
Return Type
[String ! ] ! Example
Function GolangciIssue.sourceLines is not accessible from the golangci moduleFunction GolangciIssue.sourceLines is not accessible from the golangci moduleFunction GolangciIssue.sourceLines is not accessible from the golangci moduleFunction GolangciIssue.sourceLines is not accessible from the golangci modulereplacement() 🔗
Return Type
Replacement ! Example
Function GolangciIssue.replacement is not accessible from the golangci moduleFunction GolangciIssue.replacement is not accessible from the golangci moduleFunction GolangciIssue.replacement is not accessible from the golangci moduleFunction GolangciIssue.replacement is not accessible from the golangci modulepos() 🔗
Return Type
Position ! Example
Function GolangciIssue.pos is not accessible from the golangci moduleFunction GolangciIssue.pos is not accessible from the golangci moduleFunction GolangciIssue.pos is not accessible from the golangci moduleFunction GolangciIssue.pos is not accessible from the golangci moduleexpectedNoLint() 🔗
Return Type
Boolean ! Example
Function GolangciIssue.expectedNoLint is not accessible from the golangci moduleFunction GolangciIssue.expectedNoLint is not accessible from the golangci moduleFunction GolangciIssue.expectedNoLint is not accessible from the golangci moduleFunction GolangciIssue.expectedNoLint is not accessible from the golangci moduleseverity() 🔗
Return Type
String ! Example
Function GolangciIssue.severity is not accessible from the golangci moduleFunction GolangciIssue.severity is not accessible from the golangci moduleFunction GolangciIssue.severity is not accessible from the golangci moduleFunction GolangciIssue.severity is not accessible from the golangci moduleisError() 🔗
Return Type
Boolean ! Example
Function GolangciIssue.isError is not accessible from the golangci moduleFunction GolangciIssue.isError is not accessible from the golangci moduleFunction GolangciIssue.isError is not accessible from the golangci moduleFunction GolangciIssue.isError is not accessible from the golangci modulesummary() 🔗
Return Type
String ! Example
Function GolangciIssue.summary is not accessible from the golangci moduleFunction GolangciIssue.summary is not accessible from the golangci moduleFunction GolangciIssue.summary is not accessible from the golangci moduleFunction GolangciIssue.summary is not accessible from the golangci moduleReplacement 🔗
text() 🔗
Return Type
String ! Example
Function GolangciReplacement.text is not accessible from the golangci moduleFunction GolangciReplacement.text is not accessible from the golangci moduleFunction GolangciReplacement.text is not accessible from the golangci moduleFunction GolangciReplacement.text is not accessible from the golangci modulePosition 🔗
filename() 🔗
Return Type
String ! Example
Function GolangciPosition.filename is not accessible from the golangci moduleFunction GolangciPosition.filename is not accessible from the golangci moduleFunction GolangciPosition.filename is not accessible from the golangci moduleFunction GolangciPosition.filename is not accessible from the golangci moduleoffset() 🔗
Return Type
Integer ! Example
Function GolangciPosition.offset is not accessible from the golangci moduleFunction GolangciPosition.offset is not accessible from the golangci moduleFunction GolangciPosition.offset is not accessible from the golangci moduleFunction GolangciPosition.offset is not accessible from the golangci moduleline() 🔗
Return Type
Integer ! Example
Function GolangciPosition.line is not accessible from the golangci moduleFunction GolangciPosition.line is not accessible from the golangci moduleFunction GolangciPosition.line is not accessible from the golangci moduleFunction GolangciPosition.line is not accessible from the golangci modulecolumn() 🔗
Return Type
Integer ! Example
Function GolangciPosition.column is not accessible from the golangci moduleFunction GolangciPosition.column is not accessible from the golangci moduleFunction GolangciPosition.column is not accessible from the golangci moduleFunction GolangciPosition.column is not accessible from the golangci module