
Product
Introducing Scala and Kotlin Support in Socket
Socket now supports Scala and Kotlin, bringing AI-powered threat detection to JVM projects with easy manifest generation and fast, accurate scans.
github.com/xlab/handysort
:exclamation: WARNING: 13x slower than https://github.com/fvbommel/util/tree/master/sortorder
This is a Go package implementing a correct comparison function to compare alphanumeric strings with respect to their integer parts.
For example, this is default result of strings sort:
hello1
hello10
hello11
hello2
hello3
This is handysort:
hello1
hello2
hello3
hello10
hello11
However, this is about 5x-8x times slower than the default sort version. (benchmarks available)
package main
import (
"github.com/xlab/handysort"
"sort"
)
func main() {
s1, s2 := "hello2", "hello10"
// instead of s1 < s2
less := handysort.StringLess(s1, s2)
s := []string{"hello5", "hello10", "hello1"}
// instead of sort.Strings
sort.Sort(handysort.Strings(s))
}
$ go test -bench=.
FAQs
Unknown package
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Product
Socket now supports Scala and Kotlin, bringing AI-powered threat detection to JVM projects with easy manifest generation and fast, accurate scans.
Application Security
/Security News
Socket CEO Feross Aboukhadijeh and a16z partner Joel de la Garza discuss vibe coding, AI-driven software development, and how the rise of LLMs, despite their risks, still points toward a more secure and innovative future.
Research
/Security News
Threat actors hijacked Toptal’s GitHub org, publishing npm packages with malicious payloads that steal tokens and attempt to wipe victim systems.