mirror of
https://github.com/asciinema/asciinema.git
synced 2025-12-16 11:48:13 +01:00
Code tweaks
This commit is contained in:
@@ -267,6 +267,7 @@ pub enum Format {
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone)]
|
||||
#[allow(dead_code)]
|
||||
pub enum RelayTarget {
|
||||
StreamId(String),
|
||||
WsProducerUrl(url::Url),
|
||||
|
||||
@@ -39,21 +39,21 @@ impl cli::Session {
|
||||
locale::check_utf8_locale()?;
|
||||
|
||||
let runtime = Runtime::new()?;
|
||||
let command = self.get_command(&cmd_config);
|
||||
let keys = get_key_bindings(&cmd_config)?;
|
||||
let command = self.get_command(cmd_config);
|
||||
let keys = get_key_bindings(cmd_config)?;
|
||||
let notifier = notifier::threaded(get_notifier(config));
|
||||
let record_input = self.input || cmd_config.input;
|
||||
let env = capture_env(self.env.clone(), &cmd_config);
|
||||
let env = capture_env(self.env.clone(), cmd_config);
|
||||
|
||||
let path = self
|
||||
.output
|
||||
.take()
|
||||
.map(|path| self.ensure_filename(path, &cmd_config))
|
||||
.map(|path| self.ensure_filename(path, cmd_config))
|
||||
.transpose()?;
|
||||
|
||||
let file_writer = path
|
||||
.as_ref()
|
||||
.map(|path| self.get_file_writer(path, &cmd_config, &env, notifier.clone()))
|
||||
.map(|path| self.get_file_writer(path, cmd_config, &env, notifier.clone()))
|
||||
.transpose()?;
|
||||
|
||||
let mut listener = self
|
||||
|
||||
@@ -132,13 +132,13 @@ impl Tty for DevTty {
|
||||
let mut got_da_response = false;
|
||||
|
||||
if let Some(b'c') = reversed.next() {
|
||||
while let Some(b) = reversed.next() {
|
||||
for b in reversed {
|
||||
if *b == b'[' {
|
||||
got_da_response = true;
|
||||
break;
|
||||
}
|
||||
|
||||
if *b != b';' && *b != b'?' && !(b'0'..=b'9').contains(b) {
|
||||
if *b != b';' && *b != b'?' && !b.is_ascii_digit() {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user