Function at 0x180055520
Capabilities:
Query environment variable
Set console window title

Disassembly:
mov rax, rsp
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0xa0
mov rbx, rcx
mov qword [rax - 0x68], rcx
mov qword [rax - 0x48], rcx
xor esi, esi
mov dword [rsp + 0x30], esi
mov r14d, 2
mov edx, r14d
call qword [sym.imp.MSVCP140.dll__Mtx_init_in_situ]
nop
mov qword [rbx + 0x50], rsi
mov qword [rbx + 0x58], rsi
mov qword [rbx + 0x60], rsi
lea rdi, [rbx + 0x68]
mov qword [rsp + 0x78], rdi
xorps xmm0, xmm0
movups xmmword [rdi], xmm0
lea rax, [rdi + 0x18]
mov qword [rsp + 0x38], rax
mov qword [rdi + 0x10], rsi
mov qword [rax], 7
mov word [rdi], si
lea r15, [rbx + 0x88]
mov qword [rsp + 0x88], r15
mov rcx, r15
call fcn.180055be0
nop
lea r13, [rbx + 0x190]
mov qword [rsp + 0x70], r13
mov rcx, r13
call fcn.180055be0
nop
lea r12, [rbx + 0x298]
mov qword [rsp + 0x68], r12
mov qword [rsp + 0x98], r12
lea rax, [0x18015ae60]
mov qword [r12], rax
lea rcx, [r12 + 0xb0]
call qword [sym.imp.MSVCP140.dll_protected:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::constructor_void____ptr64]
nop
mov dword [rsp + 0x30], 1
lea rbx, [r12 + 0x10]
mov qword [rsp + 0x90], rbx
xor r9d, r9d
xor r8d, r8d
mov rdx, rbx
mov rcx, r12
call qword [sym.imp.MSVCP140.dll_public:_void___cdecl_std::basic_istream_char__struct_std::char_traits_char__::constructor_class_std::basic_streambuf_char__struct_std::char_traits_char______ptr64__bool____ptr64]
nop
mov rax, qword [r12]
movsxd rcx, dword [rax + 4]
lea rax, vtable.std::basic_ifstream_char__struct_std::char_traits_char__.0
mov qword [rcx + r12], rax
mov rax, qword [r12]
movsxd rcx, dword [rax + 4]
lea edx, [rcx - 0xb0]
mov dword [rcx + r12 - 4], edx
mov qword [rsp + 0x20], rbx
mov rcx, rbx
call qword [sym.imp.MSVCP140.dll_protected:_void___cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::constructor_void____ptr64]
lea rax, vtable.std::basic_filebuf_char__struct_std::char_traits_char__.0
mov qword [rbx], rax
mov byte [rbx + 0x7c], sil
mov byte [rbx + 0x71], sil
mov rcx, rbx
call qword [sym.imp.MSVCP140.dll_protected:_void___cdecl_std::basic_streambuf_char__struct_std::char_traits_char__::_Init_void____ptr64]
mov qword [rbx + 0x80], rsi
mov rax, qword [0x180259170]
mov qword [rbx + 0x74], rax
mov qword [rbx + 0x68], rsi
lea rcx, [0x18015afe0]
call qword [sym.imp.api_ms_win_crt_environment_l1_1_0.dll_getenv]
mov rsi, rax
mov rbx, 0xffffffffffffffff
nop dword [rax]
inc rbx
cmp byte [rax + rbx], 0
jne 0x180055690
call fcn.1800f18d0
mov qword [rsp + 0x20], rsi
mov qword [rsp + 0x28], rbx
lea r8, [rsp + 0x20]
mov edx, eax
lea rcx, [rsp + 0x40]
call fcn.180056460
nop
lea rdx, [rsp + 0x40]
mov rcx, rdi
call fcn.180056a80
nop
lea rcx, [rsp + 0x40]
call fcn.180057d00
call fcn.1800f18d0
lea rcx, [0x18015e930]
mov qword [rsp + 0x20], rcx
mov qword [rsp + 0x28], 6
lea r8, [rsp + 0x20]
mov edx, eax
lea rcx, [rsp + 0x40]
call fcn.180056460
nop
lea rdx, [rsp + 0x40]
mov rcx, rdi
call fcn.180056a80
nop
lea rcx, [rsp + 0x40]
call fcn.180057d00
mov rcx, rdi
call fcn.180057be0
mov rbx, qword [rsp + 0x38]
test al, al
jne 0x180055747
mov rcx, rdi
cmp qword [rbx], 8
jb 0x180055733
mov rcx, qword [rdi]
call fcn.1800f1b30
mov rdx, rax
shr rax, 0x20
test eax, eax
jne 0x1800558f6
call fcn.1800f18d0
lea rcx, str.Unison.log
mov qword [rsp + 0x20], rcx
mov qword [rsp + 0x28], 0xa
lea r8, [rsp + 0x20]
mov edx, eax
lea rcx, [rsp + 0x40]
call fcn.180056460
nop
lea rdx, [rsp + 0x40]
mov rcx, rdi
call fcn.180056a80
nop
lea rcx, [rsp + 0x40]
call fcn.180057d00
nop
mov rsi, qword [rsp + 0x60]
jmp 0x1800557bd
call qword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
mov ecx, eax
call qword [sym.imp.KERNEL32.dll_AttachConsole]
test eax, eax
jne 0x1800557d5
call qword [sym.imp.KERNEL32.dll_AllocConsole]
lea rcx, str.Unison
call qword [sym.imp.KERNEL32.dll_SetConsoleTitleW]
mov ecx, 0xfffffff5
call qword [sym.imp.KERNEL32.dll_GetStdHandle]
mov rcx, rax
movzx edx, r14w
call qword [sym.imp.KERNEL32.dll_SetConsoleTextAttribute]
mov ecx, 0xfde9
call qword [sym.imp.KERNEL32.dll_SetConsoleCP]
mov ecx, 0xfde9
call qword [sym.imp.KERNEL32.dll_SetConsoleOutputCP]
lea rcx, [r13 + 8]
mov r8d, r14d
lea rdx, str.CONOUT_
call fcn.18000f510
mov rcx, rax
mov rax, qword [r13]
movsxd rdx, dword [rax + 4]
xor r8d, r8d
test rcx, rcx
lea rcx, [rdx + r13]
je 0x180055844
xor edx, edx
call qword [sym.imp.MSVCP140.dll_public:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::clear_int__bool____ptr64]
jmp 0x18005584d
mov edx, r14d
call qword [sym.imp.MSVCP140.dll_public:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool____ptr64]
mov r8d, 1
lea rdx, str.CONIN_
mov rcx, qword [rsp + 0x90]
call fcn.18000f510
mov rcx, rax
mov rax, qword [r12]
movsxd rdx, dword [rax + 4]
xor r8d, r8d
test rcx, rcx
lea rcx, [r12 + rdx]
je 0x180055888
xor edx, edx
call qword [sym.imp.MSVCP140.dll_public:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::clear_int__bool____ptr64]
jmp 0x180055891
mov edx, r14d
call qword [sym.imp.MSVCP140.dll_public:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool____ptr64]
cmp qword [rbx], 8
jb 0x18005589a
mov rdi, qword [rdi]
lea rcx, [r15 + 8]
mov r8d, 0xa
mov rdx, rdi
call fcn.180055f60
mov rcx, rax
mov rax, qword [r15]
movsxd rdx, dword [rax + 4]
xor r8d, r8d
test rcx, rcx
lea rcx, [r15 + rdx]
je 0x1800558cc
xor edx, edx
call qword [sym.imp.MSVCP140.dll_public:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::clear_int__bool____ptr64]
jmp 0x1800558d6
mov edx, r14d
call qword [sym.imp.MSVCP140.dll_public:_void___cdecl_std::basic_ios_char__struct_std::char_traits_char__::setstate_int__bool____ptr64]
nop
mov rax, rsi
lea r11, [rsp + 0xa0]
mov rbx, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rdi
ret
shr rdx, 0x20
mov r8, rdi
lea rcx, str.create_directory
call fcn.180056cd0
int3