Skip to content

Implement "fpm init" to create the initial project skeleton #96

@certik

Description

@certik

It would work just like cargo init:

$ cargo init myproject1
     Created binary (application) package
$ tree -a myproject1
myproject1
├── Cargo.toml
├── .git
│   ├── config
│   ...
├── .gitignore
└── src
    └── main.rs

10 directories, 18 files

As you can see, it starts a git repository, and so on. It is ready to compile, so:

~$ cd myproject1
myproject1(master)$ cat src/main.rs 
fn main() {
    println!("Hello, world!");
}
myproject1(master)$ cargo run
   Compiling myproject1 v0.1.0 (/tmp/myproject1)
    Finished dev [unoptimized + debuginfo] target(s) in 1.25s
     Running `target/debug/myproject1`
Hello, world!

If you just call cargo init, then it creates a new project in the current directory. Similar to git init.

Metadata

Metadata

Assignees

No one assigned

    Labels

    specificationIssue regarding fpm manifest and model

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions