diff --git a/cmd/feynman/main.go b/cmd/feynman/main.go new file mode 100644 index 0000000..90dd391 --- /dev/null +++ b/cmd/feynman/main.go @@ -0,0 +1,31 @@ +package main + +import "flag" + +type arguments struct { + buildDeps bool + library bool + output string + depsPath string + test bool +} + +func main() { + initArgs() +} +func initArgs() *arguments { + b := flag.Bool("b", false, "Enables building dependencies from source, instead of searching for already compiled binaries in the library path.") + l := flag.Bool("l", false, "Determines if the output should be placed in the standard dependency crate path.") + o := flag.String("o", "build", "Output path for this compilation. Should only be used for binaries.") + p := flag.String("p", "/usr/lib/feynman", "Library path root.") + t := flag.Bool("t", false, "Enables tests. Does not run Cargo benchmarks or examples.") + + flag.Parse() + return &arguments{ + buildDeps: *b, + library: *l, + output: *o, + depsPath: *p, + test: *t, + } +} diff --git a/lockfile.go b/internal/cargo/lockfile.go similarity index 94% rename from lockfile.go rename to internal/cargo/lockfile.go index 6d28666..2840fc1 100644 --- a/lockfile.go +++ b/internal/cargo/lockfile.go @@ -1,4 +1,4 @@ -package feynman +package cargo type CargoLock struct { Packages []LockPackage `toml:"package"` diff --git a/manifest.go b/internal/cargo/manifest.go similarity index 99% rename from manifest.go rename to internal/cargo/manifest.go index bb59c42..d711055 100644 --- a/manifest.go +++ b/internal/cargo/manifest.go @@ -1,4 +1,4 @@ -package feynman +package cargo type CargoManifest struct { Package `toml:"package"`