To prevent performance degradation, we will cache the result of GetConsoleOutputCP() after executing every external command.
-- v3: cmd: Use the console output code page to read batch files. programs/cmd: Factor out code_page when searching for a label. cmd/tests: Add updated code page test in batch file.