Your comments

Hi Mark

My solution to this problem was to stop using command line arguments. However, I do know of a good work-around which you could use if you are in a situation where you need to use them.

In the most recent version of SublimeREPL for ST3, there is a shell environment which will allow you to run the script easily in the current directory without opening a different window. Copy the below code into your user keyboard shortcuts file and replace "f10" with whichever key you like.

In linux the shell has memory so you can use the up arrow to retrieve the history, I don't think this works in windows, never tried it on mac. 


        { "keys": ["f10"], 

                    "command": "repl_open", 

                     "caption": "Shell",

                     "id": "repl_shell",

                     "mnemonic": "s",

                     "args": {

                        "type": "subprocess",

                        "encoding": {"windows": "$win_cmd_encoding",

                                     "linux": "utf-8",

                                     "osx": "utf-8"},

                        "cmd": {"windows": ["cmd.exe"],

                                "linux": ["bash", "-i"],

                                "osx": ["bash", "-i"]},

                        "cwd": "$file_path",

                        "cmd_postfix": "\n", 

                        "env": {},

                        "suppress_echo": true, 

                        "syntax": "Packages/Text/Plain text.tmLanguage"



I hope this helps.