pub fn export_variable<K, V>(key: K, value: V) -> Result<(), FileCommandError>
Examples found in repository?
examples/main.rs (line 33)
3fn main() {
4 info!("debug={}", is_debug());
5 info!(get_input("name").unwrap_or("default".to_string()));
6 info!(get_bool_input("bool").unwrap_or_default());
7 info!(get_multiline_input("multiline")
8 .unwrap_or_default()
9 .join("\\n"));
10 info!("state={}", get_state("name").unwrap_or_default());
11
12 {
13 stop_commands!("token");
14 info!("Message")
15 }
16
17 {
18 stop_commands!();
19 info!("Message")
20 }
21
22 group!("Main logs");
23
24 info!("Info");
25 debug!("Debug");
26 error!(format!("Error {}", 1), title: "Title");
27 error!("message", title: "title", file: "file", col: 1, end_column: 1, line: 1, end_line: 1);
28 warn!("Warning");
29 notice!("Notice");
30
31 set_secret("secret");
32
33 export_variable("key", format!("value {}", "env")).unwrap();
34 set_output("key", "value").unwrap();
35 save_state("key", "value").unwrap();
36
37 add_path("path").unwrap();
38}