Skip to content

Commit

Permalink
Added support for Visual Studio 2022,
Browse files Browse the repository at this point in the history
Updated Nuget Package "Newtonsoft.Json" to latest Version "13.0.1"
  • Loading branch information
deepak-rathi committed Nov 9, 2021
1 parent 2ff3095 commit e3a3058
Show file tree
Hide file tree
Showing 11 changed files with 59 additions and 35 deletions.
6 changes: 3 additions & 3 deletions Setup/Product.Core.wxs
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@
along with this program. If not, see<http://www.gnu.org/licenses/> .
-->
<!-- The name of the product -->
<?define Name = "VS2017 2019 Offline Setup Utility" ?>
<?define Name = "VS2017 2019 2022 Offline Setup Utility" ?>
<!-- The Description of the product -->
<?define Description = "This utility allow downloading offline setup or deletion of old version Visual Studio 2017 2019 Offline Setup files and folder" ?>
<?define Description = "This utility allow downloading offline setup or deletion of old version Visual Studio 2017 2019 2022 Offline Setup files and folder" ?>
<!-- The manufacturer, for setup package publisher and folder info -->
<?define Manufacturer = "Deepak Rathi" ?>
<!-- The version number of this setup package-->
<?define Version = "1.3.3" ?>
<?define Version = "1.4.1" ?>
<!-- UpgradeCode must be unique and not changed once the first version of the program is installed. -->
<?define UpgradeCode = "a49a94d4-f09a-4e3b-9b7e-b058cddd504e" ?>
<!-- The name of the Cabinet -->
Expand Down
2 changes: 1 addition & 1 deletion VS2017OfflineSetupUtility/Models/VsEdition.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
Copyright © 2017-2019 Deepak Rathi
Copyright © 2017-2021 Deepak Rathi
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
Expand Down
4 changes: 2 additions & 2 deletions VS2017OfflineSetupUtility/Utils/FeatureUtil.cs
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,15 @@ internal static List<Feature> GetFeatures()
var cleanUtilIcon = new CleanUtilIcon() { IsCheckedColor = (SolidColorBrush)App.Current.Resources["BlueSolidColorBrush"]};
cleanUtilIcon.SetBinding(CleanUtilIcon.IsCheckedProperty, new System.Windows.Data.Binding("IsSelected") { UpdateSourceTrigger = System.Windows.Data.UpdateSourceTrigger.PropertyChanged});

var cleanUtilFeature = new Feature() { Icon = cleanUtilIcon, Name = "VS2017/2019 Offline Clean Util", About= "Allow deletion of old version Visual Studio 2017/2019 Offline Setup files and folder, which saves your hard disk space.", Version="1.4.0.0", NavigateToView = new Views.CleanUtilPage() , IsSelected = true};
var cleanUtilFeature = new Feature() { Icon = cleanUtilIcon, Name = "VS2017/2019/2022 Offline Clean Util", About= "Allow deletion of old version Visual Studio 2017/2019/2022 Offline Setup files and folder, which saves your hard disk space.", Version="1.4.1.0", NavigateToView = new Views.CleanUtilPage() , IsSelected = true};

#endregion

#region Download Util Feature
var downloadUtilIcon = new DownloadUtilIcon() { IsCheckedColor = (SolidColorBrush)App.Current.Resources["BlueSolidColorBrush"]};
downloadUtilIcon.SetBinding(DownloadUtilIcon.IsCheckedProperty, new System.Windows.Data.Binding("IsSelected") { UpdateSourceTrigger = System.Windows.Data.UpdateSourceTrigger.PropertyChanged });

var downloadUtilFeature = new Feature() { Icon = downloadUtilIcon, Name = "VS2017/2019 Offline Download", About = "Download Visual Studio 2017/2019 Offline Setup files and folder, using command line interface. (Need internet connection)", Version = "1.4.0.0" , NavigateToView = new Views.DownloadUtilPage()};
var downloadUtilFeature = new Feature() { Icon = downloadUtilIcon, Name = "VS2017/2019/2022 Offline Download", About = "Download Visual Studio 2017/2019/2022 Offline Setup files and folder, using command line interface. (Need internet connection)", Version = "1.4.1.0" , NavigateToView = new Views.DownloadUtilPage()};

#endregion

Expand Down
24 changes: 24 additions & 0 deletions VS2017OfflineSetupUtility/Utils/VsEditionUtil.cs
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,30 @@ internal static List<VsEdition> GetAllVisualStudioEditions()
SetupUri = "https://aka.ms/vs/16/release/vs_enterprise.exe",
WorkloadDocUri = "https://docs.microsoft.com/en-us/visualstudio/install/workload-component-id-vs-enterprise?view=vs-2019",
WorkloadGitHubUri = "https://raw.githubusercontent.com/MicrosoftDocs/visualstudio-docs/master/docs/install/includes/vs-2019/workload-component-id-vs-enterprise.md",
},

new VsEdition() {
Version ="17C",
Name = "Visual Studio 2022 Community",
SetupUri = "https://aka.ms/vs/17/release/vs_community.exe",
WorkloadDocUri = "https://docs.microsoft.com/en-us/visualstudio/install/workload-component-id-vs-community?view=vs-2022",
WorkloadGitHubUri = "https://raw.githubusercontent.com/MicrosoftDocs/visualstudio-docs/master/docs/install/includes/vs-2022/workload-component-id-vs-community.md",
},

new VsEdition() {
Version = "17P",
Name = "Visual Studio 2022 Professional",
SetupUri = "https://aka.ms/vs/17/release/vs_professional.exe",
WorkloadDocUri = "https://docs.microsoft.com/en-us/visualstudio/install/workload-component-id-vs-professional?view=vs-2022",
WorkloadGitHubUri = "https://raw.githubusercontent.com/MicrosoftDocs/visualstudio-docs/master/docs/install/includes/vs-2022/workload-component-id-vs-professional.md",
},

new VsEdition() {
Version = "17E",
Name = "Visual Studio 2022 Enterprise",
SetupUri = "https://aka.ms/vs/17/release/vs_enterprise.exe",
WorkloadDocUri = "https://docs.microsoft.com/en-us/visualstudio/install/workload-component-id-vs-enterprise?view=vs-2022",
WorkloadGitHubUri = "https://raw.githubusercontent.com/MicrosoftDocs/visualstudio-docs/master/docs/install/includes/vs-2022/workload-component-id-vs-enterprise.md",
}
};
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@
<PackageIcon></PackageIcon>
<RepositoryUrl>https://github.com/deepak-rathi/VS2017OfflineSetupUtility</RepositoryUrl>
<RepositoryType>Git</RepositoryType>
<PackageReleaseNotes>Added .Net Core 3.1</PackageReleaseNotes>
<PackageReleaseNotes>Added VS2022</PackageReleaseNotes>
<PackageId>VS2017OfflineSetupUtility</PackageId>
<ApplicationIcon>Assets\logo.ico</ApplicationIcon>
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
<PackageLicenseFile>LICENSE</PackageLicenseFile>
<Copyright>Copyright © 2017-2020 Deepak Rathi</Copyright>
<Description>This utility allow downloading offline setup or deletion of old version Visual Studio 2017/2019 Offline Setup files and folder.</Description>
<Copyright>Copyright © 2017-2021 Deepak Rathi</Copyright>
<Description>This utility allow downloading offline setup or deletion of old version Visual Studio 2017/2019/2022 Offline Setup files and folder.</Description>
<AssemblyName>VS2017OfflineSetupUtility</AssemblyName>
</PropertyGroup>

Expand All @@ -42,7 +42,7 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="Newtonsoft.Json" Version="12.0.3" />
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
</ItemGroup>

<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ public DelegateCommand SelectFolderCommand
var folderBrowserDialog = new System.Windows.Forms.FolderBrowserDialog();
try
{
folderBrowserDialog.Description = "Select VS2017 or VS2019 offline setup folder";
folderBrowserDialog.Description = "Select VS2017 or VS2019 or VS2022 offline setup folder";

var dialogResult = folderBrowserDialog.ShowDialog();
if (dialogResult != System.Windows.Forms.DialogResult.OK && string.IsNullOrWhiteSpace(folderBrowserDialog.SelectedPath))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ public DelegateCommand SelectFolderCommand
var folderBrowserDialog = new System.Windows.Forms.FolderBrowserDialog();
try
{
folderBrowserDialog.Description = "Select VS2017 or VS2019 offline setup folder";
folderBrowserDialog.Description = "Select VS2017 or VS2019 or VS2022 offline setup folder";

var dialogResult = folderBrowserDialog.ShowDialog();
if (dialogResult != System.Windows.Forms.DialogResult.OK && string.IsNullOrWhiteSpace(folderBrowserDialog.SelectedPath))
Expand Down
18 changes: 9 additions & 9 deletions VS2017OfflineSetupUtility/Views/CleanUtilPage.xaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<!--
Copyright © 2017-2019 Deepak Rathi
Copyright © 2017-2021 Deepak Rathi
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
Expand All @@ -21,7 +21,7 @@
xmlns:viewModel="clr-namespace:VS2017OfflineSetupUtility.ViewModels"
mc:Ignorable="d"
d:DesignHeight="720" d:DesignWidth="1080"
Title="VS2017/2019 Offline Clean Util" Loaded="Page_Loaded">
Title="VS2017/2019/2022 Offline Clean Util" Loaded="Page_Loaded">

<Page.DataContext>
<viewModel:CleanUtilPageViewModel/>
Expand All @@ -43,7 +43,7 @@
</Grid.RowDefinitions>

<!--#region Header-->
<TextBlock Grid.Row="0" Text="VS2017/2019 Offline Setup Utility" Style="{StaticResource AppHeaderTextBlockStyle}"/>
<TextBlock Grid.Row="0" Text="VS2017/2019/2022 Offline Setup Utility" Style="{StaticResource AppHeaderTextBlockStyle}"/>
<Rectangle Grid.Row="0" VerticalAlignment="Bottom" Style="{StaticResource HorizontalSeperatorStyle}"/>
<!--#endregion Header-->

Expand All @@ -55,7 +55,7 @@
<ColumnDefinition Width="Auto" />
</Grid.ColumnDefinitions>

<TextBlock Text="(C) 2017-2019 Deepak Rathi. THIS APPLICATION IS PROVIDED AS IS WITH OUT ANY WARRANTY OF ANY KIND. DEVELOPER OF THIS APP IS NOT RESPONSIBLE FOR ANY PROBLEM/ISSUE/DEFECTS CAUSED DUE TO THIS APPLICATION OR ANY CONTENT IN THIS APPLICATION. THIS APP IS NOT AFFILIATED TO MICROSOFT OR ANY OTHER THIRD PARTY. NO USER DATA IS COLLECTED BY DEVELOPER OF THIS APP."
<TextBlock Text="(C) 2017-2021 Deepak Rathi. THIS APPLICATION IS PROVIDED AS IS WITH OUT ANY WARRANTY OF ANY KIND. DEVELOPER OF THIS APP IS NOT RESPONSIBLE FOR ANY PROBLEM/ISSUE/DEFECTS CAUSED DUE TO THIS APPLICATION OR ANY CONTENT IN THIS APPLICATION. THIS APP IS NOT AFFILIATED TO MICROSOFT OR ANY OTHER THIRD PARTY. NO USER DATA IS COLLECTED BY DEVELOPER OF THIS APP."
Padding="20" TextWrapping="Wrap" Foreground="Gray"
Grid.Column="0"/>
<Button Content="Delete" Grid.Column="1" Width="80" Height="30" Background="{StaticResource RedSolidColorBrush}" Margin="10" Foreground="White"
Expand All @@ -77,7 +77,7 @@

<!--#region Left Content-->
<StackPanel Grid.Column="0">
<TextBlock Text="1. Select Visual Studio 2017/2019 Offline Setup Folder" Style="{StaticResource LeftContentTextBlockStyle}"/>
<TextBlock Text="1. Select Visual Studio 2017/2019/2022 Offline Setup Folder" Style="{StaticResource LeftContentTextBlockStyle}"/>
<TextBlock Text="2. Verify list of old folders with version number" Style="{StaticResource LeftContentTextBlockStyle}"/>
<TextBlock Text="3. Delete directories with old version from offline setup folder" Style="{StaticResource LeftContentTextBlockStyle}"/>
</StackPanel>
Expand All @@ -91,7 +91,7 @@
<RowDefinition />
</Grid.RowDefinitions>

<TextBlock Text="This utility allow deletion of old version Visual Studio 2017/2019 Offline Setup files" Grid.Row="0" Style="{StaticResource HeaderTextBlockStyle}" Padding="17"/>
<TextBlock Text="This utility allow deletion of old version Visual Studio 2017/2019/2022 Offline Setup files" Grid.Row="0" Style="{StaticResource HeaderTextBlockStyle}" Padding="17"/>
<Grid Grid.Row="1" VerticalAlignment="Top" HorizontalAlignment="Stretch">
<Grid.RowDefinitions>
<RowDefinition Height="auto"/>
Expand Down Expand Up @@ -121,11 +121,11 @@
<StackPanel Grid.Column="4">
<TextBlock Text="Selected feature details" Padding="14" Style="{StaticResource HeaderTextBlockStyle}"/>
<TextBlock Text="Feature name" Style="{StaticResource SubHeaderTextBlockStyle}" Padding="14,5"/>
<TextBlock Text="VS2017/2019 Offline Clean Util" Style="{StaticResource BodyTextBlockStyle}" Padding="14,0"/>
<TextBlock Text="VS2017/2019/2022 Offline Clean Util" Style="{StaticResource BodyTextBlockStyle}" Padding="14,0"/>
<TextBlock Text="About" Style="{StaticResource SubHeaderTextBlockStyle}" Padding="14,20,14,5"/>
<TextBlock Text="Allow deletion of old version Visual Studio 2017/2019 Offline Setup files and folder, which saves your hard disk space." Style="{StaticResource BodyTextBlockStyle}" Padding="14,0"/>
<TextBlock Text="Allow deletion of old version Visual Studio 2017/2019/2022 Offline Setup files and folder, which saves your hard disk space." Style="{StaticResource BodyTextBlockStyle}" Padding="14,0"/>
<TextBlock Text="Version" Style="{StaticResource SubHeaderTextBlockStyle}" Padding="14,20,14,5"/>
<TextBlock Text="1.4.0.0" Style="{StaticResource BodyTextBlockStyle}" Padding="14,0"/>
<TextBlock Text="1.4.1.0" Style="{StaticResource BodyTextBlockStyle}" Padding="14,0"/>
</StackPanel>
<!--#endregion Right Content-->
</Grid>
Expand Down
16 changes: 8 additions & 8 deletions VS2017OfflineSetupUtility/Views/DownloadUtilPage.xaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<!--
Copyright © 2017-2019 Deepak Rathi
Copyright © 2017-2021 Deepak Rathi
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
Expand All @@ -21,7 +21,7 @@
xmlns:viewModel="clr-namespace:VS2017OfflineSetupUtility.ViewModels"
mc:Ignorable="d"
d:DesignHeight="720" d:DesignWidth="1080"
Title="VS2017/2019 Offline Setup Utility" Loaded="Page_Loaded">
Title="VS2017/2019/2022 Offline Setup Utility" Loaded="Page_Loaded">

<Page.DataContext>
<viewModel:DownloadUtilPageViewModel/>
Expand Down Expand Up @@ -52,7 +52,7 @@
</Grid.RowDefinitions>

<!--#region Header-->
<TextBlock Grid.Row="0" Text="VS2017/2019 Offline Setup Utility" Style="{StaticResource AppHeaderTextBlockStyle}"/>
<TextBlock Grid.Row="0" Text="VS2017/2019/2022 Offline Setup Utility" Style="{StaticResource AppHeaderTextBlockStyle}"/>
<Rectangle Grid.Row="0" VerticalAlignment="Bottom" Style="{StaticResource HorizontalSeperatorStyle}"/>
<!--#endregion Header-->

Expand All @@ -64,7 +64,7 @@
<ColumnDefinition Width="Auto" />
</Grid.ColumnDefinitions>

<TextBlock Text="(C) 2017-2019 Deepak Rathi. THIS APPLICATION IS PROVIDED AS IS WITH OUT ANY WARRANTY OF ANY KIND. DEVELOPER OF THIS APP IS NOT RESPONSIBLE FOR ANY PROBLEM/ISSUE/DEFECTS CAUSED DUE TO THIS APPLICATION OR ANY CONTENT IN THIS APPLICATION. THIS APP IS NOT AFFILIATED TO MICROSOFT OR ANY OTHER THIRD PARTY. NO USER DATA IS COLLECTED BY DEVELOPER OF THIS APP."
<TextBlock Text="(C) 2017-2021 Deepak Rathi. THIS APPLICATION IS PROVIDED AS IS WITH OUT ANY WARRANTY OF ANY KIND. DEVELOPER OF THIS APP IS NOT RESPONSIBLE FOR ANY PROBLEM/ISSUE/DEFECTS CAUSED DUE TO THIS APPLICATION OR ANY CONTENT IN THIS APPLICATION. THIS APP IS NOT AFFILIATED TO MICROSOFT OR ANY OTHER THIRD PARTY. NO USER DATA IS COLLECTED BY DEVELOPER OF THIS APP."
Padding="20" TextWrapping="Wrap" Foreground="Gray"
Grid.Column="0"/>
<Button Content="Download" Grid.Column="1" Width="80" Height="30" Background="{StaticResource GreenSolidColorBrush}" Margin="10" Foreground="White"
Expand All @@ -86,7 +86,7 @@

<!--#region Left Content-->
<StackPanel Grid.Column="0">
<TextBlock Text="1. Select a folder to store offline files and select Visual Studio 2017/2019 Edition" Style="{StaticResource LeftContentTextBlockStyle}"/>
<TextBlock Text="1. Select a folder to store offline files and select Visual Studio 2017/2019/2022 Edition" Style="{StaticResource LeftContentTextBlockStyle}"/>
<TextBlock Text="2. Select language, optional and recommended install option" Style="{StaticResource LeftContentTextBlockStyle}"/>
<TextBlock Text="3. Select Workload or customise it as per your need. &#x0a;Note*: If no checkbox is selected, all workload packages will be installed. &#x0a;Editor require atleast first two workloads to be selected if workload is customised." Style="{StaticResource LeftContentTextBlockStyle}"/>
<TextBlock Text="4. Verify CLI command and click download. This will run CLI command in command prompt." Style="{StaticResource LeftContentTextBlockStyle}"/>
Expand Down Expand Up @@ -172,11 +172,11 @@
<StackPanel Grid.Column="4">
<TextBlock Text="Selected feature details" Padding="14" Style="{StaticResource HeaderTextBlockStyle}"/>
<TextBlock Text="Feature name" Style="{StaticResource SubHeaderTextBlockStyle}" Padding="14,5"/>
<TextBlock Text="VS2017/2019 Offline Download" Style="{StaticResource BodyTextBlockStyle}" Padding="14,0"/>
<TextBlock Text="VS2017/2019/2022 Offline Download" Style="{StaticResource BodyTextBlockStyle}" Padding="14,0"/>
<TextBlock Text="About" Style="{StaticResource SubHeaderTextBlockStyle}" Padding="14,20,14,5"/>
<TextBlock Text="Download Visual Studio 2017/2019 Offline Setup files and folder, using command line interface. (Need internet connection)" Style="{StaticResource BodyTextBlockStyle}" Padding="14,0"/>
<TextBlock Text="Download Visual Studio 2017/2019/2022 Offline Setup files and folder, using command line interface. (Need internet connection)" Style="{StaticResource BodyTextBlockStyle}" Padding="14,0"/>
<TextBlock Text="Version" Style="{StaticResource SubHeaderTextBlockStyle}" Padding="14,20,14,5"/>
<TextBlock Text="1.4.0.0" Style="{StaticResource BodyTextBlockStyle}" Padding="14,0"/>
<TextBlock Text="1.4.1.0" Style="{StaticResource BodyTextBlockStyle}" Padding="14,0"/>
</StackPanel>
<!--#endregion Right Content-->
</Grid>
Expand Down
Loading

0 comments on commit e3a3058

Please sign in to comment.