<commit_before>; example2.nsi
;
; This script is based on example1.nsi, but it remember the directory, 
; has uninstall support and (optionally) installs start menu shortcuts.
;
; It will install example2.nsi into a directory that the user selects,

;--------------------------------

; The name of the installer
Name "<%= appName %>"

; The file to write
OutFile "<%= appName %>.exe"

; The default installation directory
InstallDir $PROGRAMFILES\<%= appName %>

; Registry key to check for directory (so if you install again, it will 
; overwrite the old one automatically)
InstallDirRegKey HKLM "Software\NSIS_<%= appName %>" "Install_Dir"

; Request application privileges for Windows Vista
RequestExecutionLevel admin

;--------------------------------

; Pages

Page components
Page directory
Page instfiles

UninstPage uninstConfirm
UninstPage instfiles

;--------------------------------

; The stuff to install
Section "<%= appName %> (required)"

  SectionIn RO
  
  ; Set output path to the installation directory.
  SetOutPath $INSTDIR
  
  ; Put file there
  File "<%= appName %>.nsi"
  
  ; Write the installation path into the registry
  WriteRegStr HKLM SOFTWARE\NSIS_<%= appName %> "Install_Dir" "$INSTDIR"
  
  ; Write the uninstall keys for Windows
  WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\<%= appName %>" "DisplayName" "NSIS Example2"
  WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\<%= appName %>" "UninstallString" '"$INSTDIR\uninstall.exe"'
  WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\<%= appName %>" "NoModify" 1
  WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\<%= appName %>" "NoRepair" 1
  WriteUninstaller "uninstall.exe"
  
SectionEnd

; Optional section (can be disabled by the user)
Section "Start Menu Shortcuts"

  CreateDirectory "$SMPROGRAMS\<%= appName %>"
  CreateShortcut "$SMPROGRAMS\<%= appName %>\Uninstall.lnk" "$INSTDIR\uninstall.exe" "" "$INSTDIR\uninstall.exe" 0
  CreateShortcut "$SMPROGRAMS\<%= appName %>\<%= appName %> (MakeNSISW).lnk" "$INSTDIR\<%= appName %>.nsi" "" "$INSTDIR\<%= appName %>.nsi" 0
  
SectionEnd

;--------------------------------

; Uninstaller

Section "Uninstall"
  
  ; Remove registry keys
  DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\<%= appName %>"
  DeleteRegKey HKLM SOFTWARE\NSIS_<%= appName %>

  ; Remove files and uninstaller
  Delete $INSTDIR\<%= appName %>.nsi
  Delete $INSTDIR\uninstall.exe

  ; Remove shortcuts, if any
  Delete "$SMPROGRAMS\<%= appName %>\*.*"

  ; Remove directories used
  RMDir "$SMPROGRAMS\<%= appName %>"
  RMDir "$INSTDIR"

SectionEnd
<commit_msg>updated template<commit_after>; example2.nsi
;
; This script is based on example1.nsi, but it remember the directory, 
; has uninstall support and (optionally) installs start menu shortcuts.
;
; It will install example2.nsi into a directory that the user selects,

;--------------------------------

; The name of the installer
Name "<%= appName %>"

; The file to write
OutFile "<%= appName %>.exe"

; The default installation directory
InstallDir $PROGRAMFILES\<%= appName %>

; Registry key to check for directory (so if you install again, it will 
; overwrite the old one automatically)
InstallDirRegKey HKLM "Software\NSIS_<%= appName %>" "Install_Dir"

; Request application privileges for Windows Vista
RequestExecutionLevel admin

;--------------------------------

; Pages

Page components
Page directory
Page instfiles

UninstPage uninstConfirm
UninstPage instfiles

;--------------------------------

; The stuff to install
Section "<%= appName %> (required)"

  SectionIn RO
  
  ; Set output path to the installation directory.
  SetOutPath $INSTDIR
  
  ; Put file there
  <% _.each(files, function(file) { %>
  File "<%= srcDir %>/<%- file %>"
  <% }) %>
  
  ; Write the installation path into the registry
  WriteRegStr HKLM SOFTWARE\NSIS_<%= appName %> "Install_Dir" "$INSTDIR"
  
  ; Write the uninstall keys for Windows
  WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\<%= appName %>" "DisplayName" "NSIS Example2"
  WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\<%= appName %>" "UninstallString" '"$INSTDIR\uninstall.exe"'
  WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\<%= appName %>" "NoModify" 1
  WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\<%= appName %>" "NoRepair" 1
  WriteUninstaller "uninstall.exe"
  
SectionEnd

; Optional section (can be disabled by the user)
Section "Start Menu Shortcuts"

  CreateDirectory "$SMPROGRAMS\<%= appName %>"
  CreateShortcut "$SMPROGRAMS\<%= appName %>\Uninstall.lnk" "$INSTDIR\uninstall.exe" "" "$INSTDIR\uninstall.exe" 0
  CreateShortcut "$SMPROGRAMS\<%= appName %>\<%= appName %> (MakeNSISW).lnk" "$INSTDIR\<%= appName %>.nsi" "" "$INSTDIR\<%= appName %>.nsi" 0
  
SectionEnd

;--------------------------------

; Uninstaller

Section "Uninstall"
  
  ; Remove registry keys
  DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\<%= appName %>"
  DeleteRegKey HKLM SOFTWARE\NSIS_<%= appName %>

  ; Remove files and uninstaller
  Delete $INSTDIR\<%= appName %>.nsi
  Delete $INSTDIR\uninstall.exe

  ; Remove shortcuts, if any
  Delete "$SMPROGRAMS\<%= appName %>\*.*"

  ; Remove directories used
  RMDir "$SMPROGRAMS\<%= appName %>"
  RMDir "$INSTDIR"

SectionEnd

{'fraction_non_alphanumeric': 0.16311926605504587, 'fraction_numerical': 0.0029357798165137615, 'mean_word_length': 3.627334465195246, 'pattern_counts': {'":': 0, '<': 50, '<?xml version=': 0, '>': 50, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1036126', 'n_tokens_mistral': 1820, 'n_tokens_neox': 1624, 'n_words': 487}