bb/tool/sort/sort.go

19 lines
248 B
Go
Raw Normal View History

package sort
import (
"fmt"
"os"
"sort"
2024-01-05 03:45:34 +03:00
"vultras.su/util/bb/input"
2024-01-05 03:22:55 +03:00
"vultras.su/core/cli/mtool"
)
2023-03-24 16:54:51 +03:00
func Run(flagSet *mtool.Flags) {
lines, _ := input.ReadAllLines(os.Stdin)
sort.Strings(lines)
for _, l := range lines {
fmt.Print(l)
}
}