1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
use clap::Subcommand;
#[derive(Debug, Subcommand)]
pub enum Status {
/// Get a single statuslog entry for an omg.lol address
Get {
/// ID of the statuslog entry to get
id: String,
},
/// Get entire statuslog for an omg.lol address
GetAll,
/// Create a new statuslog entry for an omg.lol address
Create {
/// Emoji to use for the statuslog entry
emoji: String,
/// Content for the statuslog entry
content: String,
/// External URL to link to from the statuslog entry
external_url: String, // TODO: should this be optional?
},
/// Create a new statuslog entry for an omg.lol address from a single string
EasyCreate {
/// Status to share
status: String,
},
/// Update the content of an existing statuslog entry for an omg.lol address
Update {
/// ID of the statuslog entry to update
id: String,
/// New emoji to use for the statuslog entry
emoji: String,
/// New content for the statuslog entry
content: String,
// TODO: should there be an external url here?
},
/// Get a statuslog bio
GetBio,
/// Update a statuslog bio
SetBio {
/// New content for statuslog bio
content: String,
},
/// Get all statuslog entries for all addresses
GetAllHistorical,
/// Get the most recent statuslog entries across omg.lol
Timeline,
}
impl Status {
pub fn process(&self, _address: &str) {
match self {
Status::Get { id: _ } => todo!(),
Status::GetAll => todo!(),
Status::Create { emoji: _, content: _, external_url: _ } => todo!(),
Status::EasyCreate { status: _ } => todo!(),
Status::Update { id: _, emoji: _, content: _ } => todo!(),
Status::GetBio => todo!(),
Status::SetBio { content: _ } => todo!(),
Status::GetAllHistorical => todo!(),
Status::Timeline => todo!(),
}
}
}