<commit_before>###########################################################################
#  Delta CLI Windows Installation
###########################################################################
#
#  This script will install the dependencies for Delta CLI on Windows 10
#
#  You must ensure Get-ExecutionPolicy is not Restricted. Run the
#  following command from PowerShell prior to running this
#  script.
# 
#      Set-ExecutionPolicy Bypass
#
#  You can then install Delta CLI and dependencies by executing this:
#
#      iex((New-Object System.Net.WebClient).DownloadString('https://raw.githubusercontent.com/bdelamatre/delta-cli-tools/master/bin/delta-install-windows.ps1'))
#
   
# Ask for elevated privelege if needed
Write-Host "Checking for elevated priveleges...[" -nonewline

If (!([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole]"Administrator")) {
    Start-Process powershell.exe "-NoProfile -NoExit -ExecutionPolicy Bypass -File `"$PSCommandPath`"" -Verb RunAs
    Exit
}

Write-Host "OK" -foreground "green" -NoNewLine
Write-Host "]"

#make sure windows 10
Write-Host "Checking if Windows 10...[" -NoNewline

if([System.Environment]::OSVersion.Version.Major -eq 10){
    Write-Host "OK" -foreground "green" -NoNewline
    Write-Host "]"
}else{
    Write-Host "FAIL" -foreground "red" -NoNewline
    Write-Host "]"
    Write-Host "This script was created for windows 10 only" -foreground "red"
    Read-Host -Prompt "Press Enter to exit"
    Exit
}

#make sure creators update is installed
Write-Host "Checking if the Windows 10 creator's update (version 1703) is installed...[" -NoNewline

$currentVersion = (Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion" -Name ReleaseId).ReleaseId
if($currentVersion -ge 1703){
    Write-Host "OK" -foreground "green" -NoNewline
    Write-Host "]"
}else{
    Write-Host "FAIL" -foreground "red" -NoNewline
    Write-Host "]"
    Write-Host "You need to install the Windows 10 Creators update (version 1703). https://www.microsoft.com/en-us/software-download/windows10" -foreground "red"
    Read-Host -Prompt "Press Enter to exit"
    Exit}

Write-Host "This script will install Chocolatey and other software on your computer. Continue? [Y/n]" -NoNewline
$proceed = Read-Host<commit_msg>trying to prevent exit<commit_after>###########################################################################
#  Delta CLI Windows Installation
###########################################################################
#
#  This script will install the dependencies for Delta CLI on Windows 10
#
#  You must ensure Get-ExecutionPolicy is not Restricted. Run the
#  following command from PowerShell prior to running this
#  script.
# 
#      Set-ExecutionPolicy Bypass
#
#  You can then install Delta CLI and dependencies by executing this:
#
#      iex((New-Object System.Net.WebClient).DownloadString('https://raw.githubusercontent.com/bdelamatre/delta-cli-tools/master/bin/delta-install-windows.ps1'))
#
   
# Ask for elevated privelege if needed
Write-Host "Checking for elevated priveleges...[" -nonewline

If (!([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole]"Administrator")) {
    Start-Process powershell.exe "-NoProfile -NoExit -ExecutionPolicy Bypass -File `"$PSCommandPath`"" -Verb RunAs
    Exit
}

Write-Host "OK" -foreground "green" -NoNewLine
Write-Host "]"

powershell -NoExit

#make sure windows 10
Write-Host "Checking if Windows 10...[" -NoNewline

if([System.Environment]::OSVersion.Version.Major -eq 10){
    Write-Host "OK" -foreground "green" -NoNewline
    Write-Host "]"
}else{
    Write-Host "FAIL" -foreground "red" -NoNewline
    Write-Host "]"
    Write-Host "This script was created for windows 10 only" -foreground "red"
    Read-Host -Prompt "Press Enter to exit"
    Exit
}

#make sure creators update is installed
Write-Host "Checking if the Windows 10 creator's update (version 1703) is installed...[" -NoNewline

$currentVersion = (Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion" -Name ReleaseId).ReleaseId
if($currentVersion -ge 1703){
    Write-Host "OK" -foreground "green" -NoNewline
    Write-Host "]"
}else{
    Write-Host "FAIL" -foreground "red" -NoNewline
    Write-Host "]"
    Write-Host "You need to install the Windows 10 Creators update (version 1703)." -foreground "red"
    Write-Host "https://www.microsoft.com/en-us/software-download/windows10" -foreground "red"
    Read-Host -Prompt "Press Enter to exit"
    Exit}

Write-Host "This script will install Chocolatey and other software on your computer. Continue? [Y/n]" -NoNewline
$proceed = Read-Host
{'fraction_non_alphanumeric': 0.1718162839248434, 'fraction_numerical': 0.012108559498956159, 'mean_word_length': 4.462941847206386, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 4, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4095452', 'n_tokens_mistral': 1492, 'n_tokens_neox': 1367, 'n_words': 419}