mirror of
https://github.com/schollz/croc.git
synced 2025-10-11 05:11:06 +02:00
use all procs
This commit is contained in:
parent
7fea858252
commit
a7b8488040
2 changed files with 5 additions and 2 deletions
2
main.go
2
main.go
|
@ -8,7 +8,6 @@ import (
|
||||||
"log"
|
"log"
|
||||||
"os"
|
"os"
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
"runtime"
|
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
humanize "github.com/dustin/go-humanize"
|
humanize "github.com/dustin/go-humanize"
|
||||||
|
@ -23,7 +22,6 @@ var codePhrase string
|
||||||
var cr *croc.Croc
|
var cr *croc.Croc
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
runtime.GOMAXPROCS(runtime.NumCPU())
|
|
||||||
app := cli.NewApp()
|
app := cli.NewApp()
|
||||||
app.Name = "croc"
|
app.Name = "croc"
|
||||||
if version == "" {
|
if version == "" {
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
package croc
|
package croc
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"runtime"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/schollz/croc/src/logger"
|
"github.com/schollz/croc/src/logger"
|
||||||
|
@ -10,6 +11,10 @@ import (
|
||||||
"github.com/schollz/croc/src/zipper"
|
"github.com/schollz/croc/src/zipper"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
func init() {
|
||||||
|
runtime.GOMAXPROCS(runtime.NumCPU())
|
||||||
|
}
|
||||||
|
|
||||||
// Croc options
|
// Croc options
|
||||||
type Croc struct {
|
type Croc struct {
|
||||||
// Options for all
|
// Options for all
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue