<commit_before>
"""
Usage::

    import install_visual_studio_wrapper
    install_visual_studio_wrapper.install()

"""

import shutil
import sys

try:
    from urllib.request import urlopen
except ImportError:
    from urllib2 import urlopen

SCRIPT_URL = \
    "https://raw.githubusercontent.com/ogrisel/python-appveyor-demo/" \
    "f54ec3593bcea682098a59b560c1850c19746e10/appveyor/run_with_env.cmd"


def install(local_path):
    """Download ``run_with_env.cmd`` and copy it to ``local_path``"""

    remote_script = urlopen(SCRIPT_URL)
    with open(local_path, "wb") as local_script:
        shutil.copyfileobj(remote_script, local_script)

if __name__ == '__main__':
    install(sys.argv[0])
<commit_msg>ci/appveyor/install_visual_studio_wrapper: Fix dowload destination path<commit_after>
"""
Usage::

    import install_visual_studio_wrapper
    install_visual_studio_wrapper.install()

"""

import os
import shutil
import sys

try:
    from urllib.request import urlopen
except ImportError:
    from urllib2 import urlopen

SCRIPT_URL = \
    "https://raw.githubusercontent.com/ogrisel/python-appveyor-demo/" \
    "f54ec3593bcea682098a59b560c1850c19746e10/appveyor/run_with_env.cmd"

LOCAL_PATH_DEFAULT = \
    os.path.join(os.path.dirname(__file__), "run-with-visual-studio.cmd")


def install(local_path=LOCAL_PATH_DEFAULT):
    """Download ``run_with_env.cmd`` and copy it to ``local_path``"""

    remote_script = urlopen(SCRIPT_URL)
    with open(local_path, "wb") as local_script:
        shutil.copyfileobj(remote_script, local_script)

if __name__ == '__main__':
    install(sys.argv[1])

{'fraction_non_alphanumeric': 0.11014312383322962, 'fraction_numerical': 0.037336652146857496, 'mean_word_length': 4.661971830985915, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3387568', 'n_tokens_mistral': 621, 'n_tokens_neox': 574, 'n_words': 99}