Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/bradleyfalzon/gopherci
/ types & classes
Types & classes
62 in github.com/bradleyfalzon/gopherci
⨍
Functions
222
◇
Types & classes
62
↓ 6 callers
TypeAlias
Duration
Duration is similar to a time.Duration but with extra methods to better handle mysql DB type TIME(3).
internal/db/db.go:100
↓ 1 callers
TypeAlias
ToolID
ToolID is the primary key on the tools table.
internal/db/db.go:86
Struct
AnalyseConfig
AnalyseConfig is a configuration struct for the Analyse method, all fields are required, unless otherwise stated.
internal/github/handlers.go:325
Interface
Analyser
An Analyser is builds an isolated execution environment to run checks in. It should provide isolation from other environments and support being called
internal/analyser/analyser.go:25
Struct
Analysis
Analysis represents a single analysis of a repository at a point in time.
internal/db/db.go:135
TypeAlias
AnalysisStatus
AnalysisStatus represents a status in the analysis table.
internal/db/db.go:38
Struct
AnalysisTool
AnalysisTool contains the timing and result of an individual tool's analysis.
internal/db/db.go:180
TypeAlias
ChangeType
ChangeType is type of change that affects a line, such as added or removed.
internal/web/vcsviewer.go:50
Interface
Cloner
A Cloner uses the executer to clone the root of a repository into the current working directory.
internal/analyser/cloner.go:12
Struct
CommitCommentReporter
CommitCommentReporter creates a single commit comment summarising all issues on a given owner, repo, and commit hash.
internal/github/reporters.go:189
Struct
Config
Config hold configuration options for use in analyser. All options are required.
internal/analyser/analyser.go:33
Interface
ConfigReader
A ConfigReader returns a repository's configuration.
internal/analyser/configReader.go:19
Interface
DB
DB interface provides access to a persistent database.
internal/db/db.go:11
Struct
Docker
Docker is an Analyser that provides an Executer to build projects inside Docker containers.
internal/analyser/docker.go:25
Struct
DockerExecuter
DockerExecuter is an Executer that runs commands in a contained environment for a single project.
internal/analyser/docker.go:63
Interface
Executer
Executer executes a single command in a contained environment.
internal/analyser/analyser.go:39
Interface
Executer
Executer is the same interface as analyser.Executer, but due to import cycles must be redefined here.
internal/db/sqldb.go:301
Struct
FileSystem
FileSystem is an Analyser than provides an Executer to build contained environments on the file system. FileSystem is safe to use concurrently, as al
internal/analyser/filesystem.go:24
Struct
FileSystemExecuter
FileSystemExecuter is an Executer that runs commands in a contained environment.
internal/analyser/filesystem.go:54
Struct
FixedRef
FixedRef is a RefReader for handling events where we know the base ref and can just return the string.
internal/analyser/refReader.go:35
Struct
GCPPubSubQueue
GCPPubSubQueue is a queue using Google Compute Platform's PubSub product.
internal/queue/gcp-pubsub.go:38
Struct
GHInstallation
GHInstallation represents a row from the gh_installations table.
internal/db/db.go:72
Struct
GitHub
GitHub is the type gopherci uses to interract with github.com.
internal/github/github.go:14
Struct
Hunk
A Hunk represents a single hunk of changed lines.
internal/web/vcsviewer.go:44
Struct
InlineCommitCommentReporter
InlineCommitCommentReporter is a analyser.Reporter that creates a commit comment for each issue on a single commit. This should only be used if all is
internal/github/reporters.go:240
Struct
Installation
Installation is a GitHub Integration which has operates in the context of a GitHub installation, and therefore performance operations as that installa
internal/github/installation.go:17
Struct
IntegrationTest
IntegrationTest helps run a single integration test. Focusing on interaction between GopherCI and GitHub, IntegrationTest helps write tests that ensur
integration_test.go:26
Struct
Issue
Issue contains file, position and string describing a single issue.
internal/db/db.go:188
Struct
Line
A Line represents a single line in a diff.
internal/web/vcsviewer.go:62
Interface
Logger
Logger is a service to write structured, levelled logs with context.
internal/logger/logger.go:17
Struct
MemoryQueue
MemoryQueue is an in memory queue of infinite size.
internal/queue/memory.go:14
Struct
MergeBase
MergeBase is a RefReader for handling pull requests by using git's merge-base tool to find the common ancestor between HEAD and FETCH_HEAD. It expects
internal/analyser/refReader.go:19
Struct
MockDB
MockDB is an in-memory database repository implementing the DB interface used for testing
internal/db/mockdb.go:7
Struct
NonZeroError
NonZeroError maybe returned by an Executer when the command executed returns with a non-zero exit status.
internal/analyser/analyser.go:51
Struct
Output
Output represents a row in the outputs table.
internal/db/db.go:126
Struct
PRCommentReporter
PRCommentReporter is a analyser.Reporter that creates a pull request comment for each issue on a given owner, repo, pr and commit hash. Returns on the
internal/github/reporters.go:20
Struct
PRReviewReporter
PRReviewReporter is a analyser.Reporter that creates a pull request review on a given owner, repo, pr and commit hash. Sets review status to COMMENT i
internal/github/reporters.go:283
Struct
Patch
A Patch represents a single file's patch.
internal/web/vcsviewer.go:38
Struct
PullRequestCloner
PullRequestCloner is a Cloner for handling cloning the HeadURL at HeadRef and also fetches BaseURL at BaseRef.
internal/analyser/cloner.go:18
Struct
PushCloner
PushCloner is a Cloner for handling cloning of HeadURL and checking out HeadRef.
internal/analyser/cloner.go:53
Interface
RefReader
RefReader returns the base reference of a repository.
internal/analyser/refReader.go:12
Struct
RepoConfig
RepoConfig contains the analyser configuration for the repository.
internal/analyser/configReader.go:13
Interface
Reporter
A Reporter reports the issues, and may be called with 0 or more issues.
internal/analyser/reporter.go:10
Struct
S
internal/queue/gcp-pubsub_test.go:42
Struct
SQLDB
SQLDB is a sql database repository implementing the DB interface.
internal/db/sqldb.go:18
Struct
SQLExecuteWriter
SQLExecuteWriter wraps an Executer and writes the results of execution to db.
internal/db/sqldb.go:291
Struct
StatusAPIReporter
StatusAPIReporter uses the GitHub Statuses API to report build status, such as success or failure.
internal/github/reporters.go:109
TypeAlias
StatusState
StatusState is the state of a GitHub Status API as defined in https://developer.github.com/v3/repos/statuses/
internal/github/reporters.go:97
Struct
Tool
Tool represents a single tool in the tools table.
internal/db/db.go:89
Interface
VCSReader
A VCSReader reads information about a completed analysis.
internal/web/vcsviewer.go:19
Struct
Web
Web handles general web/html responses (not API hooks).
internal/web/web.go:16
Struct
YAMLConfig
YAMLConfig implements a ConfigReader by reading a yaml configuration file from the repositories root.
internal/analyser/configReader.go:25
Struct
container
internal/queue/gcp-pubsub.go:156
Struct
ignoreEvent
ignoreEvent indicates the event should be accepted but ignored.
internal/github/handlers.go:150
TypeAlias
ignoreReason
internal/github/handlers.go:137
Struct
log
Log implements the Logger interface by wrapping logrus.
internal/logger/logger.go:39
Struct
mockAnalyser
internal/github/handlers_test.go:53
Struct
mockCloner
internal/analyser/analyser_test.go:32
Struct
mockConfig
internal/analyser/analyser_test.go:38
Struct
mockExecuter
internal/analyser/analyser_test.go:13
Struct
queueProcessor
Queue processor is the callback called by queuer when receiving a job
main.go:230
Struct
status
internal/github/reporters_test.go:135