repo
stringlengths
6
47
file_url
stringlengths
77
269
file_path
stringlengths
5
186
content
stringlengths
0
32.8k
language
stringclasses
1 value
license
stringclasses
7 values
commit_sha
stringlengths
40
40
retrieved_at
stringdate
2026-01-07 08:35:43
2026-01-07 08:55:24
truncated
bool
2 classes
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/lua/lua.go
internal/lua/lua.go
package lua import ( "archive/zip" "bytes" "errors" "fmt" "io" "io/ioutil" "math" "math/rand" "net" "net/http" "os" "path" "path/filepath" "regexp" "runtime" "strings" "time" "unicode/utf8" humanize "github.com/dustin/go-humanize" lua "github.com/yuin/gopher-lua" luar "layeh.com/gopher-luar" ) v...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/clipboard/clipboard.go
internal/clipboard/clipboard.go
package clipboard import ( "errors" "github.com/zyedidia/clipper" ) type Method int const ( // External relies on external tools for accessing the clipboard // These include xclip, xsel, wl-clipboard for linux, pbcopy/pbpaste on Mac, // and Syscalls on Windows. External Method = iota // Terminal uses the ter...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/clipboard/terminal.go
internal/clipboard/terminal.go
package clipboard import ( "errors" "time" "github.com/micro-editor/tcell/v2" "github.com/zyedidia/micro/v2/internal/screen" ) type terminalClipboard struct{} var terminal terminalClipboard func (t terminalClipboard) read(reg string) (string, error) { screen.Screen.GetClipboard(reg) // wait at most 200ms for...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/clipboard/multi.go
internal/clipboard/multi.go
package clipboard import ( "bytes" ) // For storing multi cursor clipboard contents type multiClipboard map[Register][]string var multi multiClipboard func (c multiClipboard) getAllText(r Register) string { content := c[r] if content == nil { return "" } buf := &bytes.Buffer{} for _, s := range content { ...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/clipboard/internal.go
internal/clipboard/internal.go
package clipboard type internalClipboard map[Register]string var internal internalClipboard func init() { internal = make(internalClipboard) } func (c internalClipboard) read(r Register) string { return c[r] } func (c internalClipboard) write(text string, r Register) { c[r] = text }
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/views/splits.go
internal/views/splits.go
package views import ( "fmt" "strings" ) type SplitType uint8 const ( STVert = 0 STHoriz = 1 STUndef = 2 ) var idcounter uint64 // NewID returns a new unique id func NewID() uint64 { idcounter++ return idcounter } // A View is a size and location of a split type View struct { X, Y int W, H int } // A N...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/views/splits_test.go
internal/views/splits_test.go
package views import ( "fmt" "testing" ) func TestHSplit(t *testing.T) { root := NewRoot(0, 0, 80, 80) n1 := root.VSplit(true) root.GetNode(n1).VSplit(true) root.GetNode(root.id).ResizeSplit(7) root.Resize(120, 120) fmt.Println(root.String()) }
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/config/plugin_manager.go
internal/config/plugin_manager.go
package config import ( "bytes" "encoding/json" "errors" ) var ( ErrMissingName = errors.New("Missing or empty name field") ErrMissingDesc = errors.New("Missing or empty description field") ErrMissingSite = errors.New("Missing or empty website field") ) // PluginInfo contains all the needed info about a plugin...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/config/globals.go
internal/config/globals.go
package config const ( DoubleClickThreshold = 400 // How many milliseconds to wait before a second click is not a double click ) var Bindings map[string]map[string]string func init() { Bindings = map[string]map[string]string{ "command": make(map[string]string), "buffer": make(map[string]string), "terminal...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/config/rtfiles.go
internal/config/rtfiles.go
package config import ( "errors" "log" "os" "path/filepath" "regexp" "strings" rt "github.com/zyedidia/micro/v2/runtime" ) const ( RTColorscheme = 0 RTSyntax = 1 RTHelp = 2 RTPlugin = 3 RTSyntaxHeader = 4 ) var ( NumTypes = 5 // How many filetypes are there ) type RTFiletype int ...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/config/config.go
internal/config/config.go
package config import ( "errors" "os" "path/filepath" homedir "github.com/mitchellh/go-homedir" ) var ConfigDir string // InitConfigDir finds the configuration directory for micro according to the XDG spec. // If no directory is found, it creates one. func InitConfigDir(flagConfigDir string) error { var e erro...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/config/plugin_installer.go
internal/config/plugin_installer.go
package config import ( "archive/zip" "bytes" "fmt" "io" "net/http" "os" "path/filepath" "sort" "strings" "sync" "github.com/blang/semver" "github.com/micro-editor/json5" lua "github.com/yuin/gopher-lua" ulua "github.com/zyedidia/micro/v2/internal/lua" "github.com/zyedidia/micro/v2/internal/util" ) va...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/config/colorscheme_test.go
internal/config/colorscheme_test.go
package config import ( "testing" "github.com/micro-editor/tcell/v2" "github.com/stretchr/testify/assert" ) func TestSimpleStringToStyle(t *testing.T) { s := StringToStyle("lightblue,magenta") fg, bg, _ := s.Decompose() assert.Equal(t, tcell.ColorBlue, fg) assert.Equal(t, tcell.ColorPurple, bg) } func Test...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/config/settings.go
internal/config/settings.go
package config import ( "encoding/json" "errors" "fmt" "os" "path/filepath" "reflect" "runtime" "strconv" "strings" "github.com/micro-editor/json5" "github.com/zyedidia/glob" "github.com/zyedidia/micro/v2/internal/util" "golang.org/x/text/encoding/htmlindex" ) type optionValidator func(string, any) erro...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/config/autosave.go
internal/config/autosave.go
package config import ( "time" ) var Autosave chan bool var autotime chan float64 func init() { Autosave = make(chan bool) autotime = make(chan float64) } func SetAutoTime(a float64) { autotime <- a } func StartAutoSave() { go func() { var a float64 var t *time.Timer var elapsed <-chan time.Time for {...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/config/plugin_installer_test.go
internal/config/plugin_installer_test.go
package config import ( "testing" "github.com/blang/semver" "github.com/micro-editor/json5" ) func TestDependencyResolving(t *testing.T) { js := ` [{ "Name": "Foo", "Versions": [{ "Version": "1.0.0" }, { "Version": "1.5.0" },{ "Version": "2.0.0" }] }, { "Name": "Bar", "Versions": [{ "Version": "1.0.0", ...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/config/rtfiles_test.go
internal/config/rtfiles_test.go
package config import ( "testing" "github.com/stretchr/testify/assert" ) func init() { InitRuntimeFiles(false) } func TestAddFile(t *testing.T) { AddRuntimeFile(RTPlugin, memoryFile{"foo.lua", []byte("hello world\n")}) AddRuntimeFile(RTSyntax, memoryFile{"bar", []byte("some syntax file\n")}) f1 := FindRuntim...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/config/colorscheme.go
internal/config/colorscheme.go
package config import ( "errors" "regexp" "strconv" "strings" "github.com/micro-editor/tcell/v2" ) // DefStyle is Micro's default style var DefStyle tcell.Style = tcell.StyleDefault // Colorscheme is the current colorscheme var Colorscheme map[string]tcell.Style // GetColor takes in a syntax group and returns...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/config/plugin.go
internal/config/plugin.go
package config import ( "errors" "log" lua "github.com/yuin/gopher-lua" ulua "github.com/zyedidia/micro/v2/internal/lua" ) // ErrNoSuchFunction is returned when Call is executed on a function that does not exist var ErrNoSuchFunction = errors.New("No such function exists") // LoadAllPlugins loads all detected p...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/shell/job.go
internal/shell/job.go
package shell import ( "bytes" "io" "os/exec" ) var Jobs chan JobFunction func init() { Jobs = make(chan JobFunction, 100) } // Jobs are the way plugins can run processes in the background // A job is simply a process that gets executed asynchronously // There are callbacks for when the job exits, when the job ...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/shell/terminal.go
internal/shell/terminal.go
package shell import ( "bytes" "os/exec" "strconv" "github.com/micro-editor/terminal" "github.com/zyedidia/micro/v2/internal/buffer" "github.com/zyedidia/micro/v2/internal/screen" ) type TermType int type CallbackFunc func(string) const ( TTClose = iota // Should be closed TTRunning // Currently ru...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/shell/shell.go
internal/shell/shell.go
package shell import ( "bytes" "errors" "fmt" "io" "os" "os/exec" "os/signal" shellquote "github.com/kballard/go-shellquote" "github.com/zyedidia/micro/v2/internal/screen" "github.com/zyedidia/micro/v2/internal/util" ) // ExecCommand executes a command using exec // It returns any output/errors func ExecCo...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/info/infobuffer.go
internal/info/infobuffer.go
package info import ( "fmt" "github.com/zyedidia/micro/v2/internal/buffer" ) // The InfoBuf displays messages and other info at the bottom of the screen. // It is represented as a buffer and a message with a style. type InfoBuf struct { *buffer.Buffer HasPrompt bool HasMessage bool HasError bool HasYN ...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/info/history.go
internal/info/history.go
package info import ( "bytes" "encoding/gob" "errors" "io/fs" "os" "path/filepath" "strings" "github.com/zyedidia/micro/v2/internal/config" "github.com/zyedidia/micro/v2/internal/screen" "github.com/zyedidia/micro/v2/internal/util" ) // LoadHistory attempts to load user history from configDir/buffers/histo...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/info/gutter.go
internal/info/gutter.go
package info // A GutterMessage is a message displayed on the side of the editor type GutterMessage struct { lineNum int msg string kind int } // These are the different types of messages const ( // GutterInfo represents a simple info message GutterInfo = iota // GutterWarning represents a compiler warni...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/buffer/buffer_generated_test.go
internal/buffer/buffer_generated_test.go
// This file is generated from VSCode model tests by the testgen tool. // DO NOT EDIT THIS FILE BY HAND; your changes will be overwritten! package buffer import "testing" func TestAuto1(t *testing.T) { check( t, []string{ "ioe", "", "yjct", "", "", }, []operation{ { start: Loc{1, 0}, ...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/buffer/line_array.go
internal/buffer/line_array.go
package buffer import ( "bufio" "bytes" "io" "sync" "github.com/zyedidia/micro/v2/internal/util" "github.com/zyedidia/micro/v2/pkg/highlight" ) // Finds the byte index of the nth rune in a byte slice func runeToByteIndex(n int, txt []byte) int { if n == 0 { return 0 } count := 0 i := 0 for len(txt) > 0...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/buffer/line_array_test.go
internal/buffer/line_array_test.go
package buffer import ( "strings" "testing" "github.com/stretchr/testify/assert" ) var unicode_txt = `An preost wes on leoden, Laȝamon was ihoten He wes Leovenaðes sone -- liðe him be Drihten. He wonede at Ernleȝe at æðelen are chirechen, Uppen Sevarne staþe, sel þar him þuhte, Onfest Radestone, þer he bock radde...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/buffer/buffer.go
internal/buffer/buffer.go
package buffer import ( "bufio" "bytes" "crypto/md5" "errors" "fmt" "io" "io/fs" "os" "path/filepath" "strconv" "strings" "sync" "time" luar "layeh.com/gopher-luar" dmp "github.com/sergi/go-diff/diffmatchpatch" "github.com/zyedidia/micro/v2/internal/config" ulua "github.com/zyedidia/micro/v2/interna...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
true
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/buffer/autocomplete.go
internal/buffer/autocomplete.go
package buffer import ( "bytes" "io/fs" "os" "sort" "strings" "github.com/zyedidia/micro/v2/internal/util" ) // A Completer is a function that takes a buffer and returns info // describing what autocompletions should be inserted at the current // cursor location // It returns a list of string suggestions which...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/buffer/eventhandler.go
internal/buffer/eventhandler.go
package buffer import ( "bytes" "time" dmp "github.com/sergi/go-diff/diffmatchpatch" "github.com/zyedidia/micro/v2/internal/config" ulua "github.com/zyedidia/micro/v2/internal/lua" "github.com/zyedidia/micro/v2/internal/screen" "github.com/zyedidia/micro/v2/internal/util" luar "layeh.com/gopher-luar" ) const...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/buffer/settings.go
internal/buffer/settings.go
package buffer import ( "crypto/md5" "reflect" "github.com/zyedidia/micro/v2/internal/config" ulua "github.com/zyedidia/micro/v2/internal/lua" "github.com/zyedidia/micro/v2/internal/screen" "golang.org/x/text/encoding/htmlindex" "golang.org/x/text/encoding/unicode" luar "layeh.com/gopher-luar" ) func (b *Buf...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/buffer/stack.go
internal/buffer/stack.go
package buffer // TEStack is a simple implementation of a LIFO stack for text events type TEStack struct { Top *Element Size int } // An Element which is stored in the Stack type Element struct { Value *TextEvent Next *Element } // Len returns the stack's length func (s *TEStack) Len() int { return s.Size } ...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/buffer/buffer_test.go
internal/buffer/buffer_test.go
package buffer import ( "math/rand" "strings" "testing" "github.com/stretchr/testify/assert" lua "github.com/yuin/gopher-lua" "github.com/zyedidia/micro/v2/internal/config" ulua "github.com/zyedidia/micro/v2/internal/lua" "github.com/zyedidia/micro/v2/internal/util" ) type operation struct { start Loc end ...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/buffer/search.go
internal/buffer/search.go
package buffer import ( "regexp" "unicode/utf8" "github.com/zyedidia/micro/v2/internal/util" ) // We want "^" and "$" to match only the beginning/end of a line, not the // beginning/end of the search region if it is in the middle of a line. // In that case we use padded regexps to require a rune before or after /...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/buffer/backup.go
internal/buffer/backup.go
package buffer import ( "errors" "fmt" "io/fs" "os" "path/filepath" "github.com/zyedidia/micro/v2/internal/config" "github.com/zyedidia/micro/v2/internal/screen" "github.com/zyedidia/micro/v2/internal/util" ) const BackupMsg = `A backup was detected for: %s This likely means that micro crashed while editin...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/buffer/cursor.go
internal/buffer/cursor.go
package buffer import ( "github.com/zyedidia/micro/v2/internal/clipboard" "github.com/zyedidia/micro/v2/internal/util" ) // InBounds returns whether the given location is a valid character position in the given buffer func InBounds(pos Loc, buf *Buffer) bool { if pos.Y < 0 || pos.Y >= len(buf.lines) || pos.X < 0 |...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/buffer/stack_test.go
internal/buffer/stack_test.go
package buffer import ( "testing" "time" "github.com/stretchr/testify/assert" ) func TestStack(t *testing.T) { s := new(TEStack) e1 := &TextEvent{ EventType: TextEventReplace, Time: time.Now(), } e2 := &TextEvent{ EventType: TextEventInsert, Time: time.Now(), } s.Push(e1) s.Push(e2) p :...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/buffer/message.go
internal/buffer/message.go
package buffer import ( "github.com/micro-editor/tcell/v2" "github.com/zyedidia/micro/v2/internal/config" ) type MsgType int const ( MTInfo = iota MTWarning MTError ) // Message represents the information for a gutter message type Message struct { // The Msg iteslf Msg string // Start and End locations for ...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/buffer/loc.go
internal/buffer/loc.go
package buffer import ( "github.com/zyedidia/micro/v2/internal/util" ) // Loc stores a location type Loc struct { X, Y int } // LessThan returns true if b is smaller func (l Loc) LessThan(b Loc) bool { if l.Y < b.Y { return true } return l.Y == b.Y && l.X < b.X } // GreaterThan returns true if b is bigger fu...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/buffer/serialize.go
internal/buffer/serialize.go
package buffer import ( "bytes" "encoding/gob" "errors" "os" "path/filepath" "time" "github.com/zyedidia/micro/v2/internal/config" "github.com/zyedidia/micro/v2/internal/util" ) // The SerializedBuffer holds the types that get serialized when a buffer is saved // These are used for the savecursor and saveund...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
zyedidia/micro
https://github.com/zyedidia/micro/blob/6a62575bcfdf4965f187eedafceb3400316e612b/internal/buffer/save.go
internal/buffer/save.go
package buffer import ( "bufio" "bytes" "errors" "io" "io/fs" "os" "os/exec" "os/signal" "path/filepath" "runtime" "time" "unicode" "github.com/zyedidia/micro/v2/internal/config" "github.com/zyedidia/micro/v2/internal/screen" "github.com/zyedidia/micro/v2/internal/util" "golang.org/x/text/transform" )...
go
MIT
6a62575bcfdf4965f187eedafceb3400316e612b
2026-01-07T08:37:16.157226Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/bind_test.go
bind_test.go
//nolint:wrapcheck,tagliatelle // We must not wrap errors in tests package fiber import ( "bytes" "compress/gzip" "encoding/json" "errors" "fmt" "mime/multipart" "net/http" "net/http/httptest" "reflect" "strings" "testing" "time" "github.com/fxamacker/cbor/v2" "github.com/gofiber/fiber/v3/binder" "gith...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
true
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/constants.go
constants.go
package fiber // HTTP methods were copied from net/http. const ( MethodGet = "GET" // RFC 7231, 4.3.1 MethodHead = "HEAD" // RFC 7231, 4.3.2 MethodPost = "POST" // RFC 7231, 4.3.3 MethodPut = "PUT" // RFC 7231, 4.3.4 MethodPatch = "PATCH" // RFC 5789 MethodDelete = "DELETE" // R...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/res_interface_gen.go
res_interface_gen.go
// Code generated by ifacemaker; DO NOT EDIT. package fiber import ( "bufio" "io" "github.com/valyala/fasthttp" ) // Res is an interface for response-related Ctx methods. type Res interface { // App returns the *App reference to the instance of the Fiber application App() *App // Append the specified value to...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/path.go
path.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 📄 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io // ⚠️ This path parser was inspired by https://github.com/ucarion/urlpath // 💖 Maintained and modified for Fiber by @renewerner87 package fi...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/error.go
error.go
package fiber import ( "encoding/json" "errors" "github.com/gofiber/schema" ) // Wrap and return this for unreachable code if panicking is undesirable (i.e., in a handler). // Unexported because users will hopefully never need to see it. var errUnreachable = errors.New("fiber: unreachable code, please create an i...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/group.go
group.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 🤖 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io package fiber import ( "fmt" "reflect" ) // Group represents a collection of routes that share middleware and a common // path prefix. ty...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/bind.go
bind.go
package fiber import ( "reflect" "slices" "sync" "github.com/gofiber/fiber/v3/binder" "github.com/gofiber/utils/v2" ) // CustomBinder An interface to register custom binders. type CustomBinder interface { Name() string MIMETypes() []string Parse(c Ctx, out any) error } // StructValidator is an interface to ...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/helpers_fuzz_test.go
helpers_fuzz_test.go
//go:build go1.18 package fiber import ( "testing" ) // go test -v -run=^$ -fuzz=FuzzUtilsGetOffer func FuzzUtilsGetOffer(f *testing.F) { inputs := []string{ `application/json; v=1; foo=bar; q=0.938; extra=param, text/plain;param="big fox"; q=0.43`, `text/html, application/xhtml+xml, application/xml;q=0.9, */*...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/redirect_msgp_test.go
redirect_msgp_test.go
package fiber // Code generated by github.com/tinylib/msgp DO NOT EDIT. import ( "bytes" "testing" "github.com/tinylib/msgp/msgp" ) func TestMarshalUnmarshalredirectionMsg(t *testing.T) { v := redirectionMsg{} bts, err := v.MarshalMsg(nil) if err != nil { t.Fatal(err) } left, err := v.UnmarshalMsg(bts) i...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/services_test.go
services_test.go
package fiber import ( "bytes" "context" "errors" "fmt" "strings" "testing" "time" "github.com/gofiber/fiber/v3/log" "github.com/stretchr/testify/require" ) const ( terminateErrorMessage = "terminate error" startErrorMessage = "start error" ) // mockService implements Service interface for testing ty...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/app_integration_test.go
app_integration_test.go
package fiber_test import ( "bytes" "errors" "net" "strconv" "strings" "testing" "time" "github.com/stretchr/testify/require" "github.com/gofiber/fiber/v3" "github.com/gofiber/fiber/v3/middleware/basicauth" "github.com/gofiber/fiber/v3/middleware/cache" "github.com/gofiber/fiber/v3/middleware/compress" ...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/error_test.go
error_test.go
package fiber import ( "encoding/json" "errors" "testing" "github.com/gofiber/schema" "github.com/stretchr/testify/require" ) func Test_ConversionError(t *testing.T) { t.Parallel() ok := errors.As(ConversionError{}, &schema.ConversionError{}) require.True(t, ok) } func Test_UnknownKeyError(t *testing.T) { ...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/prefork.go
prefork.go
package fiber import ( "crypto/tls" "errors" "fmt" "net" "os" "os/exec" "runtime" "sync/atomic" "time" "github.com/valyala/fasthttp/reuseport" "github.com/gofiber/fiber/v3/log" ) const ( envPreforkChildKey = "FIBER_PREFORK_CHILD" envPreforkChildVal = "1" sleepDuration = 100 * time.Millisecond wi...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/readonly.go
readonly.go
//go:build !s390x && !ppc64 && !ppc64le package fiber import ( "unsafe" ) //go:linkname runtimeRodata runtime.rodata var runtimeRodata byte //go:linkname runtimeErodata runtime.erodata var runtimeErodata byte func isReadOnly(p unsafe.Pointer) bool { start := uintptr(unsafe.Pointer(&runtimeRodata)) //nolint:gosec...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/redirect_test.go
redirect_test.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 📝 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io package fiber import ( "bytes" "encoding/hex" "encoding/json" "io" "mime/multipart" "net/http" "net/http/httptest" "net/url" "strin...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/register.go
register.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 🤖 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io package fiber // Register defines all router handle interface generate by RouteChain(). type Register interface { All(handler any, handlers...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/router.go
router.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 🤖 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io package fiber import ( "bytes" "fmt" "slices" "sync/atomic" "github.com/gofiber/utils/v2" "github.com/valyala/fasthttp" ) // flashCo...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/req.go
req.go
package fiber import ( "bytes" "errors" "fmt" "math" "mime/multipart" "net" "strconv" "strings" "github.com/gofiber/utils/v2" "github.com/valyala/fasthttp" "golang.org/x/net/idna" ) // Pre-allocated byte slices for common header comparisons to avoid allocations var ( xForwardedPrefix = []byte("X-F...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/state.go
state.go
package fiber import ( "encoding/hex" "strings" "sync" "github.com/google/uuid" ) const servicesStatePrefix = "gofiber-services-" var servicesStatePrefixHash string func init() { servicesStatePrefixHash = hex.EncodeToString([]byte(servicesStatePrefix + uuid.New().String())) } // State is a key-value store fo...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/ctx_interface.go
ctx_interface.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 🤖 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io package fiber import ( "github.com/valyala/fasthttp" ) // CustomCtx extends Ctx with the additional methods required by Fiber's // interna...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/helpers_test.go
helpers_test.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 📝 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io package fiber import ( "math" "strconv" "testing" "time" "unsafe" "github.com/gofiber/utils/v2" "github.com/stretchr/testify/require...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
true
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/redirect_msgp.go
redirect_msgp.go
package fiber // Code generated by github.com/tinylib/msgp DO NOT EDIT. import ( "github.com/tinylib/msgp/msgp" ) // DecodeMsg implements msgp.Decodable func (z *redirectionMsg) DecodeMsg(dc *msgp.Reader) (err error) { var field []byte _ = field var zb0001 uint32 zb0001, err = dc.ReadMapHeader() if err != nil ...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/path_test.go
path_test.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 📝 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io package fiber import ( "testing" "github.com/stretchr/testify/require" ) // go test -race -run Test_Path_parseRoute func Test_Path_parse...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/state_test.go
state_test.go
package fiber import ( "strconv" "testing" "github.com/stretchr/testify/require" ) func TestState_SetAndGet_WithApp(t *testing.T) { t.Parallel() // Create app app := New() // test setting and getting a value app.State().Set("foo", "bar") val, ok := app.State().Get("foo") require.True(t, ok) require.Equal...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/req_interface_gen.go
req_interface_gen.go
// Code generated by ifacemaker; DO NOT EDIT. package fiber import ( "mime/multipart" "github.com/valyala/fasthttp" ) // Req is an interface for request-related Ctx methods. type Req interface { // Accepts checks if the specified extensions or content types are acceptable. Accepts(offers ...string) string // A...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/color.go
color.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 🤖 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io package fiber // Colors is a struct to define custom colors for Fiber app and middlewares. type Colors struct { // Black color. // // Opt...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/ctx.go
ctx.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 🤖 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io package fiber import ( "context" "crypto/tls" "fmt" "io" "maps" "mime/multipart" "strconv" "strings" "time" "github.com/gofiber/u...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/path_testcases_test.go
path_testcases_test.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 📝 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io package fiber import ( "strings" ) type routeTestCase struct { url string params []string match bool partialChec...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/ctx_test.go
ctx_test.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 🤖 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io package fiber import ( "bufio" "bytes" "compress/gzip" "compress/zlib" "context" "crypto/tls" "embed" "encoding/hex" "encoding/xml"...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
true
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/readonly_strict.go
readonly_strict.go
//go:build s390x || ppc64 || ppc64le package fiber import "unsafe" func isReadOnly(_ unsafe.Pointer) bool { return false }
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/listen.go
listen.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 🤖 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io package fiber import ( "context" "crypto/tls" "crypto/x509" "fmt" "io" "net" "os" "path/filepath" "reflect" "runtime" "slices" "...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/mount_test.go
mount_test.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 🤖 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io package fiber import ( "errors" "io" "net/http" "net/http/httptest" "testing" "github.com/stretchr/testify/require" ) // go test -ru...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/errors_internal.go
errors_internal.go
package fiber import ( "errors" ) var ( errBindPoolTypeAssertion = errors.New("failed to type-assert to *Bind") errCustomCtxTypeAssertion = errors.New("failed to type-assert to CustomCtx") errTLSConfigTypeAssertion = errors.New("failed to type-assert to *tls.Config") errInvalidEscapeSequence = errors.New("inva...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/hooks_test.go
hooks_test.go
package fiber import ( "bytes" "errors" "os" "runtime" "testing" "time" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" "github.com/valyala/bytebufferpool" "github.com/gofiber/fiber/v3/log" ) const testMountPath = "/api" func testSimpleHandler(c Ctx) error { return c.SendStrin...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/res.go
res.go
package fiber import ( "bufio" "bytes" "fmt" "html/template" "io" "io/fs" "net/http" "net/url" "os" pathpkg "path" "path/filepath" "strconv" "strings" "time" "github.com/gofiber/utils/v2" "github.com/valyala/bytebufferpool" "github.com/valyala/fasthttp" ) // SendFile defines configuration options wh...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
true
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/redirect.go
redirect.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 📝 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io package fiber import ( "encoding/hex" "sync" "github.com/gofiber/fiber/v3/binder" "github.com/gofiber/utils/v2" "github.com/valyala/by...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/mount.go
mount.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 🤖 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io package fiber import ( "sort" "sync" "sync/atomic" "github.com/gofiber/utils/v2" ) // Put fields related to mounting. type mountFields...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/hooks.go
hooks.go
package fiber import ( "slices" "github.com/gofiber/fiber/v3/log" ) type ( // OnRouteHandler defines the hook signature invoked whenever a route is registered. OnRouteHandler = func(Route) error // OnNameHandler shares the OnRouteHandler signature for route naming callbacks. OnNameHandler = OnRouteHandler // ...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/storage_interface.go
storage_interface.go
package fiber import ( "context" "time" ) // Storage interface for communicating with different database/key-value // providers type Storage interface { // GetWithContext gets the value for the given key with a context. // `nil, nil` is returned when the key does not exist GetWithContext(ctx context.Context, key...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/services.go
services.go
package fiber import ( "context" "errors" "fmt" "io" "github.com/gofiber/utils/v2" ) // Service is an interface that defines the methods for a service. type Service interface { // Start starts the service, returning an error if it fails. Start(ctx context.Context) error // String returns a string representa...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/router_test.go
router_test.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 📃 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io package fiber import ( "context" "encoding/json" "errors" "io" "net/http" "net/http/httptest" "os" "reflect" "runtime" "strings" ...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
true
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/prefork_test.go
prefork_test.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 📄 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io // 💖 Maintained and modified for Fiber by @renewerner87 package fiber import ( "crypto/tls" "io" "os" "testing" "time" "github.com/st...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/adapter.go
adapter.go
package fiber import ( "fmt" "net/http" "reflect" "github.com/valyala/fasthttp" "github.com/valyala/fasthttp/fasthttpadaptor" ) // toFiberHandler converts a supported handler type to a Fiber handler. func toFiberHandler(handler any) (Handler, bool) { if handler == nil { return nil, false } switch handler....
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/app_test.go
app_test.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 🤖 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io package fiber import ( "bufio" "bytes" "context" "crypto/tls" "errors" "fmt" "io" "mime/multipart" "net" "net/http" "net/http/htt...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
true
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/listen_test.go
listen_test.go
package fiber import ( "bytes" "context" "crypto/tls" "errors" "fmt" "io" "log" //nolint:depguard // TODO: Required to capture output, use internal log package instead "net" "os" "path/filepath" "sync" "testing" "time" "github.com/gofiber/utils/v2" "github.com/stretchr/testify/assert" "github.com/stre...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/ctx_interface_gen.go
ctx_interface_gen.go
// Code generated by ifacemaker; DO NOT EDIT. package fiber import ( "bufio" "context" "crypto/tls" "io" "mime/multipart" "time" "github.com/valyala/fasthttp" ) // Ctx represents the Context which hold the HTTP request and response. // It has methods for the request query string, parameters, body, HTTP heade...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/app.go
app.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 🤖 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io // Package fiber is an Express inspired web framework built on top of Fasthttp, // the fastest HTTP engine for Go. Designed to ease things up...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
true
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/helpers.go
helpers.go
// ⚡️ Fiber is an Express inspired web framework written in Go with ☕️ // 🤖 GitHub Repository: https://github.com/gofiber/fiber // 📌 API Documentation: https://docs.gofiber.io package fiber import ( "bytes" "crypto/tls" "errors" "fmt" "io" "net" "os" "path/filepath" "reflect" "slices" "strconv" "strings...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/adapter_test.go
adapter_test.go
package fiber import ( "errors" "fmt" "io" "net/http" "net/http/httptest" "reflect" "testing" "time" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" "github.com/valyala/fasthttp" ) func TestToFiberHandler_Nil(t *testing.T) { t.Parallel() var handler Handler converted, ok := ...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/middleware/adaptor/adaptor_test.go
middleware/adaptor/adaptor_test.go
//nolint:contextcheck,revive // Much easier to just ignore memory leaks in tests package adaptor import ( "bufio" "bytes" "context" "errors" "fmt" "io" "net" "net/http" "net/http/httptest" "net/url" "os" "path/filepath" "strings" "testing" "time" "github.com/gofiber/fiber/v3" "github.com/stretchr/tes...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
true
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/middleware/adaptor/adaptor.go
middleware/adaptor/adaptor.go
package adaptor import ( "context" "errors" "fmt" "io" "net" "net/http" "reflect" "sync" "unsafe" "github.com/gofiber/fiber/v3" "github.com/gofiber/utils/v2" "github.com/valyala/fasthttp" "github.com/valyala/fasthttp/fasthttpadaptor" ) // disableLogger implements the fasthttp Logger interface and discar...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/middleware/recover/recover.go
middleware/recover/recover.go
package recover //nolint:predeclared // TODO: Rename to some non-builtin import ( "fmt" "os" "runtime/debug" "github.com/gofiber/fiber/v3" ) func defaultStackTraceHandler(_ fiber.Ctx, e any) { fmt.Fprintf(os.Stderr, "panic: %v\n\n%s\n", e, debug.Stack()) } // New creates a new middleware handler func New(confi...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/middleware/recover/config.go
middleware/recover/config.go
package recover //nolint:predeclared // TODO: Rename to some non-builtin import ( "github.com/gofiber/fiber/v3" ) // Config defines the config for middleware. type Config struct { // Next defines a function to skip this middleware when returned true. // // Optional. Default: nil Next func(c fiber.Ctx) bool // ...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/middleware/recover/recover_test.go
middleware/recover/recover_test.go
package recover //nolint:predeclared // TODO: Rename to some non-builtin import ( "net/http" "net/http/httptest" "testing" "github.com/gofiber/fiber/v3" "github.com/stretchr/testify/require" ) // go test -run Test_Recover func Test_Recover(t *testing.T) { t.Parallel() app := fiber.New(fiber.Config{ ErrorHan...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/middleware/static/static.go
middleware/static/static.go
package static import ( "bytes" "errors" "fmt" "io/fs" "net/url" "os" pathpkg "path" "path/filepath" "strconv" "strings" "sync" "github.com/gofiber/utils/v2" "github.com/valyala/fasthttp" "github.com/gofiber/fiber/v3" ) var ErrInvalidPath = errors.New("invalid path") // sanitizePath validates and cle...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/middleware/static/config.go
middleware/static/config.go
package static import ( "io/fs" "time" "github.com/gofiber/fiber/v3" ) // Config defines the config for middleware. type Config struct { // FS is the file system to serve the static files from. // You can use interfaces compatible with fs.FS like embed.FS, os.DirFS etc. // // Optional. Default: nil FS fs.FS ...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/middleware/static/static_test.go
middleware/static/static_test.go
package static import ( "embed" "io" "io/fs" "net/http" "net/http/httptest" "net/url" "os" "path/filepath" "runtime" "strings" "testing" "time" "github.com/stretchr/testify/require" "github.com/gofiber/fiber/v3" ) const ( winOS = "windows" testCSSDir = "../../.github/testdata/fs/css" ) var tes...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
true
gofiber/fiber
https://github.com/gofiber/fiber/blob/2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d/middleware/expvar/expvar_test.go
middleware/expvar/expvar_test.go
package expvar import ( "bytes" "io" "net/http" "net/http/httptest" "testing" "github.com/gofiber/fiber/v3" "github.com/stretchr/testify/require" ) func Test_Non_Expvar_Path(t *testing.T) { t.Parallel() app := fiber.New() app.Use(New()) app.Get("/", func(c fiber.Ctx) error { return c.SendString("escap...
go
MIT
2e37e61ca4a4ce0ab8e7ca72e7ea52409db55d5d
2026-01-07T08:35:58.039181Z
false