Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/Code-Hex/golet
/ functions
Functions
65 in github.com/Code-Hex/golet
⨍
Functions
65
◇
Types & classes
7
↓ 7 callers
Method
Done
Done is implemented for context.Context
context.go:75
↓ 6 callers
Method
Add
(...Service)
golet.go:80
↓ 6 callers
Method
Printf
Printf formats according to a format specifier and writes to golet writer It returns the number of bytes written and any write error encountered.
context.go:53
↓ 5 callers
Function
New
New to create struct of golet.
golet.go:116
↓ 5 callers
Method
Println
Println formats using the default formats for its operands and writes to golet writer. Spaces are always added between operands and a newline is appen
context.go:40
↓ 3 callers
Method
Port
Port returns assgined port
context.go:18
↓ 3 callers
Method
notifySignal
()
signalctx.go:18
↓ 3 callers
Function
run
Execute the command and send its process ID.
golet.go:331
↓ 3 callers
Function
sendSignal2Procs
sendSignal2Procs can send signal and replace os.Process struct of the terminated process with nil
golet.go:318
↓ 2 callers
Method
Env
(map[string]string)
golet.go:79
↓ 2 callers
Method
Run
()
golet.go:81
↓ 2 callers
Method
Signal
Signal returns os.Signal and error.
context.go:63
↓ 2 callers
Method
Write
Improved io.writer for golet
logger.go:18
↓ 2 callers
Method
isCron
()
service.go:52
↓ 2 callers
Method
prepare
Create a command
service.go:34
↓ 2 callers
Method
wait
Wait services
golet.go:364
↓ 2 callers
Method
waitSignals
Receive process ID to be executed. or It traps the signal relate to parent process. sends a signal to the received process ID.
golet.go:280
↓ 2 callers
Method
write
(data []byte)
logger.go:33
↓ 1 callers
Method
Copy
Copy method is wrapped by io.Copy
context.go:28
↓ 1 callers
Method
EnableColor
()
golet.go:74
↓ 1 callers
Function
IsPortAvailable
IsPortAvailable returns a flag is TCP port available.
internal/port/port.go:18
↓ 1 callers
Method
Recv
Recv send channel when a process receives a signal.
context.go:58
↓ 1 callers
Method
ServePort
ServePort returns assigned port which is serve format
context.go:23
↓ 1 callers
Function
ServiceGen
()
golet_test.go:131
↓ 1 callers
Method
SetCtxCancelSignal
(syscall.Signal)
golet.go:78
↓ 1 callers
Method
SetInterval
(time.Duration)
golet.go:73
↓ 1 callers
Method
addCmd
Add a task to execute the command to cron.
golet.go:340
↓ 1 callers
Method
addTask
Add a task to execute the code block to cron.
golet.go:351
↓ 1 callers
Method
executeCallback
executeCallback run callback as goroutine or cron
golet.go:247
↓ 1 callers
Method
executeRun
executeRun run command as a process
golet.go:209
↓ 1 callers
Method
isCode
()
service.go:48
↓ 1 callers
Method
isExecute
()
service.go:44
↓ 1 callers
Function
serveCode
()
eg/main.go:61
Method
Add
Add can add runnable services
golet.go:147
Method
Deadline
* They are methods for context.Context */ Deadline is implemented for context.Context
signalctx.go:48
Method
Deadline
* They are methods for context.Context */ Deadline is implemented for context.Context
context.go:70
Method
DisableExecNotice
()
golet.go:77
Method
DisableExecNotice
DisableExecNotice is disable execute notifications.
golet.go:109
Method
DisableLogger
()
golet.go:76
Method
DisableLogger
DisableLogger is prevent to output log.
golet.go:106
Method
Done
Done is implemented for context.Context
signalctx.go:53
Method
EnableColor
EnableColor can output colored log.
golet.go:89
Method
Env
Env can add temporary environment variables.
golet.go:137
Method
Err
Err is implemented for context.Context
signalctx.go:58
Method
Err
Err is implemented for context.Context
context.go:80
Function
GetPort
GetPort gets a free TCP port between 1024-65535.
internal/port/port.go:31
Method
Print
Print formats using the default formats for its operands and writes to golet writer. Spaces are added between operands when neither is a string. It re
context.go:47
Method
Recv
Recv send channel when a process receives a signal
signalctx.go:28
Method
Run
Run just like the name.
golet.go:185
Method
SetCtxCancelSignal
SetCtxCancelSignal can specify the signal to send processes when context cancel. If you do not set, golet will not send the signal when context cancel
golet.go:113
Method
SetInterval
for settings SetInterval can specify the interval at which the command is executed.
golet.go:86
Method
SetLogger
(io.Writer)
golet.go:75
Method
SetLogger
SetLogger can specify the io.Writer for example in https://github.com/lestrrat/go-file-rotatelogs * logf, _ := rotatelogs.New( "/path/to/
golet.go:103
Method
Signal
Signal returns os.Signal and error.
signalctx.go:39
Function
TestAdd
(t *testing.T)
golet_test.go:52
Function
TestDefault
(t *testing.T)
golet_test.go:21
Function
TestEnv
(t *testing.T)
golet_test.go:31
Function
TestWait
(t *testing.T)
golet_test.go:79
Method
Value
Value is implemented for context.Context
signalctx.go:63
Method
Value
Value is implemented for context.Context
context.go:85
Method
Write
Improved io.writer for golet
context.go:33
Method
createContext
(ctx *signalCtx, logger *Logger, port int)
service.go:24
Function
init
()
golet.go:55
Function
main
()
_testdata/sleep.go:9
Function
main
()
eg/main.go:14