<commit_before>#define AppName "Cloudify CLI"
#define AppVersion GetEnv('VERSION')
#define AppMilestone GetEnv('PRERELEASE')
#define AppBuild GetEnv('BUILD')
#define AppPublisher "GigaSpaces Technologies"
#define AppURL "http://getcloudify.org/"
#define PluginsTagName GetEnv('PLUGINS_TAG_NAME')
#define CoreTagName GetEnv('CORE_TAG_NAME')

[Setup]
; NOTE: The value of AppId uniquely identifies this application.
; Do not use the same AppId value in installers for other applications.
; (To generate a new GUID, click Tools | Generate GUID inside the IDE.)
AppId={{94B9D938-5123-4AC5-AA99-68F07F773DE2}
AppName={#AppName}
AppVersion={#AppVersion}
AppPublisher={#AppPublisher}
AppPublisherURL={#AppURL}
AppSupportURL={#AppURL}
AppUpdatesURL={#AppURL}
DefaultDirName={sd}\Cloudify
OutputBaseFilename=cloudify-windows-cli_{#AppVersion}-{#AppMilestone}
Compression=lzma
SolidCompression=yes
ArchitecturesInstallIn64BitMode=
LicenseFile=source\license.txt
MinVersion=6.0
SetupIconFile=source\icons\Cloudify.ico
UninstallDisplayIcon={app}\Cloudify.ico
OutputDir=output\
DisableDirPage=auto
DisableProgramGroupPage=yes

[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"

[Files]
Source: "source\python\*"; DestDir: "{app}\embedded" ;Flags: recursesubdirs
Source: "source\wheels\*.whl"; Flags: dontcopy
Source: "source\icons\Cloudify.ico"; DestDir: "{app}"
Source: "source\blueprints\*"; DestDir: "{app}\cloudify-manager-blueprints"; Flags: recursesubdirs

Source: "source\types\*"; DestDir: "{app}\cloudify\types"; Flags: recursesubdirs
Source: "source\scripts\*"; DestDir: "{app}\cloudify\scripts"; Flags: recursesubdirs
Source: "source\plugins\*"; DestDir: "{app}\cloudify\plugins"; Flags: recursesubdirs
Source: "source\import_resolver.yaml"; Flags: dontcopy


[Tasks]
Name: "desktopicon"; Description: "Create a desktop icon";

[Icons]
Name: "{userdesktop}\Cloudify CLI"; Filename: "{cmd}"; Parameters: "/k SET PATH=%PATH%;{app}\embedded\Scripts\"; WorkingDir: "{app}"; IconFilename: "{app}\Cloudify.ico"; Tasks: "desktopicon";

[UninstallDelete]
;this is NOT recommended but in our case, no user data here
Type: "filesandordirs"; Name: "{app}"

[Code]
const
  mainPackagesName = 'cloudify cloudify-fabric-plugin cloudify-openstack-plugin cloudify-aws-plugin cloudify-softlayer-plugin cloudify-vsphere-plugin';
  //Error messages
  errUnexpected = 'Unexpected error. Run setup with /LOG flag and check the logs for additional details.';
  LF = #10;
  CR = #13;
  CRLF = CR + LF;

function runPipSetup(): Boolean;
var
  GetPipArgs: String;
  ErrorCode: Integer;
begin
  GetPipArgs := '-m ensurepip';
  Exec(Expandconstant('{app}\embedded\python.exe'), GetPipArgs, Expandconstant('{tmp}'), SW_SHOW, ewWaituntilterminated, ErrorCode);
  Log('Installting pip return code: ' + IntToStr(ErrorCode));
  if Errorcode <> 0 then
    Result := False
  else
    Result := True;
end;


function runWheelsInstall(): Boolean;
var
  PipArgs: String;
  ErrorCode: Integer;
  PackagesToInstall: String;
begin
  ExtractTemporaryFiles('*.whl');
<commit_msg>CFY-7109 remove plugins from cli package installation<commit_after>#define AppName "Cloudify CLI"
#define AppVersion GetEnv('VERSION')
#define AppMilestone GetEnv('PRERELEASE')
#define AppBuild GetEnv('BUILD')
#define AppPublisher "GigaSpaces Technologies"
#define AppURL "http://getcloudify.org/"
#define PluginsTagName GetEnv('PLUGINS_TAG_NAME')
#define CoreTagName GetEnv('CORE_TAG_NAME')

[Setup]
; NOTE: The value of AppId uniquely identifies this application.
; Do not use the same AppId value in installers for other applications.
; (To generate a new GUID, click Tools | Generate GUID inside the IDE.)
AppId={{94B9D938-5123-4AC5-AA99-68F07F773DE2}
AppName={#AppName}
AppVersion={#AppVersion}
AppPublisher={#AppPublisher}
AppPublisherURL={#AppURL}
AppSupportURL={#AppURL}
AppUpdatesURL={#AppURL}
DefaultDirName={sd}\Cloudify
OutputBaseFilename=cloudify-windows-cli_{#AppVersion}-{#AppMilestone}
Compression=lzma
SolidCompression=yes
ArchitecturesInstallIn64BitMode=
LicenseFile=source\license.txt
MinVersion=6.0
SetupIconFile=source\icons\Cloudify.ico
UninstallDisplayIcon={app}\Cloudify.ico
OutputDir=output\
DisableDirPage=auto
DisableProgramGroupPage=yes

[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"

[Files]
Source: "source\python\*"; DestDir: "{app}\embedded" ;Flags: recursesubdirs
Source: "source\wheels\*.whl"; Flags: dontcopy
Source: "source\icons\Cloudify.ico"; DestDir: "{app}"
Source: "source\blueprints\*"; DestDir: "{app}\cloudify-manager-blueprints"; Flags: recursesubdirs

Source: "source\types\*"; DestDir: "{app}\cloudify\types"; Flags: recursesubdirs
Source: "source\scripts\*"; DestDir: "{app}\cloudify\scripts"; Flags: recursesubdirs
Source: "source\plugins\*"; DestDir: "{app}\cloudify\plugins"; Flags: recursesubdirs
Source: "source\import_resolver.yaml"; Flags: dontcopy


[Tasks]
Name: "desktopicon"; Description: "Create a desktop icon";

[Icons]
Name: "{userdesktop}\Cloudify CLI"; Filename: "{cmd}"; Parameters: "/k SET PATH=%PATH%;{app}\embedded\Scripts\"; WorkingDir: "{app}"; IconFilename: "{app}\Cloudify.ico"; Tasks: "desktopicon";

[UninstallDelete]
;this is NOT recommended but in our case, no user data here
Type: "filesandordirs"; Name: "{app}"

[Code]
const
  mainPackagesName = 'cloudify cloudify-fabric-plugin';
  //Error messages
  errUnexpected = 'Unexpected error. Run setup with /LOG flag and check the logs for additional details.';
  LF = #10;
  CR = #13;
  CRLF = CR + LF;

function runPipSetup(): Boolean;
var
  GetPipArgs: String;
  ErrorCode: Integer;
begin
  GetPipArgs := '-m ensurepip';
  Exec(Expandconstant('{app}\embedded\python.exe'), GetPipArgs, Expandconstant('{tmp}'), SW_SHOW, ewWaituntilterminated, ErrorCode);
  Log('Installting pip return code: ' + IntToStr(ErrorCode));
  if Errorcode <> 0 then
    Result := False
  else
    Result := True;
end;


function runWheelsInstall(): Boolean;
var
  PipArgs: String;
  ErrorCode: Integer;
  PackagesToInstall: String;
begin
  ExtractTemporaryFiles('*.whl');

{'fraction_non_alphanumeric': 0.13711544823023486, 'fraction_numerical': 0.010916308303010255, 'mean_word_length': 6.6738578680203045, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, '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': '4887807', 'n_tokens_mistral': 2073, 'n_tokens_neox': 1972, 'n_words': 494}