├── art
├── context-menu.png
├── nested-files.png
└── nested-files-dark.png
├── src
├── Resources
│ ├── logo.png
│ ├── Images.png
│ └── preview.png
├── source.extension.ico
├── Nesters
│ ├── IFileNester.cs
│ ├── Automated
│ │ ├── AddedExtensionNester.cs
│ │ ├── VsDocNester.cs
│ │ ├── BundleNester.cs
│ │ ├── SpriteNester.cs
│ │ ├── KnownFileTypeNester.cs
│ │ ├── PathSegmentFileNester.cs
│ │ └── InterfaceImplementationNester.cs
│ ├── FileNestingFactory.cs
│ └── ManualNester.cs
├── Properties
│ └── AssemblyInfo.cs
├── source.extension.cs
├── Dialogs
│ ├── ItemSelector.xaml
│ ├── NestingOptions.cs
│ └── ItemSelector.xaml.cs
├── MenuItems
│ ├── RunAutoNestingButton.cs
│ ├── NestButton.cs
│ ├── EnableAutoNestButton.cs
│ └── UnNestButton.cs
├── Helpers
│ ├── Logger.cs
│ └── Helpers.cs
├── source.extension.vsixmanifest
├── VSCommandTable.cs
├── VSPackage.cs
├── website.pkgdef
├── VSCommandTable.vsct
├── source.extension.resx
└── FileNesting.csproj
├── .editorconfig
├── .gitignore
├── .github
├── ISSUE_TEMPLATE.md
└── CONTRIBUTING.md
├── LICENSE
├── .gitattributes
├── appveyor.yml
├── FileNesting.sln
└── README.md
/art/context-menu.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/madskristensen/FileNesting/master/art/context-menu.png
--------------------------------------------------------------------------------
/art/nested-files.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/madskristensen/FileNesting/master/art/nested-files.png
--------------------------------------------------------------------------------
/src/Resources/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/madskristensen/FileNesting/master/src/Resources/logo.png
--------------------------------------------------------------------------------
/src/Resources/Images.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/madskristensen/FileNesting/master/src/Resources/Images.png
--------------------------------------------------------------------------------
/src/source.extension.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/madskristensen/FileNesting/master/src/source.extension.ico
--------------------------------------------------------------------------------
/art/nested-files-dark.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/madskristensen/FileNesting/master/art/nested-files-dark.png
--------------------------------------------------------------------------------
/src/Resources/preview.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/madskristensen/FileNesting/master/src/Resources/preview.png
--------------------------------------------------------------------------------
/.editorconfig:
--------------------------------------------------------------------------------
1 | # Top-most EditorConfig file
2 | root = true
3 |
4 | [*]
5 | indent_style = space
6 | end_of_line = crlf
7 | indent_size = 4
8 |
9 | [*.json]
10 | indent_style = space
11 | indent_size = 2
--------------------------------------------------------------------------------
/src/Nesters/IFileNester.cs:
--------------------------------------------------------------------------------
1 |
2 | namespace MadsKristensen.FileNesting
3 | {
4 | public interface IFileNester
5 | {
6 | NestingResult Nest(string fileName);
7 | bool IsEnabled();
8 | }
9 |
10 | public enum NestingResult
11 | {
12 | Continue,
13 | StopProcessing,
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | packages
2 | .vs
3 |
4 | # User files
5 | *.suo
6 | *.user
7 | *.sln.docstates
8 | .vs/
9 |
10 | # Build results
11 |
12 | [Dd]ebug/
13 | [Rr]elease/
14 | x64/
15 | [Bb]in/
16 | [Oo]bj/
17 |
18 | # MSTest test Results
19 | [Tt]est[Rr]esult*/
20 | [Bb]uild[Ll]og.*
21 |
22 | # NCrunch
23 | *.ncrunchsolution
24 | *.ncrunchproject
25 | _NCrunch_WebCompiler
--------------------------------------------------------------------------------
/.github/ISSUE_TEMPLATE.md:
--------------------------------------------------------------------------------
1 | ### Installed product versions
2 | - Visual Studio: [example 2015 Professional]
3 | - This extension: [example 1.1.21]
4 |
5 | ### Description
6 | Replace this text with a short description
7 |
8 | ### Steps to recreate
9 | 1. Replace this
10 | 2. text with
11 | 3. the steps
12 | 4. to recreate
13 |
14 | ### Current behavior
15 | Explain what it's doing and why it's wrong
16 |
17 | ### Expected behavior
18 | Explain what it should be doing after it's fixed.
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | Copyright 2014 Mads Kristensen
2 |
3 | Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
4 |
5 | http://www.apache.org/licenses/LICENSE-2.0
6 |
7 | Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
--------------------------------------------------------------------------------
/.gitattributes:
--------------------------------------------------------------------------------
1 | # Auto detect text files and perform LF normalization
2 | * text=auto
3 |
4 | # Custom for Visual Studio
5 | *.cs diff=csharp
6 | *.sln merge=union
7 | *.csproj merge=union
8 | *.vbproj merge=union
9 | *.fsproj merge=union
10 | *.dbproj merge=union
11 |
12 | # Standard to msysgit
13 | *.doc diff=astextplain
14 | *.DOC diff=astextplain
15 | *.docx diff=astextplain
16 | *.DOCX diff=astextplain
17 | *.dot diff=astextplain
18 | *.DOT diff=astextplain
19 | *.pdf diff=astextplain
20 | *.PDF diff=astextplain
21 | *.rtf diff=astextplain
22 | *.RTF diff=astextplain
23 |
--------------------------------------------------------------------------------
/src/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Reflection;
3 | using System.Resources;
4 | using System.Runtime.InteropServices;
5 | using MadsKristensen.FileNesting;
6 |
7 | [assembly: AssemblyTitle(Vsix.Name)]
8 | [assembly: AssemblyDescription(Vsix.Description)]
9 | [assembly: AssemblyConfiguration("")]
10 | [assembly: AssemblyCompany(Vsix.Author)]
11 | [assembly: AssemblyProduct(Vsix.Name)]
12 | [assembly: AssemblyCopyright(Vsix.Author)]
13 | [assembly: AssemblyTrademark("")]
14 | [assembly: AssemblyCulture("")]
15 | [assembly: ComVisible(false)]
16 | [assembly: CLSCompliant(false)]
17 | [assembly: NeutralResourcesLanguage(Vsix.Language)]
18 |
19 | [assembly: AssemblyVersion(Vsix.Version)]
20 | [assembly: AssemblyFileVersion(Vsix.Version)]
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/src/Nesters/Automated/AddedExtensionNester.cs:
--------------------------------------------------------------------------------
1 | using System.IO;
2 | using EnvDTE;
3 |
4 | namespace MadsKristensen.FileNesting
5 | {
6 | internal class AddedExtensionNester : IFileNester
7 | {
8 | public NestingResult Nest(string fileName)
9 | {
10 | string trimmed = Path.GetFileNameWithoutExtension(fileName);
11 | ProjectItem item = FileNestingPackage.DTE.Solution.FindProjectItem(trimmed);
12 |
13 | if (item != null)
14 | {
15 | item.ProjectItems.AddFromFile(fileName);
16 | return NestingResult.StopProcessing;
17 | }
18 |
19 | return NestingResult.Continue;
20 | }
21 |
22 |
23 | public bool IsEnabled()
24 | {
25 | return FileNestingPackage.Options.EnableExtensionRule;
26 | }
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/appveyor.yml:
--------------------------------------------------------------------------------
1 | image: Visual Studio 2022
2 |
3 | install:
4 | - ps: (new-object Net.WebClient).DownloadString("https://raw.github.com/madskristensen/ExtensionScripts/master/AppVeyor/vsix.ps1") | iex
5 |
6 | before_build:
7 | - ps: Vsix-IncrementVsixVersion | Vsix-UpdateBuildVersion
8 | - ps: Vsix-TokenReplacement src\source.extension.cs 'Version = "([0-9\\.]+)"' 'Version = "{version}"'
9 |
10 | build_script:
11 | - nuget restore -verbosity quiet
12 | - msbuild /p:configuration=Release /p:DeployExtension=false /p:ZipPackageCompressionLevel=normal /v:m
13 |
14 | after_test:
15 | - ps: Vsix-PushArtifacts | Vsix-PublishToGallery
16 |
17 | before_deploy:
18 | - ps: Vsix-CreateChocolatyPackage -packageId filenesting
19 |
20 | deploy:
21 | - provider: Environment
22 | name: Chocolatey
23 | on:
24 | branch: master
25 | appveyor_repo_commit_message_extended: /\[release\]/
26 |
--------------------------------------------------------------------------------
/src/source.extension.cs:
--------------------------------------------------------------------------------
1 | // ------------------------------------------------------------------------------
2 | //
3 | // This file was generated by Extensibility Tools v1.10.211
4 | //
5 | // ------------------------------------------------------------------------------
6 | namespace MadsKristensen.FileNesting
7 | {
8 | static class Vsix
9 | {
10 | public const string Id = "6c799bc4-0d4c-4172-98bc-5d464b612dca";
11 | public const string Name = "File Nesting";
12 | public const string Description = @"Automatically nest files based on file name and enables developers to nest and unnest any file manually";
13 | public const string Language = "en-US";
14 | public const string Version = "2.7.1";
15 | public const string Author = "Mads Kristensen";
16 | public const string Tags = "file, nesting, solution explorer";
17 | }
18 | }
19 |
--------------------------------------------------------------------------------
/src/Nesters/Automated/VsDocNester.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using EnvDTE;
3 |
4 | namespace MadsKristensen.FileNesting
5 | {
6 | internal class VsDocNester : IFileNester
7 | {
8 | public NestingResult Nest(string fileName)
9 | {
10 | if (!fileName.EndsWith("-vsdoc.js", StringComparison.OrdinalIgnoreCase))
11 | return NestingResult.Continue;
12 |
13 | string parent = fileName.Replace("-vsdoc.js", ".js");
14 | ProjectItem item = FileNestingPackage.DTE.Solution.FindProjectItem(parent);
15 |
16 | if (item != null)
17 | {
18 | item.ProjectItems.AddFromFile(fileName);
19 | return NestingResult.StopProcessing;
20 | }
21 |
22 | return NestingResult.Continue;
23 | }
24 |
25 |
26 | public bool IsEnabled()
27 | {
28 | return FileNestingPackage.Options.EnableVsDocRule;
29 | }
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/src/Dialogs/ItemSelector.xaml:
--------------------------------------------------------------------------------
1 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/src/MenuItems/RunAutoNestingButton.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.ComponentModel.Design;
3 | using System.Linq;
4 | using EnvDTE;
5 | using EnvDTE80;
6 | using Microsoft.VisualStudio.Shell;
7 |
8 | namespace MadsKristensen.FileNesting
9 | {
10 | static class RunAutoNestingButton
11 | {
12 | private static DTE2 _dte;
13 |
14 | public static void Register(DTE2 dte, MenuCommandService mcs)
15 | {
16 | _dte = dte;
17 | CommandID nestAllId = new CommandID(PackageGuids.guidFileNestingCmdSet, PackageIds.cmdRunNesting);
18 | OleMenuCommand menuNestAll = new OleMenuCommand(NestAll, nestAllId);
19 | mcs.AddCommand(menuNestAll);
20 | }
21 |
22 | private static void NestAll(object sender, EventArgs e)
23 | {
24 | var selected = Helpers.GetSelectedItemsRecursive().Distinct();
25 | _dte.StatusBar.Text = "Nesting files...";
26 |
27 | foreach (ProjectItem item in selected)
28 | {
29 | FileNestingFactory.RunNesting(item);
30 | }
31 |
32 | _dte.StatusBar.Clear();
33 | }
34 | }
35 | }
--------------------------------------------------------------------------------
/src/Helpers/Logger.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Microsoft.VisualStudio.Shell;
3 | using Microsoft.VisualStudio.Shell.Interop;
4 | using Task = System.Threading.Tasks.Task;
5 |
6 | internal static class Logger
7 | {
8 | private static string _name;
9 | private static IVsOutputWindowPane _pane;
10 | private static IVsOutputWindow _output;
11 |
12 | public static async Task Initialize(AsyncPackage provider, string name)
13 | {
14 | _output = await provider.GetServiceAsync(typeof(SVsOutputWindow)) as IVsOutputWindow;
15 | _name = name;
16 | }
17 |
18 | public static void Log(object message)
19 | {
20 | try
21 | {
22 | if (EnsurePane())
23 | {
24 | _pane.OutputString(DateTime.Now.ToString() + ": " + message + Environment.NewLine);
25 | }
26 | }
27 | catch (Exception ex)
28 | {
29 | System.Diagnostics.Debug.Write(ex);
30 | }
31 | }
32 |
33 | private static bool EnsurePane()
34 | {
35 | if (_pane == null)
36 | {
37 | Guid guid = Guid.NewGuid();
38 | _output.CreatePane(ref guid, _name, 1, 1);
39 | _output.GetPane(ref guid, out _pane);
40 | }
41 |
42 | return _pane != null;
43 | }
44 | }
--------------------------------------------------------------------------------
/src/MenuItems/NestButton.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.ComponentModel.Design;
4 | using System.Linq;
5 | using EnvDTE;
6 | using Microsoft.VisualStudio;
7 | using Microsoft.VisualStudio.Shell;
8 |
9 | namespace MadsKristensen.FileNesting
10 | {
11 | static class NestButton
12 | {
13 | private static IEnumerable _items;
14 |
15 | public static void Register(MenuCommandService mcs)
16 | {
17 | CommandID nestId = new CommandID(PackageGuids.guidFileNestingCmdSet, PackageIds.cmdNest);
18 | OleMenuCommand menuNest = new OleMenuCommand(Nest, nestId);
19 | mcs.AddCommand(menuNest);
20 | menuNest.BeforeQueryStatus += BeforeNest;
21 | }
22 |
23 | private static void BeforeNest(object sender, EventArgs e)
24 | {
25 | var button = (OleMenuCommand)sender;
26 | _items = Helpers.GetSelectedItems().Where(i => (i.Kind.Equals(VSConstants.ItemTypeGuid.PhysicalFile_string, StringComparison.OrdinalIgnoreCase) && i.ProjectItems != null));
27 | button.Enabled = _items.Any();
28 | }
29 |
30 | private static void Nest(object sender, EventArgs e)
31 | {
32 | ManualNester.Nest(_items);
33 | }
34 | }
35 | }
--------------------------------------------------------------------------------
/FileNesting.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio 14
4 | VisualStudioVersion = 14.0.24720.0
5 | MinimumVisualStudioVersion = 10.0.40219.1
6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "FileNesting", "src\FileNesting.csproj", "{25F9FD9B-5EB2-4B27-93FB-05955B7D115F}"
7 | EndProject
8 | Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{B1D58043-DD3B-4BC0-9857-EB9EAE43D9A9}"
9 | ProjectSection(SolutionItems) = preProject
10 | appveyor.yml = appveyor.yml
11 | README.md = README.md
12 | EndProjectSection
13 | EndProject
14 | Global
15 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
16 | Debug|Any CPU = Debug|Any CPU
17 | Release|Any CPU = Release|Any CPU
18 | EndGlobalSection
19 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
20 | {25F9FD9B-5EB2-4B27-93FB-05955B7D115F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
21 | {25F9FD9B-5EB2-4B27-93FB-05955B7D115F}.Debug|Any CPU.Build.0 = Debug|Any CPU
22 | {25F9FD9B-5EB2-4B27-93FB-05955B7D115F}.Release|Any CPU.ActiveCfg = Release|Any CPU
23 | {25F9FD9B-5EB2-4B27-93FB-05955B7D115F}.Release|Any CPU.Build.0 = Release|Any CPU
24 | EndGlobalSection
25 | GlobalSection(SolutionProperties) = preSolution
26 | HideSolutionNode = FALSE
27 | EndGlobalSection
28 | EndGlobal
29 |
--------------------------------------------------------------------------------
/src/MenuItems/EnableAutoNestButton.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.ComponentModel.Design;
3 | using EnvDTE80;
4 | using Microsoft.VisualStudio.Shell;
5 |
6 | namespace MadsKristensen.FileNesting
7 | {
8 | static class EnableAutoNestButton
9 | {
10 | private static DTE2 _dte;
11 |
12 | public static void Register(DTE2 dte, MenuCommandService mcs)
13 | {
14 | _dte = dte;
15 | CommandID autoId = new CommandID(PackageGuids.guidFileNestingCmdSet, PackageIds.cmdAutoNesting);
16 | OleMenuCommand menuAuto = new OleMenuCommand(AutoNest, autoId);
17 | mcs.AddCommand(menuAuto);
18 | menuAuto.BeforeQueryStatus += BeforeAutoNest;
19 | }
20 |
21 | private static void BeforeAutoNest(object sender, EventArgs e)
22 | {
23 | var button = (OleMenuCommand)sender;
24 | button.Checked = FileNestingPackage.Options.EnableAutoNesting;
25 | }
26 |
27 | private static void AutoNest(object sender, EventArgs e)
28 | {
29 | var isEnabled = FileNestingPackage.Options.EnableAutoNesting;
30 |
31 | _dte.StatusBar.Text = "Automatic file nesting " + (isEnabled ? "disabled" : "enabled");
32 |
33 | FileNestingPackage.Options.EnableAutoNesting = !isEnabled;
34 | }
35 | }
36 | }
--------------------------------------------------------------------------------
/src/Nesters/Automated/BundleNester.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 | using System.IO;
3 | using EnvDTE;
4 |
5 | namespace MadsKristensen.FileNesting
6 | {
7 | internal class BundleNester : IFileNester
8 | {
9 | private static Dictionary _mapping = new Dictionary(){
10 | {".js", new [] {".bundle"}},
11 | {".css", new [] {".bundle"}},
12 | {".html", new [] {".bundle"}},
13 | };
14 |
15 | public NestingResult Nest(string fileName)
16 | {
17 | string extension = Path.GetExtension(fileName).ToLowerInvariant();
18 |
19 | if (!_mapping.ContainsKey(extension))
20 | return NestingResult.Continue;
21 |
22 | foreach (string ext in _mapping[extension])
23 | {
24 | string parent = fileName + ext;
25 | ProjectItem item = FileNestingPackage.DTE.Solution.FindProjectItem(parent);
26 |
27 | if (item != null)
28 | {
29 | item.ProjectItems.AddFromFile(fileName);
30 | return NestingResult.StopProcessing;
31 | }
32 | }
33 |
34 | return NestingResult.Continue;
35 | }
36 |
37 | public bool IsEnabled()
38 | {
39 | return FileNestingPackage.Options.EnableBundleRule;
40 | }
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/src/Nesters/Automated/SpriteNester.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 | using System.IO;
3 | using EnvDTE;
4 |
5 | namespace MadsKristensen.FileNesting
6 | {
7 | internal class SpriteNester : IFileNester
8 | {
9 | private static Dictionary _mapping = new Dictionary(){
10 | {".png", new [] {".sprite"}},
11 | {".jpg", new [] {".sprite"}},
12 | {".gif", new [] {".sprite"}},
13 | };
14 |
15 | public NestingResult Nest(string fileName)
16 | {
17 | string extension = Path.GetExtension(fileName).ToLowerInvariant();
18 |
19 | if (!_mapping.ContainsKey(extension))
20 | return NestingResult.Continue;
21 |
22 | foreach (string ext in _mapping[extension])
23 | {
24 | string parent = Path.ChangeExtension(fileName, ext);
25 | ProjectItem item = FileNestingPackage.DTE.Solution.FindProjectItem(parent);
26 |
27 | if (item != null)
28 | {
29 | item.ProjectItems.AddFromFile(fileName);
30 | return NestingResult.StopProcessing;
31 | }
32 | }
33 |
34 | return NestingResult.Continue;
35 | }
36 |
37 | public bool IsEnabled()
38 | {
39 | return FileNestingPackage.Options.EnableSpriteRule;
40 | }
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/src/MenuItems/UnNestButton.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.ComponentModel.Design;
4 | using System.Linq;
5 | using EnvDTE;
6 | using Microsoft.VisualStudio;
7 | using Microsoft.VisualStudio.Shell;
8 |
9 | namespace MadsKristensen.FileNesting
10 | {
11 | static class UnNestButton
12 | {
13 | private static IEnumerable _nested;
14 |
15 | public static void Register(MenuCommandService mcs)
16 | {
17 | CommandID unNestId = new CommandID(PackageGuids.guidFileNestingCmdSet, PackageIds.cmdUnNest);
18 | OleMenuCommand menuUnNest = new OleMenuCommand(UnNest, unNestId);
19 | mcs.AddCommand(menuUnNest);
20 | menuUnNest.BeforeQueryStatus += BeforeUnNest;
21 | }
22 |
23 | private static void BeforeUnNest(object sender, EventArgs e)
24 | {
25 | _nested = from p in Helpers.GetSelectedItems()
26 | let parent = p.Collection.Parent as ProjectItem
27 | where parent != null && !parent.Kind.Equals(VSConstants.ItemTypeGuid.PhysicalFolder_string, StringComparison.OrdinalIgnoreCase)
28 | select p;
29 |
30 | var button = (OleMenuCommand)sender;
31 | button.Enabled = _nested.Any();
32 | }
33 |
34 | private static void UnNest(object sender, EventArgs e)
35 | {
36 | FileNestingFactory.Enabled = false;
37 |
38 | foreach (ProjectItem item in _nested)
39 | {
40 | ManualNester.UnNest(item);
41 | }
42 |
43 | FileNestingFactory.Enabled = true;
44 | }
45 | }
46 | }
--------------------------------------------------------------------------------
/src/Nesters/Automated/KnownFileTypeNester.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 | using System.IO;
3 | using EnvDTE;
4 |
5 | namespace MadsKristensen.FileNesting
6 | {
7 | internal class KnownFileTypeNester : IFileNester
8 | {
9 | private static Dictionary _mapping = new Dictionary(){
10 | {".js", new [] {".coffee", ".litcoffee", ".iced", ".ts", ".tsx", ".dart", ".html", ".cshtml", ".vbhtml", ".aspx", ".master", ".ascx", ".vue"}},
11 | {".css", new [] {".less", ".scss", ".sass", ".styl", ".html", ".cshtml", ".vbhtml", ".aspx", ".master", ".ascx"}},
12 | {".ts", new [] {".html", ".cshtml", ".vbhtml", ".aspx", ".master", ".ascx"}},
13 | {".map", new [] {".js", ".css"}},
14 | };
15 |
16 | public NestingResult Nest(string fileName)
17 | {
18 | string extension = Path.GetExtension(fileName).ToLowerInvariant();
19 |
20 | if (!_mapping.ContainsKey(extension))
21 | return NestingResult.Continue;
22 |
23 | foreach (string ext in _mapping[extension])
24 | {
25 | string parent = Path.ChangeExtension(fileName, ext);
26 | ProjectItem item = FileNestingPackage.DTE.Solution.FindProjectItem(parent);
27 |
28 | if (item != null)
29 | {
30 | item.ProjectItems.AddFromFile(fileName);
31 | return NestingResult.StopProcessing;
32 | }
33 | }
34 |
35 | return NestingResult.Continue;
36 | }
37 |
38 | public bool IsEnabled()
39 | {
40 | return FileNestingPackage.Options.EnableKnownFileTypeRule;
41 | }
42 | }
43 | }
44 |
--------------------------------------------------------------------------------
/src/source.extension.vsixmanifest:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | File Nesting
6 | Automatically nest files based on file name and enables developers to nest and unnest any file manually
7 | https://visualstudiogallery.msdn.microsoft.com/3ebde8fb-26d8-4374-a0eb-1e4e2665070c
8 | Resources\LICENSE
9 | Resources\logo.png
10 | Resources\preview.png
11 | file, nesting, solution explorer
12 |
13 |
14 |
15 | amd64
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/src/Nesters/Automated/PathSegmentFileNester.cs:
--------------------------------------------------------------------------------
1 | using System.IO;
2 | using System.Linq;
3 | using EnvDTE;
4 |
5 | namespace MadsKristensen.FileNesting
6 | {
7 | internal class PathSegmentNester : IFileNester
8 | {
9 | public NestingResult Nest(string fileName)
10 | {
11 | if (!IsSupported(fileName))
12 | return NestingResult.Continue;
13 |
14 | string name = Path.GetFileNameWithoutExtension(fileName);
15 |
16 | int index = name.LastIndexOf('.');
17 | if (index > -1)
18 | {
19 | string directory = Path.GetDirectoryName(fileName);
20 | string extension = Path.GetExtension(fileName);
21 | string firstName = name.Substring(0, index);
22 | string parentFileName = Path.Combine(directory, firstName + extension);
23 |
24 | ProjectItem parent = FileNestingPackage.DTE.Solution.FindProjectItem(parentFileName);
25 | if (parent != null)
26 | {
27 | parent.ProjectItems.AddFromFile(fileName);
28 | return NestingResult.StopProcessing;
29 | }
30 | }
31 |
32 | return NestingResult.Continue;
33 | }
34 |
35 | private static bool IsSupported(string fileName)
36 | {
37 | string extension = Path.GetExtension(fileName).ToLowerInvariant();
38 | string[] allowed = new[] { ".js", ".css", ".html", ".htm", ".less", ".scss", ".coffee", ".iced", ".config", ".cs", "vb", ".sql", ".vue" };
39 |
40 | return allowed.Contains(extension);
41 | }
42 |
43 | public bool IsEnabled()
44 | {
45 | return FileNestingPackage.Options.EnablePathSegmentRule;
46 | }
47 | }
48 | }
49 |
--------------------------------------------------------------------------------
/src/VSCommandTable.cs:
--------------------------------------------------------------------------------
1 | // ------------------------------------------------------------------------------
2 | //
3 | // This file was generated by Extensibility Tools 2015 v1.7.160
4 | //
5 | // ------------------------------------------------------------------------------
6 | namespace MadsKristensen.FileNesting
7 | {
8 | using System;
9 |
10 | ///
11 | /// Helper class that exposes all GUIDs used across VS Package.
12 | ///
13 | internal sealed partial class PackageGuids
14 | {
15 | public const string guidFileNestingPkgString = "6c799bc4-0d4c-4172-98bc-5d464b612dca";
16 | public const string guidFileNestingCmdSetString = "a5bb8f41-d79a-4de2-bd13-857f39dd0f3f";
17 | public const string guidImagesString = "c24fa2f3-0d5d-498f-8bee-2947e84addbd";
18 | public static Guid guidFileNestingPkg = new Guid(guidFileNestingPkgString);
19 | public static Guid guidFileNestingCmdSet = new Guid(guidFileNestingCmdSetString);
20 | public static Guid guidImages = new Guid(guidImagesString);
21 | }
22 | ///
23 | /// Helper class that encapsulates all CommandIDs uses across VS Package.
24 | ///
25 | internal sealed partial class PackageIds
26 | {
27 | public const int NestingMenu = 0x1000;
28 | public const int MyMenuGroup = 0x1020;
29 | public const int cmdUnNest = 0x1030;
30 | public const int cmdNest = 0x1040;
31 | public const int AutoNestGroup = 0x1050;
32 | public const int cmdAutoNesting = 0x1060;
33 | public const int cmdRunNesting = 0x1070;
34 | public const int bmpPic1 = 0x0001;
35 | public const int bmpPic2 = 0x0002;
36 | public const int bmpPicSearch = 0x0003;
37 | public const int bmpPicX = 0x0004;
38 | public const int bmpPicArrows = 0x0005;
39 | public const int bmpPicStrikethrough = 0x0006;
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # File Nesting
2 |
3 | [](https://ci.appveyor.com/project/madskristensen/filenesting)
4 |
5 | Download File Nesting from the [VS Gallery](http://visualstudiogallery.msdn.microsoft.com/3ebde8fb-26d8-4374-a0eb-1e4e2665070c)
6 | or get the [CI build](http://vsixgallery.com/extension/6c799bc4-0d4c-4172-98bc-5d464b612dca/).
7 |
8 | ---------------------------------------------------------------
9 |
10 | Automatically nest files based on file name and enables
11 | developers to nest and unnest any file manually
12 |
13 | See the
14 | [demo video](http://channel9.msdn.com/Blogs/MadsKristensen/Introducing-File-Nestor-for-Visual-Studio)
15 | on Channel 9.
16 |
17 | **Announcement:** Visual Studio 2017 15.6 introduced support for [customizing how files are nested in ASP.NET Core projects](https://blogs.msdn.microsoft.com/webdev/2018/02/07/file-nesting-in-solution-explorer/)
18 |
19 | ## Features
20 |
21 | - Manually nest files
22 | - Manually un-nest files
23 | - Auto-nesting based on naming conventions
24 | - Option to enable auto-nesting when files are added or renamed
25 | - Options to specify which naming conventions to apply
26 | - Keyboard shortcut for manual nesting (Ctrl+Alt+N)
27 |
28 | You can both nest and un-nest any file with ease.
29 |
30 | 
31 |
32 | File Nesting also gives you the option to automatically nest
33 | based on file naming rules. You can then apply those rules to
34 | any files, folders or entire projects.
35 |
36 | Here's a screenshot of that:
37 |
38 | 
39 | 
40 |
41 | ## Known issues
42 |
43 | Due to missing or limited support for file nesting in certain
44 | project types, this extension will have no effect or be
45 | disabled. The project types are:
46 |
47 | - Node.js projects (NTVS)
48 | - ASP.NET Core
49 | - Apache Cordova
50 | - Shared projects
51 |
52 | There is nothing this extension can do to provide nesting
53 | in those project types. The support has to be added to the
54 | project type itself before support can be added.
55 |
56 | ## Contribute
57 | Check out the [contribution guidelines](.github/CONTRIBUTING.md)
58 | if you want to contribute to this project.
59 |
60 | For cloning and building this project yourself, make sure
61 | to install the
62 | [Extensibility Tools 2015](https://visualstudiogallery.msdn.microsoft.com/ab39a092-1343-46e2-b0f1-6a3f91155aa6)
63 | extension for Visual Studio which enables some features
64 | used by this project.
65 |
66 | ## License
67 | [Apache 2.0](LICENSE)
68 |
--------------------------------------------------------------------------------
/src/Dialogs/NestingOptions.cs:
--------------------------------------------------------------------------------
1 | using System.ComponentModel;
2 | using Microsoft.VisualStudio.Shell;
3 |
4 | namespace MadsKristensen.FileNesting
5 | {
6 | public class NestingOptions : DialogPage
7 | {
8 | [LocDisplayName("Enable auto-nesting")]
9 | [Description("Enables automatic nesting when files are added or renamed")]
10 | [Category("File Nesting")]
11 | [DefaultValue(true)]
12 | public bool EnableAutoNesting { get; set; }
13 |
14 | // Rules
15 | [LocDisplayName("Enable extension rule")]
16 | [Description("Files with an added extension nests under parent. Example: foo.js.map nests under foo.js")]
17 | [Category("Nesting rules")]
18 | [DefaultValue(true)]
19 | public bool EnableExtensionRule { get; set; }
20 |
21 | [LocDisplayName("Enable path segment rule")]
22 | [Description("Files with an added path segment nests under parent. Example: foo.min.js nests under foo.js")]
23 | [Category("Nesting rules")]
24 | [DefaultValue(true)]
25 | public bool EnablePathSegmentRule { get; set; }
26 |
27 | [LocDisplayName("Enable .bundle file rule")]
28 | [Description("Files with .bundle extension will be parent. Example: foo.js.bundle will nest foo.js under it")]
29 | [Category("Nesting rules")]
30 | [DefaultValue(true)]
31 | public bool EnableBundleRule { get; set; }
32 |
33 | [LocDisplayName("Enable .sprite file rule")]
34 | [Description("Files with .sprite extension will be parent. Example: foo.sprite will nest foo.png under it")]
35 | [Category("Nesting rules")]
36 | [DefaultValue(true)]
37 | public bool EnableSpriteRule { get; set; }
38 |
39 | [LocDisplayName("Enable known file type rule")]
40 | [Description("Some known file types will be nested. Example: foo.css will nest under foo.less")]
41 | [Category("Nesting rules")]
42 | [DefaultValue(true)]
43 | public bool EnableKnownFileTypeRule { get; set; }
44 |
45 | [LocDisplayName("Enable -vsdoc.js rule")]
46 | [Description("Nest JavaScript files ending in -vsdoc.js under corresponding .js files")]
47 | [Category("Nesting rules")]
48 | [DefaultValue(true)]
49 | public bool EnableVsDocRule { get; set; }
50 |
51 | [LocDisplayName("Enable interface implementation rule")]
52 | [Description("Nest C# interface implementations under their respective interfaces (by filename only)")]
53 | [Category("Nesting rules")]
54 | [DefaultValue(false)]
55 | public bool EnableInterfaceImplementationRule { get; set; }
56 | }
57 | }
--------------------------------------------------------------------------------
/src/Nesters/FileNestingFactory.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using EnvDTE;
5 | using EnvDTE80;
6 | using Microsoft.VisualStudio;
7 |
8 | namespace MadsKristensen.FileNesting
9 | {
10 | static class FileNestingFactory
11 | {
12 | private static List _nesters = new List()
13 | {
14 | new KnownFileTypeNester(),
15 | new VsDocNester(),
16 | new BundleNester(),
17 | new InterfaceImplementationNester(),
18 | new PathSegmentNester(),
19 | new SpriteNester(),
20 | new AddedExtensionNester(),
21 |
22 | };
23 |
24 | private static ProjectItemsEvents _events;
25 | public static bool Enabled { get; set; }
26 |
27 | public static void Enable(DTE2 dte)
28 | {
29 | if (_events == null)
30 | {
31 | _events = ((Events2)dte.Events).ProjectItemsEvents;
32 | _events.ItemAdded += ItemAdded;
33 | _events.ItemRenamed += ItemRenamed;
34 | }
35 | }
36 |
37 | private static void ItemRenamed(ProjectItem item, string OldName)
38 | {
39 | ItemAdded(item);
40 | }
41 |
42 | private static void ItemAdded(ProjectItem item)
43 | {
44 | // Node.js project system doesn't support 'item.Collection'
45 | if (item.ContainingProject.Kind.Equals("{9092aa53-fb77-4645-b42d-1ccca6bd08bd}", StringComparison.OrdinalIgnoreCase))
46 | return;
47 |
48 | if (FileNestingPackage.Options != null && FileNestingPackage.Options.EnableAutoNesting && item != null && item.Properties != null)
49 | {
50 | try
51 | {
52 |
53 | if (!(item.Collection.Parent is ProjectItem parent) || !parent.Kind.Equals(VSConstants.ItemTypeGuid.PhysicalFile_string, StringComparison.OrdinalIgnoreCase))
54 | {
55 | RunNesting(item);
56 | }
57 | }
58 | catch (Exception ex)
59 | {
60 | Logger.Log(ex);
61 | }
62 | }
63 | }
64 |
65 | public static void RunNesting(ProjectItem item)
66 | {
67 | if (!Enabled)
68 | return;
69 |
70 | foreach (var nester in _nesters.Where(n => n.IsEnabled()))
71 | {
72 | NestingResult result = nester.Nest(item.FileNames[0]);
73 |
74 | if (result == NestingResult.StopProcessing)
75 | break;
76 | }
77 | }
78 | }
79 | }
80 |
--------------------------------------------------------------------------------
/src/Nesters/Automated/InterfaceImplementationNester.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 | using System.IO;
3 | using System.Linq;
4 | using EnvDTE;
5 |
6 | namespace MadsKristensen.FileNesting
7 | {
8 | internal class InterfaceImplementationNester : IFileNester
9 | {
10 | public NestingResult Nest(string fileName)
11 | {
12 | if (!IsSupported(fileName))
13 | return NestingResult.Continue;
14 |
15 | IEnumerable possibleInterfaceNames = PossibleInterfaceNames(fileName);
16 |
17 | foreach (string interfaceName in possibleInterfaceNames)
18 | {
19 | string directory = Path.GetDirectoryName(fileName);
20 | string parentFileName = Path.Combine(directory, interfaceName);
21 |
22 | ProjectItem parent = FileNestingPackage.DTE.Solution.FindProjectItem(parentFileName);
23 | if (parent != null)
24 | {
25 | parent.ProjectItems.AddFromFile(fileName);
26 | return NestingResult.StopProcessing;
27 | }
28 | }
29 |
30 | return NestingResult.Continue;
31 | }
32 |
33 | private static IEnumerable PossibleInterfaceNames(string fileName)
34 | {
35 | string fileNameOnly = Path.GetFileNameWithoutExtension(fileName);
36 |
37 | List possibleNames = new List();
38 |
39 | for (int i = 0; i < fileNameOnly.Length; i++)
40 | {
41 | string letter = fileNameOnly.Substring(i, 1);
42 |
43 | if (letter == letter.ToUpperInvariant())
44 | {
45 | possibleNames.Add(fileNameOnly.Substring(i, fileNameOnly.Length - i));
46 | }
47 | }
48 |
49 | string extension = Path.GetExtension(fileName);
50 |
51 | return possibleNames.Select(n => "I" + n + extension);
52 | }
53 |
54 | private static bool IsSupported(string fileName)
55 | {
56 | return (IsAllowedFileType(fileName)) && (!IsInterface(fileName));
57 | }
58 |
59 | private static bool IsAllowedFileType(string fileName)
60 | {
61 | string extension = Path.GetExtension(fileName).ToLowerInvariant();
62 | string[] allowed = { ".cs" };
63 |
64 | return allowed.Contains(extension);
65 | }
66 |
67 | private static bool IsInterface(string fileName)
68 | {
69 | fileName = Path.GetFileName(fileName);
70 | bool firstLetterIsI = ('I' == fileName[0]);
71 |
72 | string secondLetter = fileName.Substring(1, 1);
73 | bool secondLetterPeriodOrLowercase = (("." == secondLetter) || (secondLetter == secondLetter.ToLowerInvariant()));
74 |
75 | return ((firstLetterIsI) && (!secondLetterPeriodOrLowercase));
76 | }
77 |
78 | public bool IsEnabled()
79 | {
80 | return FileNestingPackage.Options.EnableInterfaceImplementationRule;
81 | }
82 | }
83 | }
--------------------------------------------------------------------------------
/src/VSPackage.cs:
--------------------------------------------------------------------------------
1 | using EnvDTE;
2 | using EnvDTE80;
3 | using Microsoft.VisualStudio.Shell;
4 | using Microsoft.VisualStudio.Shell.Interop;
5 | using System;
6 | using System.ComponentModel.Design;
7 | using System.Linq;
8 | using System.Runtime.InteropServices;
9 | using System.Threading;
10 | using Task = System.Threading.Tasks.Task;
11 |
12 | namespace MadsKristensen.FileNesting
13 | {
14 | [PackageRegistration(UseManagedResourcesOnly = true, AllowsBackgroundLoading = true)]
15 | [InstalledProductRegistration("#110", "#112", Vsix.Version, IconResourceID = 400)]
16 | [ProvideMenuResource("Menus.ctmenu", 1)]
17 | [Guid(PackageGuids.guidFileNestingPkgString)]
18 | [ProvideAutoLoad(UIContextGuids80.SolutionHasSingleProject, PackageAutoLoadFlags.BackgroundLoad)]
19 | [ProvideAutoLoad(UIContextGuids80.SolutionHasMultipleProjects, PackageAutoLoadFlags.BackgroundLoad)]
20 | [ProvideOptionPage(typeof(NestingOptions), Vsix.Name, "General", 101, 100, true, new[] { "File Nesting in Solution Explorer" })]
21 | public sealed class FileNestingPackage : AsyncPackage
22 | {
23 | public static DTE2 DTE { get; private set; }
24 | public static NestingOptions Options { get; private set; }
25 |
26 | protected override async Task InitializeAsync(CancellationToken cancellationToken, IProgress progress)
27 | {
28 | DTE = await GetServiceAsync(typeof(DTE)) as DTE2;
29 | FileNestingFactory.Enable(DTE);
30 |
31 | await JoinableTaskFactory.SwitchToMainThreadAsync();
32 | await Logger.Initialize(this, Vsix.Name);
33 |
34 | if (GetService(typeof(IMenuCommandService)) is OleMenuCommandService mcs)
35 | {
36 | CommandID commandId = new CommandID(PackageGuids.guidFileNestingCmdSet, PackageIds.NestingMenu);
37 | OleMenuCommand menuCommand = new OleMenuCommand((s, e) => { }, commandId);
38 | menuCommand.BeforeQueryStatus += ShowMenu;
39 | mcs.AddCommand(menuCommand);
40 |
41 | UnNestButton.Register(mcs);
42 | NestButton.Register(mcs);
43 | EnableAutoNestButton.Register(DTE, mcs);
44 | RunAutoNestingButton.Register(DTE, mcs);
45 | }
46 |
47 | Options = (NestingOptions)GetDialogPage(typeof(NestingOptions));
48 | FileNestingFactory.Enabled = true;
49 | }
50 |
51 | private void ShowMenu(object sender, EventArgs e)
52 | {
53 | OleMenuCommand menu = (OleMenuCommand)sender;
54 | ProjectItem item = Helpers.GetSelectedItems().FirstOrDefault();
55 |
56 | // We need to exclude website projects, since they don't support file nesting
57 | menu.Visible = item != null &&
58 | !(item.ContainingProject.Kind.Equals("{E24C65DC-7377-472B-9ABA-BC803B73C61A}", StringComparison.OrdinalIgnoreCase)) &&
59 | !item.ContainingProject.Kind.Equals("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}", StringComparison.OrdinalIgnoreCase); // ASP.NET 5
60 | }
61 | }
62 | }
--------------------------------------------------------------------------------
/src/website.pkgdef:
--------------------------------------------------------------------------------
1 | // JavaScript
2 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.js]
3 | "RelationType"=dword:00000001
4 |
5 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.js\.intellisense.js]
6 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.js\.debug.js]
7 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.js\.js.map]
8 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.js\.min.js]
9 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.js\.min.js.map]
10 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.js\.js.gz]
11 |
12 | // Web.config
13 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.config]
14 | "RelationType"=dword:00000001
15 |
16 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.config\.release.config]
17 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.config\.debug.config]
18 |
19 | // Minified CSS files
20 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.css]
21 | "RelationType"=dword:00000001
22 |
23 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.css\.min.css]
24 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.css\.css.map]
25 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.css\.css.gz]
26 |
27 | // Minified HTML files
28 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.html]
29 | "RelationType"=dword:00000001
30 |
31 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.html\.min.html]
32 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.html\.html.gz]
33 |
34 | // CoffeeScript
35 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.coffee]
36 | "RelationType"=dword:00000001
37 |
38 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.coffee\.js]
39 |
40 | // Iced CoffeeScript
41 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.iced]
42 | "RelationType"=dword:00000001
43 |
44 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.iced\.js]
45 |
46 | // JSX
47 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.jsx]
48 | "RelationType"=dword:00000001
49 |
50 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.jsx\.js]
51 |
52 | // LESS
53 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.less]
54 | "RelationType"=dword:00000001
55 |
56 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.less\.css]
57 |
58 | // Sass
59 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.scss]
60 | "RelationType"=dword:00000001
61 |
62 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.scss\.css]
63 |
64 | // Sweet.js
65 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.sjs]
66 | "RelationType"=dword:00000001
67 |
68 | [$RootKey$\Projects\{E24C65DC-7377-472b-9ABA-BC803B73C61A}\RelatedFiles\.sjs\.js]
--------------------------------------------------------------------------------
/src/Helpers/Helpers.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.IO;
4 | using EnvDTE;
5 | using Microsoft.VisualStudio;
6 |
7 | namespace MadsKristensen.FileNesting
8 | {
9 | static class Helpers
10 | {
11 | public static IEnumerable GetSelectedItems()
12 | {
13 | var items = (Array)FileNestingPackage.DTE.ToolWindows.SolutionExplorer.SelectedItems;
14 | foreach (UIHierarchyItem selItem in items)
15 | {
16 | var project = selItem.Object as Project;
17 | if (project != null)
18 | {
19 | foreach (ProjectItem item in project.ProjectItems)
20 | yield return item;
21 | }
22 | else
23 | {
24 | var item = selItem.Object as ProjectItem;
25 | if (item != null)
26 | {
27 | yield return item;
28 | }
29 | }
30 | }
31 | }
32 |
33 | public static IEnumerable GetSelectedItemsRecursive()
34 | {
35 | foreach (ProjectItem item in GetSelectedItems())
36 | {
37 | Guid kind;
38 |
39 | if (!Guid.TryParse(item.Kind, out kind))
40 | continue;
41 |
42 | if (kind == VSConstants.ItemTypeGuid.PhysicalFolder_guid)
43 | {
44 | var files = Directory.EnumerateFiles(item.FileNames[0], "*", SearchOption.AllDirectories);
45 | foreach (string file in files)
46 | {
47 | ProjectItem child = FileNestingPackage.DTE.Solution.FindProjectItem(file);
48 |
49 | if (child != null)
50 | yield return child;
51 | }
52 | }
53 | else
54 | {
55 | yield return item;
56 | }
57 | }
58 | }
59 |
60 | public static bool ContainsProperty(this ProjectItem projectItem, string propertyName)
61 | {
62 | if (projectItem.Properties != null)
63 | {
64 | foreach (Property item in projectItem.Properties)
65 | {
66 | if (item != null && item.Name == propertyName)
67 | {
68 | return true;
69 | }
70 | }
71 | }
72 |
73 | return false;
74 | }
75 |
76 | public static bool IsKind(this Project project, params string[] kindGuids)
77 | {
78 | foreach (var guid in kindGuids)
79 | {
80 | if (project.Kind.Equals(guid, StringComparison.OrdinalIgnoreCase))
81 | return true;
82 | }
83 |
84 | return false;
85 | }
86 | }
87 |
88 | public static class ProjectTypes
89 | {
90 | public const string ASPNET_5 = "{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}";
91 | public const string DOTNET_Core = "{9A19103F-16F7-4668-BE54-9A1E7A4F7556}";
92 | public const string WEBSITE_PROJECT = "{E24C65DC-7377-472B-9ABA-BC803B73C61A}";
93 | public const string UNIVERSAL_APP = "{262852C6-CD72-467D-83FE-5EEB1973A190}";
94 | public const string NODE_JS = "{9092AA53-FB77-4645-B42D-1CCCA6BD08BD}";
95 | public const string SSDT = "{00d1a9c2-b5f0-4af3-8072-f6c62b433612}";
96 | public const string SHARED_PROJECT = "{D954291E-2A0B-460D-934E-DC6B0785DB48}";
97 | public const string NETSTANDARD = "{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}";
98 | }
99 | }
100 |
--------------------------------------------------------------------------------
/src/Dialogs/ItemSelector.xaml.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 | using System.Linq;
3 | using System.Windows;
4 | using Microsoft.VisualStudio;
5 |
6 | namespace MadsKristensen.FileNesting
7 | {
8 | public partial class ItemSelector : Window
9 | {
10 | public string SelectedFile { get; private set; }
11 | private IDictionary _files;
12 |
13 | public ItemSelector(IEnumerable items)
14 | {
15 | InitializeComponent();
16 |
17 | ddlFiles.Focus();
18 |
19 | EnvDTE.ProjectItem currentItem = items.ElementAt(0);
20 |
21 | var siblings = ItemSelector.GetSiblings(currentItem);
22 | _files = this.GetSource(siblings, items, new Dictionary(), string.Empty);
23 | ddlFiles.ItemsSource = _files.Keys;
24 | var index = GetMatchParentIndex(currentItem.Name, _files.Keys.ToArray());
25 | ddlFiles.SelectedIndex = index;
26 | }
27 |
28 | private int GetMatchParentIndex(string currentFileName, string[] allFiles)
29 | {
30 | int maxFileIndex = 0;
31 | int maxFileEqualCharCount = 0;
32 |
33 | for (int i = 0; i < allFiles.Length; i++)
34 | {
35 | var fileNameInList = allFiles[i];
36 | var count = GetEqualCharCount(currentFileName , fileNameInList);
37 | if (count <= maxFileEqualCharCount) continue;
38 | maxFileEqualCharCount = count;
39 | maxFileIndex = i;
40 | }
41 | return maxFileIndex;
42 | }
43 |
44 | private int GetEqualCharCount(string currentFileName, string fileNameInList)
45 | {
46 | return fileNameInList.TakeWhile((t, i) => i < currentFileName.Length).TakeWhile((t, i) => currentFileName[i] == t).Count();
47 | }
48 |
49 | private IDictionary GetSource(IEnumerable parents, IEnumerable selected, Dictionary paths, string indentation)
50 | {
51 | foreach (EnvDTE.ProjectItem item in parents)
52 | {
53 | if (!selected.Contains(item))
54 | {
55 | string path = indentation + item.Name;
56 |
57 | if (!paths.ContainsKey(path))
58 | paths.Add(path, item.FileNames[0]);
59 | }
60 |
61 | GetSource(item.ProjectItems.Cast(), selected, paths, indentation + " ");
62 | }
63 |
64 | return paths;
65 | }
66 |
67 | private static IEnumerable GetSiblings(EnvDTE.ProjectItem item)
68 | {
69 | EnvDTE.ProjectItem folder = item.Collection.Parent as EnvDTE.ProjectItem;
70 | List items = new List();
71 |
72 | while (folder != null)
73 | {
74 | if (!folder.Kind.Equals(VSConstants.ItemTypeGuid.PhysicalFolder_string, System.StringComparison.OrdinalIgnoreCase))
75 | {
76 | folder = folder.Collection.Parent as EnvDTE.ProjectItem;
77 | }
78 | else
79 | {
80 | break;
81 | }
82 | }
83 |
84 | if (folder != null)
85 | {
86 | items.AddRange(folder.ProjectItems.Cast());
87 | }
88 | else if (item.ContainingProject != null && item.ContainingProject.ProjectItems != null)
89 | {
90 | items.AddRange(item.ContainingProject.ProjectItems.Cast());
91 | }
92 |
93 | return items.Where(i => i.Kind.Equals(VSConstants.ItemTypeGuid.PhysicalFile_string, System.StringComparison.OrdinalIgnoreCase));
94 | }
95 |
96 | private void ok_Click(object sender, RoutedEventArgs e)
97 | {
98 | SelectedFile = _files[ddlFiles.SelectedItem.ToString()];
99 | DialogResult = true;
100 | this.Close();
101 | }
102 | }
103 | }
104 |
--------------------------------------------------------------------------------
/src/VSCommandTable.vsct:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
16 |
17 |
18 |
19 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
36 |
37 |
45 |
46 |
53 |
54 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
--------------------------------------------------------------------------------
/src/Nesters/ManualNester.cs:
--------------------------------------------------------------------------------
1 | using System.Collections.Generic;
2 | using System.IO;
3 | using EnvDTE;
4 |
5 | namespace MadsKristensen.FileNesting
6 | {
7 | static class ManualNester
8 | {
9 | private const string CordovaKind = "{262852C6-CD72-467D-83FE-5EEB1973A190}";
10 | public static void Nest(IEnumerable items)
11 | {
12 | ItemSelector selector = new ItemSelector(items);
13 |
14 | if (!selector.ShowDialog().Value)
15 | {
16 | return;
17 | }
18 |
19 | foreach (ProjectItem item in items)
20 | {
21 | string path = item.FileNames[0];
22 | ProjectItem parent = item.DTE.Solution.FindProjectItem(selector.SelectedFile);
23 | if (parent == null) continue;
24 |
25 | bool mayNeedAttributeSet = item.ContainingProject.IsKind(
26 | ProjectTypes.DOTNET_Core,
27 | ProjectTypes.UNIVERSAL_APP,
28 | ProjectTypes.SHARED_PROJECT,
29 | ProjectTypes.NETSTANDARD);
30 |
31 | if (!(mayNeedAttributeSet && SetDependentUpon(item, parent.Name)))
32 | {
33 | item.Remove();
34 | parent.ProjectItems.AddFromFile(path);
35 | }
36 | }
37 | }
38 |
39 | public static void UnNest(ProjectItem item)
40 | {
41 | foreach (ProjectItem child in item.ProjectItems)
42 | {
43 | UnNest(child);
44 | }
45 |
46 | UnNestItem(item);
47 | }
48 |
49 | private static void UnNestItem(ProjectItem item)
50 | {
51 | string path = item.FileNames[0];
52 | object parent = item.Collection.Parent;
53 |
54 | bool shouldAddToParentItem = item.ContainingProject.Kind == CordovaKind;
55 |
56 | while (parent != null)
57 | {
58 | var pi = parent as ProjectItem;
59 |
60 | if (pi != null)
61 | {
62 | if (!Path.HasExtension(pi.FileNames[0]))
63 | {
64 | object itemType = item.Properties.Item("ItemType").Value;
65 |
66 | DeleteAndAdd(item, path);
67 |
68 | ProjectItem newItem;
69 | if (shouldAddToParentItem)
70 | {
71 | newItem = pi.ProjectItems.AddFromFile(path);
72 | }
73 | else
74 | {
75 | newItem = pi.ContainingProject.ProjectItems.AddFromFile(path);
76 | }
77 | newItem.Properties.Item("ItemType").Value = itemType;
78 | break;
79 | }
80 |
81 | parent = pi.Collection.Parent;
82 | }
83 | else
84 | {
85 | var pj = parent as Project;
86 | if (pj != null)
87 | {
88 | object itemType = item.Properties.Item("ItemType").Value;
89 |
90 | DeleteAndAdd(item, path);
91 |
92 | ProjectItem newItem = pj.ProjectItems.AddFromFile(path);
93 | newItem.Properties.Item("ItemType").Value = itemType;
94 | break;
95 | }
96 | }
97 | }
98 | }
99 |
100 | private static void DeleteAndAdd(ProjectItem item, string path)
101 | {
102 | if (!File.Exists(path))
103 | return;
104 |
105 | string temp = Path.GetTempFileName();
106 | File.Copy(path, temp, true);
107 | item.Delete();
108 | File.Copy(temp, path);
109 | File.Delete(temp);
110 | }
111 |
112 | private static void RemoveDependentUpon(ProjectItem item)
113 | {
114 | SetDependentUpon(item, null);
115 | }
116 |
117 | private static bool SetDependentUpon(ProjectItem item, string value)
118 | {
119 | if (item.ContainsProperty("DependentUpon"))
120 | {
121 | item.Properties.Item("DependentUpon").Value = value;
122 | return true;
123 | }
124 |
125 | return false;
126 | }
127 | }
128 | }
129 |
--------------------------------------------------------------------------------
/.github/CONTRIBUTING.md:
--------------------------------------------------------------------------------
1 | # Contributing
2 |
3 | Looking to contribute something? **Here's how you can help.**
4 |
5 | Please take a moment to review this document in order to make the contribution
6 | process easy and effective for everyone involved.
7 |
8 | Following these guidelines helps to communicate that you respect the time of
9 | the developers managing and developing this open source project. In return,
10 | they should reciprocate that respect in addressing your issue or assessing
11 | patches and features.
12 |
13 |
14 | ## Using the issue tracker
15 |
16 | The issue tracker is the preferred channel for [bug reports](#bug-reports),
17 | [features requests](#feature-requests) and
18 | [submitting pull requests](#pull-requests), but please respect the
19 | following restrictions:
20 |
21 | * Please **do not** use the issue tracker for personal support requests. Stack
22 | Overflow is a better place to get help.
23 |
24 | * Please **do not** derail or troll issues. Keep the discussion on topic and
25 | respect the opinions of others.
26 |
27 | * Please **do not** open issues or pull requests which *belongs to* third party
28 | components.
29 |
30 |
31 | ## Bug reports
32 |
33 | A bug is a _demonstrable problem_ that is caused by the code in the repository.
34 | Good bug reports are extremely helpful, so thanks!
35 |
36 | Guidelines for bug reports:
37 |
38 | 1. **Use the GitHub issue search** — check if the issue has already been
39 | reported.
40 |
41 | 2. **Check if the issue has been fixed** — try to reproduce it using the
42 | latest `master` or development branch in the repository.
43 |
44 | 3. **Isolate the problem** — ideally create an
45 | [SSCCE](http://www.sscce.org/) and a live example.
46 | Uploading the project on cloud storage (OneDrive, DropBox, et el.)
47 | or creating a sample GitHub repository is also helpful.
48 |
49 |
50 | A good bug report shouldn't leave others needing to chase you up for more
51 | information. Please try to be as detailed as possible in your report. What is
52 | your environment? What steps will reproduce the issue? What browser(s) and OS
53 | experience the problem? Do other browsers show the bug differently? What
54 | would you expect to be the outcome? All these details will help people to fix
55 | any potential bugs.
56 |
57 | Example:
58 |
59 | > Short and descriptive example bug report title
60 | >
61 | > A summary of the issue and the Visual Studio, browser, OS environments
62 | > in which it occurs. If suitable, include the steps required to reproduce the bug.
63 | >
64 | > 1. This is the first step
65 | > 2. This is the second step
66 | > 3. Further steps, etc.
67 | >
68 | > `` - a link to the project/file uploaded on cloud storage or other publicly accessible medium.
69 | >
70 | > Any other information you want to share that is relevant to the issue being
71 | > reported. This might include the lines of code that you have identified as
72 | > causing the bug, and potential solutions (and your opinions on their
73 | > merits).
74 |
75 |
76 | ## Feature requests
77 |
78 | Feature requests are welcome. But take a moment to find out whether your idea
79 | fits with the scope and aims of the project. It's up to *you* to make a strong
80 | case to convince the project's developers of the merits of this feature. Please
81 | provide as much detail and context as possible.
82 |
83 |
84 | ## Pull requests
85 |
86 | Good pull requests, patches, improvements and new features are a fantastic
87 | help. They should remain focused in scope and avoid containing unrelated
88 | commits.
89 |
90 | **Please ask first** before embarking on any significant pull request (e.g.
91 | implementing features, refactoring code, porting to a different language),
92 | otherwise you risk spending a lot of time working on something that the
93 | project's developers might not want to merge into the project.
94 |
95 | Please adhere to the [coding guidelines](#code-guidelines) used throughout the
96 | project (indentation, accurate comments, etc.) and any other requirements
97 | (such as test coverage).
98 |
99 | Adhering to the following process is the best way to get your work
100 | included in the project:
101 |
102 | 1. [Fork](http://help.github.com/fork-a-repo/) the project, clone your fork,
103 | and configure the remotes:
104 |
105 | ```bash
106 | # Clone your fork of the repo into the current directory
107 | git clone https://github.com//.git
108 | # Navigate to the newly cloned directory
109 | cd
110 | # Assign the original repo to a remote called "upstream"
111 | git remote add upstream https://github.com/madskristensen/.git
112 | ```
113 |
114 | 2. If you cloned a while ago, get the latest changes from upstream:
115 |
116 | ```bash
117 | git checkout master
118 | git pull upstream master
119 | ```
120 |
121 | 3. Create a new topic branch (off the main project development branch) to
122 | contain your feature, change, or fix:
123 |
124 | ```bash
125 | git checkout -b
126 | ```
127 |
128 | 4. Commit your changes in logical chunks. Please adhere to these [git commit
129 | message guidelines](http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html)
130 | or your code is unlikely be merged into the main project. Use Git's
131 | [interactive rebase](https://help.github.com/articles/interactive-rebase)
132 | feature to tidy up your commits before making them public. Also, prepend name of the feature
133 | to the commit message. For instance: "SCSS: Fixes compiler results for IFileListener.\nFixes `#123`"
134 |
135 | 5. Locally merge (or rebase) the upstream development branch into your topic branch:
136 |
137 | ```bash
138 | git pull [--rebase] upstream master
139 | ```
140 |
141 | 6. Push your topic branch up to your fork:
142 |
143 | ```bash
144 | git push origin
145 | ```
146 |
147 | 7. [Open a Pull Request](https://help.github.com/articles/using-pull-requests/)
148 | with a clear title and description against the `master` branch.
149 |
150 |
151 | ## Code guidelines
152 |
153 | - Always use proper indentation.
154 | - In Visual Studio under `Tools > Options > Text Editor > C# > Advanced`, make sure
155 | `Place 'System' directives first when sorting usings` option is enabled (checked).
156 | - Before committing, organize usings for each updated C# source file. Either you can
157 | right-click editor and select `Organize Usings > Remove and sort` OR use extension
158 | like [BatchFormat](http://visualstudiogallery.msdn.microsoft.com/a7f75c34-82b4-4357-9c66-c18e32b9393e).
159 | - Before committing, run Code Analysis in `Debug` configuration and follow the guidelines
160 | to fix CA issues. Code Analysis commits can be made separately.
161 |
--------------------------------------------------------------------------------
/src/source.extension.resx:
--------------------------------------------------------------------------------
1 |
2 |
3 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 | text/microsoft-resx
110 |
111 |
112 | 2.0
113 |
114 |
115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
116 |
117 |
118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
119 |
120 |
121 | File Nesting
122 |
123 |
124 | Automatically nest files based on file name and enables developers to nest and unnest any file manually
125 |
126 |
127 |
128 | source.extension.ico;System.Drawing.Icon, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a
129 |
130 |
--------------------------------------------------------------------------------
/src/FileNesting.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | $(VisualStudioVersion)
5 | $(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)
6 | Program
7 | $(DevEnvDir)\devenv.exe
8 | /rootsuffix Exp
9 | true
10 |
11 |
12 |
13 |
14 |
15 |
16 | Debug
17 | AnyCPU
18 | 2.0
19 | {25F9FD9B-5EB2-4B27-93FB-05955B7D115F}
20 | {82b43b9b-a64c-4715-b499-d71e9ca2bd60};{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}
21 | Library
22 | Properties
23 | MadsKristensen.FileNesting
24 | FileNesting
25 | True
26 |
27 |
28 | v4.8
29 |
30 |
31 | true
32 | full
33 | false
34 | bin\Debug\
35 | DEBUG;TRACE
36 | prompt
37 | 4
38 |
39 |
40 | pdbonly
41 | true
42 | bin\Release\
43 | TRACE
44 | prompt
45 | 4
46 | false
47 | AllRules.ruleset
48 |
49 |
50 |
51 |
52 | ..\packages\Microsoft.VisualStudio.CoreUtility.14.0.23205\lib\net45\Microsoft.VisualStudio.CoreUtility.dll
53 |
54 |
55 | ..\packages\Microsoft.VisualStudio.ImageCatalog.14.0.23205\lib\net45\Microsoft.VisualStudio.ImageCatalog.dll
56 |
57 |
58 | ..\packages\Microsoft.VisualStudio.Imaging.14.0.23205\lib\net45\Microsoft.VisualStudio.Imaging.dll
59 |
60 |
61 | ..\packages\Microsoft.VisualStudio.OLE.Interop.7.10.6071\lib\Microsoft.VisualStudio.OLE.Interop.dll
62 | True
63 |
64 |
65 | ..\packages\Microsoft.VisualStudio.Shell.14.0.14.0.23205\lib\Microsoft.VisualStudio.Shell.14.0.dll
66 | True
67 |
68 |
69 | ..\packages\Microsoft.VisualStudio.Shell.Immutable.10.0.10.0.30319\lib\net40\Microsoft.VisualStudio.Shell.Immutable.10.0.dll
70 |
71 |
72 | ..\packages\Microsoft.VisualStudio.Shell.Immutable.11.0.11.0.50727\lib\net45\Microsoft.VisualStudio.Shell.Immutable.11.0.dll
73 |
74 |
75 | ..\packages\Microsoft.VisualStudio.Shell.Immutable.12.0.12.0.21003\lib\net45\Microsoft.VisualStudio.Shell.Immutable.12.0.dll
76 |
77 |
78 | ..\packages\Microsoft.VisualStudio.Shell.Immutable.14.0.14.0.23205\lib\net45\Microsoft.VisualStudio.Shell.Immutable.14.0.dll
79 |
80 |
81 | ..\packages\Microsoft.VisualStudio.Shell.Interop.7.10.6072\lib\net11\Microsoft.VisualStudio.Shell.Interop.dll
82 | True
83 |
84 |
85 | True
86 | ..\packages\Microsoft.VisualStudio.Shell.Interop.10.0.10.0.30320\lib\net20\Microsoft.VisualStudio.Shell.Interop.10.0.dll
87 | True
88 |
89 |
90 | True
91 | ..\packages\Microsoft.VisualStudio.Shell.Interop.11.0.11.0.61031\lib\net20\Microsoft.VisualStudio.Shell.Interop.11.0.dll
92 | True
93 |
94 |
95 | True
96 | ..\packages\Microsoft.VisualStudio.Shell.Interop.12.0.12.0.30111\lib\net20\Microsoft.VisualStudio.Shell.Interop.12.0.dll
97 | True
98 |
99 |
100 | ..\packages\Microsoft.VisualStudio.Shell.Interop.8.0.8.0.50728\lib\net11\Microsoft.VisualStudio.Shell.Interop.8.0.dll
101 | True
102 |
103 |
104 | ..\packages\Microsoft.VisualStudio.Shell.Interop.9.0.9.0.30730\lib\net11\Microsoft.VisualStudio.Shell.Interop.9.0.dll
105 | True
106 |
107 |
108 | ..\packages\Microsoft.VisualStudio.TextManager.Interop.7.10.6071\lib\net11\Microsoft.VisualStudio.TextManager.Interop.dll
109 | True
110 |
111 |
112 | ..\packages\Microsoft.VisualStudio.TextManager.Interop.8.0.8.0.50728\lib\net11\Microsoft.VisualStudio.TextManager.Interop.8.0.dll
113 | True
114 |
115 |
116 | ..\packages\Microsoft.VisualStudio.Threading.14.0.51107\lib\net45\Microsoft.VisualStudio.Threading.dll
117 |
118 |
119 | ..\packages\Microsoft.VisualStudio.Utilities.14.0.23205\lib\net45\Microsoft.VisualStudio.Utilities.dll
120 |
121 |
122 | ..\packages\Microsoft.VisualStudio.Validation.14.0.51103\lib\net45\Microsoft.VisualStudio.Validation.dll
123 |
124 |
125 |
126 |
127 | True
128 | ..\packages\stdole.7.0.3302\lib\net10\stdole.dll
129 | True
130 |
131 |
132 |
133 |
134 |
135 |
136 |
137 |
138 |
139 |
140 |
141 |
142 |
143 |
144 |
145 | ItemSelector.xaml
146 |
147 |
148 |
149 | True
150 | True
151 | VSCommandTable.vsct
152 |
153 |
154 |
155 |
156 |
157 |
158 |
159 |
160 |
161 |
162 |
163 |
164 |
165 | Component
166 |
167 |
168 |
169 |
170 |
171 |
172 |
173 |
174 | source.extension.vsixmanifest
175 |
176 |
177 |
178 |
179 | Resources\LICENSE
180 | true
181 |
182 |
183 | true
184 |
185 |
186 | source.extension.vsixmanifest
187 |
188 |
189 | Designer
190 | VsixManifestGenerator
191 | source.extension.resx
192 |
193 |
194 |
195 |
196 | Menus.ctmenu
197 | Designer
198 | VsctGenerator
199 | VSCommandTable.cs
200 |
201 |
202 |
203 |
204 |
205 |
206 |
207 | true
208 |
209 |
210 | true
211 |
212 |
213 |
214 |
215 | Designer
216 | MSBuild:Compile
217 |
218 |
219 |
220 |
221 | True
222 | True
223 | source.extension.vsixmanifest
224 | true
225 | VSPackage
226 |
227 |
228 |
229 |
230 | 17.1.32210.191
231 |
232 |
233 | 17.1.4057
234 | runtime; build; native; contentfiles; analyzers; buildtransitive
235 | all
236 |
237 |
238 |
239 | true
240 |
241 |
242 |
243 |
250 |
--------------------------------------------------------------------------------