idk what i added
This commit is contained in:
28
source/kernel/features/utils.asm
Normal file
28
source/kernel/features/utils.asm
Normal file
@@ -0,0 +1,28 @@
|
||||
util_cat:
|
||||
pusha
|
||||
|
||||
call disk_clear_file_buffer
|
||||
mov si, user_input
|
||||
; TODO make this more consistent to account for double spaces
|
||||
add si, 4 ; Move si to after 'CAT'
|
||||
|
||||
call disk_load_file
|
||||
mov si, file_buffer
|
||||
mov cx, [file_length]
|
||||
call text_print_raw
|
||||
|
||||
popa
|
||||
ret
|
||||
|
||||
util_ls:
|
||||
pusha
|
||||
|
||||
call disk_clear_output_buffer
|
||||
call disk_list_contents
|
||||
|
||||
mov si, output_buffer
|
||||
call os_print_string
|
||||
|
||||
popa
|
||||
ret
|
||||
|
||||
Reference in New Issue
Block a user