crud/
lib.rs

1//! # CRUD
2//!
3//! This crate provides a framework to generate an executable to manipulate your REST HTTP API from CLI.
4//!
5//! Have a look to the examples directory.
6//!
7//! ### Options
8//!
9//! #### Crud Options
10//!
11//! Per endpoint options.
12//!
13//! * **route** : route prefix. `route="/myroute"`
14//! * **nested**: Nested link to this endpoind. example: `nested(route = "/another_endpoint/{id}/here"))`
15//! * **parameters**: Parameter struct that is passed in the query string
16//! * **help**: Help string
17//!
18//! #### Field Options
19//!
20//! * **id**: Mark this field as `id`
21//! * **long**: Long name of the option
22//! * **short**: Short name of the option
23//! * **no_short**: Don't generate a short option
24//! * **heading**: Category of the option
25//! * **help**: Short help string
26//! * **long_help**: Long help text
27//! * **table_skip**: THE field won't appears when display as the table
28//!
29//!
30//! ### Runtime Settings
31//!
32//! File `settings.toml`
33//!
34//! | option     | description          |                            |
35//! |------------|----------------------|----------------------------|
36//! | base_url   | Base url of the api  |                            |
37//! | auth_token | token send as bearer | read by `crud-auth-bearer` |
38//!
39//! #### Profiles
40//!
41//! In `settings.toml`, you can define multiple profiles:
42//! ```ignore
43//! [profile.p1]
44//! base_url="..."
45//! uth_token="..."
46//! [profile.p2]
47//! base_url="..."
48//! uth_token="..."
49//! ```
50//!
51//! You call the profiles with the `--profile` argument.
52
53extern crate crud_derive;
54#[doc(hidden)]
55pub use crud_derive::*;