⛩️ Powerful yet Minimal Nix Dependency Manager
flake flakes home-manager nixos go nix dependency dependencies

feat(yae): add file not found and init information

fuwn.net 7df9be2d 27af3b90

verified
+10 -1
+10 -1
yae.go
··· 30 30 return nil 31 31 } 32 32 33 - return sources.Load(c.String("sources")) 33 + location := c.String("sources") 34 + 35 + if _, err := os.Stat(location); os.IsNotExist(err) { 36 + return fmt.Errorf( 37 + "file `%s` was not present, run `yae init` to create it", 38 + location, 39 + ) 40 + } 41 + 42 + return sources.Load(location) 34 43 }, 35 44 Flags: []cli.Flag{ 36 45 &cli.StringFlag{