Start of binary search for ls command
This commit is contained in:
@@ -227,9 +227,24 @@ function result_ls(this: Bash, data: any, args: CommandArgs): HTMLElement {
|
||||
return w;
|
||||
}
|
||||
|
||||
|
||||
|
||||
return dummysonoerror; //TEMP SO NO ERROR CUZ RETURNS HTMLElement EVERY TIME, DELETE LATER
|
||||
}
|
||||
|
||||
function checkMaxColumns(this: Bash, files: TreeNode[]) {
|
||||
const paddingWidth: number = 2;
|
||||
const maxWidth: number = (this.getTerminalWidth() / this.getTerminalFontSize()) * 0.8;
|
||||
|
||||
|
||||
//Upper bound set to max width / min column width - 1 character + padding
|
||||
let lowBound: number = 1;
|
||||
let highBound: number = Math.floor(maxWidth / (1 + paddingWidth));
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
function isValidNodeSortMethod(value: string): value is SortNodeBy {
|
||||
return Object.values(SortNodeBy).includes(value as SortNodeBy);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user