MCPcopy Create free account

hub / github.com/bradleyfalzon/gopherci / functions

Functions222 in github.com/bradleyfalzon/gopherci

↓ 108 callersMethodErrorf
(format string, args ...interface{})
internal/logger/logger.go:28
↓ 90 callersMethodString
String implements the fmt.Stringer interface.
internal/db/db.go:121
↓ 78 callersMethodFatalf
(format string, args ...interface{})
internal/logger/logger.go:32
↓ 63 callersMethodWith
With adds context to a logger.
internal/logger/logger.go:35
↓ 48 callersMethodError
Error logs, errors. An error should only be logged once.
internal/logger/logger.go:27
↓ 31 callersMethodFatal
Fatal logs an error and then immediately terminates execution.
internal/logger/logger.go:31
↓ 29 callersMethodInfo
Info logs general events.
internal/logger/logger.go:23
↓ 22 callersMethodClose
Close stops gopherci and removes any temporary directories.
integration_test.go:112
↓ 22 callersMethodExec
Exec executes a script within the testdata directory with args.
integration_test.go:126
↓ 18 callersMethodInfof
(format string, args ...interface{})
internal/logger/logger.go:24
↓ 15 callersMethodExecute
(context.Context, []string)
internal/db/sqldb.go:302
↓ 10 callersMethodWaitForSuccess
WaitForSuccess waits for the statusContext's ref Status API to be success, will only wait for a short timeout, unless the status is failure or error,
integration_test.go:141
↓ 9 callersFunctionsetup
(t *testing.T)
internal/github/handlers_test.go:83
↓ 8 callersMethodIsEnabled
IsEnabled returns true if an installation is enabled.
internal/github/installation.go:51
↓ 8 callersFunctionNewIntegrationTest
NewIntegrationTest creates an environment for running integration tests by creating file system temporary directories, starting gopherci and setting u
integration_test.go:40
↓ 7 callersFunctiongoodPush
()
internal/github/handlers_test.go:578
↓ 6 callersMethodAddGHInstallation
AddGHInstallation records a new installation.
internal/db/db.go:13
↓ 6 callersMethodDiff
Diff returns a multi file unified diff as an io.ReadCloser, return nil if no diff could be found or returns an error if an error is found.
internal/web/vcsviewer.go:22
↓ 6 callersMethodExecute
Execute executes a command and returns the combined stdout and stderr, along with an error if any. Must not be called after Stop(). If the command ret
internal/analyser/analyser.go:44
↓ 6 callersFunctionNewAnalysis
NewAnalysis returns a ready to use analysis.
internal/db/db.go:153
↓ 6 callersMethodNewInstallation
(installationID int)
internal/github/installation.go:22
↓ 6 callersMethoderrorHandler
errorHandler handles an error message, with an optional description
internal/web/web.go:46
↓ 5 callersMethodAnalyse
Analyse analyses a GitHub event. If cfg.pr is not 0, comments will also be written on the Pull Request.
internal/github/handlers.go:353
↓ 5 callersMethodIssues
Issues returns all the issues by each tool as a slice.
internal/db/db.go:160
↓ 5 callersMethodStop
(context.Context)
internal/db/sqldb.go:303
↓ 5 callersMethodWait
Wait waits for messages on queuePush and adds them to the queue. New message are checked for regularly and when a new message is ready f will be calle
internal/queue/memory.go:28
↓ 4 callersMethodEnableGHInstallation
EnableGHInstallation enables a gh installation
internal/db/mockdb.go:45
↓ 4 callersMethodRead
Read implements the ConfigReader interface.
internal/analyser/configReader.go:32
↓ 4 callersMethodSetStatus
SetStatus sets the CI Status API
internal/github/reporters.go:131
↓ 4 callersMethodintegrationInstallationEvent
(e *github.InstallationEvent)
internal/github/handlers.go:248
↓ 3 callersMethodGetGHInstallation
GetGHInstallation returns an installation for a given installationID, returns nil if no installation was found, or an error occurs.
internal/db/db.go:18
↓ 3 callersFunctiondedupePRIssues
dedupePRIssues deduplicates issues by checking the existing pull request for existing comments and returns comments that don't already exist.
internal/github/reporters.go:43
↓ 3 callersFunctiongetPatch
(ctx context.Context, exec Executer, baseRef, headRef string)
internal/analyser/analyser.go:200
↓ 3 callersFunctionstripScheme
stripScheme removes the scheme/protocol and :// from a URL.
internal/github/handlers.go:478
↓ 2 callersMethodDebug
Debug level for developer concerned debugging, not visible in production.
internal/logger/logger.go:19
↓ 2 callersMethodDebugf
(format string, args ...interface{})
internal/logger/logger.go:20
↓ 2 callersFunctionDiffIssues
DiffIssues reads a diff and adds the issues to the lines affected. Only hunks with issues will be returned.
internal/web/vcsviewer.go:71
↓ 2 callersMethodFinishAnalysis
FinishAnalysis marks a status as finished.
internal/db/db.go:27
↓ 2 callersMethodForceError
ForceError forces MockDB to return err on all methods that return an error.
internal/db/mockdb.go:24
↓ 2 callersMethodGetGHInstallation
GetGHInstallation implements DB interface
internal/db/mockdb.go:53
↓ 2 callersMethodHTMLURL
HTMLURL returns the URL to view the analysis.
internal/db/db.go:169
↓ 2 callersMethodIsPush
IsPush returns true if the analysis was triggered by a push, or false if it was triggered by pull/merge request.
internal/db/db.go:175
↓ 2 callersFunctionNew
New constructs a new Logger.
internal/logger/logger.go:44
↓ 2 callersFunctionNewCommitCommentReporter
NewCommitCommentReporter returns a CommitCommentReporter. commits is the number of commits the analysis is checking (to be displayed in the message) a
internal/github/reporters.go:203
↓ 2 callersFunctionNewFileSystem
NewFileSystem returns an FileSystem which uses the path base to build contained environments on the file system. If memLimit is > 0, limit the amount
internal/analyser/filesystem.go:35
↓ 2 callersFunctionNewGCPPubSubQueue
NewGCPPubSubQueue creates connects to Google Pub/Sub with a topic and subscriber in a one-to-one architecture.
internal/queue/gcp-pubsub.go:48
↓ 2 callersFunctionNewInlineCommitCommentReporter
NewInlineCommitCommentReporter returns a InlineCommitCommentReporter.
internal/github/reporters.go:250
↓ 2 callersFunctionNewPRReviewReporter
NewPRReviewReporter returns a PRReviewReporter.
internal/github/reporters.go:294
↓ 2 callersFunctionNewStatusAPIReporter
NewStatusAPIReporter returns a StatusAPIReporter.
internal/github/reporters.go:120
↓ 2 callersFunctionPushConfig
PushConfig returns an AnalyseConfig for a GitHub Push Event.
internal/github/handlers.go:265
↓ 2 callersMethodScan
Scan implements the sql.Scanner interface.
internal/db/db.go:103
↓ 2 callersMethodStop
Stop stops the executer and allows it to cleanup, if applicable.
internal/analyser/analyser.go:46
↓ 2 callersMethodStop
Stop stops and removes a container ignoring any errors.
internal/analyser/docker.go:166
↓ 2 callersMethodWait
Wait waits for messages on queuePush and adds them to the Pub/Sub queue. Upon receiving messages from Pub/Sub, f is invoked with the message. Wait is
internal/queue/gcp-pubsub.go:96
↓ 2 callersMethodWebHookHandler
WebHookHandler is the net/http handler for github webhooks.
internal/github/handlers.go:43
↓ 2 callersFunctioncheckPRAccessible
checkPRAccessible checks to ensure the pull request is accessible. GitHub may have marked a repository as suspicious where some API requests are no lo
internal/github/handlers.go:217
↓ 2 callersFunctioncheckPRAction
checkPRAction checks a pull request's action to determine whether the event should continue to be processed. Returns error type *ignoreEvent if the ev
internal/github/handlers.go:180
↓ 2 callersFunctioncheckPRAffectsGo
checkPRAffectsGo returns true if a pull request modifies, adds or removes Go files, else returns error if an error occurs.
internal/github/handlers.go:194
↓ 2 callersFunctioncheckPushAffectsGo
checkPushAffectsGo returns true if the event modifies, adds or removes Go files.
internal/github/handlers.go:226
↓ 2 callersFunctionexists
(path string)
internal/analyser/filesystem_test.go:76
↓ 2 callersFunctionhasGoExtension
hasGoExtension returns true if the filename has the suffix ".go".
internal/github/handlers.go:244
↓ 2 callersFunctioninstallAPTPackages
installAptPackages install packages using apt package manager, it expects apt-get update to have already been executed. Can be called with 0 or more p
internal/analyser/analyser.go:224
↓ 2 callersMethodstatusDesc
statusDesc builds a status description based on issues.
internal/github/reporters.go:172
↓ 2 callersFunctiontrim
trim trims input b to approximately max by keeping the first and last max/2 bytes. It may be larger due to n bytes suppressed placeholder message.
internal/db/sqldb.go:280
↓ 1 callersMethodAddGHInstallation
AddGHInstallation implements DB interface
internal/db/mockdb.go:29
↓ 1 callersFunctionAnalyse
Analyse downloads a repository set in config in an environment provided by exec, running the series of tools. Writes results to provided analysis, or
internal/analyser/analyser.go:64
↓ 1 callersMethodAnalysisOutputs
AnalysisOutputs returns the ordered output from the database.
internal/db/db.go:32
↓ 1 callersMethodBase
(context.Context, Executer)
internal/analyser/refReader.go:13
↓ 1 callersMethodBase
Base implements the RefReader interface.
internal/analyser/refReader.go:24
↓ 1 callersMethodBase
Base implements the RefReader interface.
internal/analyser/refReader.go:42
↓ 1 callersMethodCallbackHandler
CallbackHandler is the net/http handler for github callbacks. This may have only been for old integration behaviour, as it doesn't appear to be docume
internal/github/handlers.go:24
↓ 1 callersMethodCleanup
Cleanup runs background cleanup tasks, such as purging old records.
internal/db/sqldb.go:37
↓ 1 callersMethodClone
(context.Context, Executer)
internal/analyser/cloner.go:13
↓ 1 callersMethodClone
Clone implements the Cloner interface.
internal/analyser/cloner.go:28
↓ 1 callersMethodClone
Clone implements the Cloner interface.
internal/analyser/cloner.go:61
↓ 1 callersMethodDiff
Diff implements the web.VCSReader interface.
internal/github/installation.go:56
↓ 1 callersMethodExecRecorder
ExecRecorder records the analysis in the database by wrapping the executer.
internal/db/db.go:34
↓ 1 callersMethodExecute
Execute implements the Executer interface and runs commands inside a docker container.
internal/analyser/docker.go:117
↓ 1 callersFunctionFileServer
FileServer conveniently sets up a http.FileServer handler to serve static files from a http.FileSystem. https://github.com/go-chi/chi/blob/524a0204461
main.go:215
↓ 1 callersMethodGetAnalysis
GetAnalysis returns an analysis for a given analysisID, returns nil if no analysis was found, or an error occurs.
internal/db/db.go:30
↓ 1 callersMethodListTools
ListTools returns all tools. Returns nil if no tools were found, error will be non-nil if an error occurs.
internal/db/db.go:21
↓ 1 callersFunctionNew
New returns a GitHub object for use with GitHub integrations https://developer.github.com/changes/2016-09-14-Integrations-Early-Access/ integrationID
internal/github/github.go:32
↓ 1 callersFunctionNewDocker
NewDocker returns a Docker which uses imageName as a container to build projects. If memLimit is > 0, limit the amount of memory (MiB) a process insid
internal/analyser/docker.go:38
↓ 1 callersMethodNewExecuter
NewExecuter implements the Analyser interface
internal/analyser/filesystem.go:44
↓ 1 callersMethodNewExecuter
NewExecuter returns an Executer with the working directory set to $GOPATH/src/<goSrcPath>.
internal/analyser/analyser.go:28
↓ 1 callersMethodNewExecuter
NewExecuter implements Analyser interface by creating and starting a docker container.
internal/analyser/docker.go:73
↓ 1 callersFunctionNewMemoryQueue
NewMemoryQueue creates a new in memory queue
internal/queue/memory.go:21
↓ 1 callersFunctionNewMockDB
NewMockDB returns an MockDB
internal/db/mockdb.go:17
↓ 1 callersFunctionNewPRCommentReporter
NewPRCommentReporter returns a PRCommentReporter.
internal/github/reporters.go:31
↓ 1 callersFunctionNewVCS
NewVCS returns a VCSReader for a given analysis.
internal/web/vcsviewer.go:26
↓ 1 callersMethodNotFoundHandler
NotFoundHandler displays a 404 not found error
internal/web/web.go:41
↓ 1 callersFunctionPullRequestConfig
PullRequestConfig return an AnalyseConfig for a GitHub Pull Request.
internal/github/handlers.go:300
↓ 1 callersMethodRead
(context.Context, Executer)
internal/analyser/configReader.go:20
↓ 1 callersMethodRemoveGHInstallation
RemoveGHInstallation removes an installation.
internal/db/db.go:15
↓ 1 callersMethodRemoveGHInstallation
RemoveGHInstallation implements DB interface
internal/db/mockdb.go:39
↓ 1 callersMethodReport
(context.Context, []db.Issue)
internal/analyser/reporter.go:11
↓ 1 callersMethodReport
Report implements the analyser.Reporter interface.
internal/github/reporters.go:69
↓ 1 callersMethodReport
Report implements the analyser.Reporter interface.
internal/github/reporters.go:215
↓ 1 callersMethodReport
Report implements the analyser.Reporter interface.
internal/github/reporters.go:260
↓ 1 callersMethodReport
Report implements the analyser.Reporter interface.
internal/github/reporters.go:305
next →1–100 of 222, ranked by callers