improve completion generation/binary usage

This commit is contained in:
askiiart 2025-01-30 12:07:21 -06:00
parent a4bcaf6103
commit b440555138
Signed by untrusted user who does not match committer: askiiart
GPG key ID: 6A32977DAF31746A
4 changed files with 58 additions and 48 deletions

View file

@ -70,7 +70,11 @@ pub fn cat_to_num(text: Vec<String>, alphabet: Vec<String>, char_length: u32) ->
pub(crate) fn split_every_x(text: impl AsRef<str>, x: u32) -> Vec<String> {
let x = x as usize;
let delim = " ";
let tmp: Vec<String> = text.as_ref().split(delim).map(|item| item.to_string()).collect();
let tmp: Vec<String> = text
.as_ref()
.split(delim)
.map(|item| item.to_string())
.collect();
let mut output: Vec<String> = Vec::new();
for i in 0..tmp.len() {
if i % x == 0 {