Skip to content

Commit

Permalink
Merge branch 'release/0.4.0'
Browse files Browse the repository at this point in the history
* release/0.4.0:
  (build) Update path to manifest(s)
  (#128) Make URL's absolute
  (doc) Update description for supported VS Versions
  (#133) fixed build
  (maint) cleanup
  (#133) re-enabled file-icon
  (#133) re-enabled Cake snippets
  (#133) re-enabled CSharp snippets
  (#133) enabled Build -> Cake Build menu
  (#133) Upgrade to support Visual Studio 2022
  (GH-123) Add publishing manifest file
  • Loading branch information
gep13 committed Aug 23, 2021
2 parents d0176b3 + 51805b6 commit b50715f
Show file tree
Hide file tree
Showing 82 changed files with 953 additions and 388 deletions.
32 changes: 21 additions & 11 deletions Cake.VisualStudio.sln
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 15
VisualStudioVersion = 15.0.26127.3
# Visual Studio Version 16
VisualStudioVersion = 16.0.31515.178
MinimumVisualStudioVersion = 10.0.40219.1
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{04D0CE67-A915-44BB-BC3C-8E7885CF9E97}"
ProjectSection(SolutionItems) = preProject
Expand All @@ -11,11 +11,6 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Templates", "Templates", "{7067556F-B744-4F73-B509-C8CC9F559AB9}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Cake.VisualStudio", "src\Cake.VisualStudio.csproj", "{94660BCF-169A-42E1-BD84-345449743069}"
ProjectSection(ProjectDependencies) = postProject
{FCE573DD-E74E-4AB1-9D17-56FC8869797F} = {FCE573DD-E74E-4AB1-9D17-56FC8869797F}
EndProjectSection
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AddinTemplate", "template\AddinTemplate\AddinTemplate.csproj", "{FCE573DD-E74E-4AB1-9D17-56FC8869797F}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ModuleTemplate", "template\ModuleTemplate\ModuleTemplate.csproj", "{85BCBED7-39BD-4670-85F7-EE36D0DA31C0}"
Expand All @@ -28,16 +23,23 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AddinTestBasicTemplate", "t
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SolutionItemTemplate", "template\SolutionItemTemplate\SolutionItemTemplate.csproj", "{5D45E667-D12D-44F8-8A87-5503BF5DE274}"
EndProject
Project("{D954291E-2A0B-460D-934E-DC6B0785DB48}") = "Cake.VisualStudio.Shared", "src\Cake.VisualStudio.Shared\Cake.VisualStudio.Shared.shproj", "{3D9AB2DB-3DD8-4E2B-8DBC-BF29EDAF1A1B}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Cake.VisualStudio", "src\Cake.VisualStudio\Cake.VisualStudio.csproj", "{94660BCF-169A-42E1-BD84-345449743069}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Cake.VisualStudio.2022", "src\Cake.VisualStudio.2022\Cake.VisualStudio.2022.csproj", "{F8EB885A-FCA3-410A-B895-9CE327D5D482}"
EndProject
Global
GlobalSection(SharedMSBuildProjectFiles) = preSolution
src\Cake.VisualStudio.Shared\Cake.VisualStudio.Shared.projitems*{3d9ab2db-3dd8-4e2b-8dbc-bf29edaf1a1b}*SharedItemsImports = 13
src\Cake.VisualStudio.Shared\Cake.VisualStudio.Shared.projitems*{94660bcf-169a-42e1-bd84-345449743069}*SharedItemsImports = 4
src\Cake.VisualStudio.Shared\Cake.VisualStudio.Shared.projitems*{f8eb885a-fca3-410a-b895-9ce327d5d482}*SharedItemsImports = 4
EndGlobalSection
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{94660BCF-169A-42E1-BD84-345449743069}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{94660BCF-169A-42E1-BD84-345449743069}.Debug|Any CPU.Build.0 = Debug|Any CPU
{94660BCF-169A-42E1-BD84-345449743069}.Release|Any CPU.ActiveCfg = Release|Any CPU
{94660BCF-169A-42E1-BD84-345449743069}.Release|Any CPU.Build.0 = Release|Any CPU
{FCE573DD-E74E-4AB1-9D17-56FC8869797F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{FCE573DD-E74E-4AB1-9D17-56FC8869797F}.Debug|Any CPU.Build.0 = Debug|Any CPU
{FCE573DD-E74E-4AB1-9D17-56FC8869797F}.Release|Any CPU.ActiveCfg = Release|Any CPU
Expand All @@ -62,6 +64,14 @@ Global
{5D45E667-D12D-44F8-8A87-5503BF5DE274}.Debug|Any CPU.Build.0 = Debug|Any CPU
{5D45E667-D12D-44F8-8A87-5503BF5DE274}.Release|Any CPU.ActiveCfg = Release|Any CPU
{5D45E667-D12D-44F8-8A87-5503BF5DE274}.Release|Any CPU.Build.0 = Release|Any CPU
{94660BCF-169A-42E1-BD84-345449743069}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{94660BCF-169A-42E1-BD84-345449743069}.Debug|Any CPU.Build.0 = Debug|Any CPU
{94660BCF-169A-42E1-BD84-345449743069}.Release|Any CPU.ActiveCfg = Release|Any CPU
{94660BCF-169A-42E1-BD84-345449743069}.Release|Any CPU.Build.0 = Release|Any CPU
{F8EB885A-FCA3-410A-B895-9CE327D5D482}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{F8EB885A-FCA3-410A-B895-9CE327D5D482}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F8EB885A-FCA3-410A-B895-9CE327D5D482}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F8EB885A-FCA3-410A-B895-9CE327D5D482}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Cake for Visual Studio

Adds support for the [Cake](https://cakebuild.net/)
build tool in Visual Studio 2017 and 2019. Includes support for the Task Runner Explorer,
build tool in Visual Studio 2017, 2019, and 2022. Includes support for the Task Runner Explorer,
new item and project templates and bootstrapping important Cake files

Originally based off Mads Kristensen's [Brunch Task Runner](https://github.com/madskristensen/BrunchTaskRunner) extension.
Expand All @@ -28,22 +28,22 @@ a `build.cake` file.
Open Task Runner Explorer by right-clicking the Cake script and select **Task Runner Explorer** from
the context menu:

![Open Task Runner Explorer](art/open-trx.png)
![Open Task Runner Explorer](https://cdn.jsdelivr.net/gh/cake-build/cake-vs@340ef57f9bfadc30641c0a2572e46fd35375ee89/art/open-trx.png)

Individual tasks will be listed in the task list on the left.

![Task List](art/task-list.png)
![Task List](https://cdn.jsdelivr.net/gh/cake-build/cake-vs@340ef57f9bfadc30641c0a2572e46fd35375ee89/art/task-list.png)

Each task can be executed by double-clicking the task.

![Console output](art/console.png)
![Console output](https://cdn.jsdelivr.net/gh/cake-build/cake-vs@340ef57f9bfadc30641c0a2572e46fd35375ee89/art/console.png)

### Bindings

Task bindings make it possible to associate individual tasks
with Visual Studio events such as _Project Open_ etc.

![Bindings](art/bindings.png)
![Bindings](https://cdn.jsdelivr.net/gh/cake-build/cake-vs@340ef57f9bfadc30641c0a2572e46fd35375ee89/art/bindings.png)

These bindings are stored in your `cake.config` file.

Expand All @@ -57,13 +57,13 @@ However, at this time, it will not automatically download Cake for you.

Choose Cake Build from the Build menu to quickly install the default bootstrapper scripts or Cake configuration files into your solution.

![Template installers](art/installers.png)
![Template installers](https://cdn.jsdelivr.net/gh/cake-build/cake-vs@340ef57f9bfadc30641c0a2572e46fd35375ee89/art/installers.png)

## Templates

The extension includes an item template for build scripts and project templates for Cake modules, addins, and unit tests.

![Project Template](art/templates.png)
![Project Template](https://cdn.jsdelivr.net/gh/cake-build/cake-vs@340ef57f9bfadc30641c0a2572e46fd35375ee89/art/templates.png)

## Contribute

Expand Down
28 changes: 19 additions & 9 deletions build.cake
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,12 @@ Task("Update-Manifest-Version")
{
BuildVersion.UpdateManifestVersion(
context: Context,
path: "./src/source.extension.vsixmanifest"
path: "./src/Cake.VisualStudio/source.extension.vsixmanifest"
);
BuildVersion.UpdateManifestVersion(
context: Context,
path: "./src/Cake.VisualStudio.2022/source.extension.vsixmanifest"
);
});
Expand Down Expand Up @@ -171,17 +176,20 @@ Task("Post-Build")
.IsDependentOn("Build")
.Does(() =>
{
CopyFileToDirectory("./src/bin/" + configuration + "/Cake.VisualStudio.vsix", artifacts);
CopyFile("./src/Cake.VisualStudio/bin/" + configuration + "/Cake.VisualStudio.vsix", artifacts + "/Cake.VisualStudio.2019.vsix");
CopyFile("./src/Cake.VisualStudio.2022/bin/" + configuration + "/Cake.VisualStudio.vsix", artifacts + "/Cake.VisualStudio.2022.vsix");
});
Task("Publish-GitHub-Release")
.WithCriteria(() => parameters.ShouldPublish)
.Does(() =>
{
var buildResultDir = Directory(artifacts);
var packageFile = File("Cake.VisualStudio.vsix");
var packageFile2019 = File("Cake.VisualStudio.2019.vsix");
var packageFile2022 = File("Cake.VisualStudio.2022.vsix");
GitReleaseManagerAddAssets(parameters.GitHub.Token, "cake-build", "cake-vs", parameters.Version.Milestone, buildResultDir + packageFile);
GitReleaseManagerAddAssets(parameters.GitHub.Token, "cake-build", "cake-vs", parameters.Version.Milestone, buildResultDir + packageFile2019);
GitReleaseManagerAddAssets(parameters.GitHub.Token, "cake-build", "cake-vs", parameters.Version.Milestone, buildResultDir + packageFile2022);
GitReleaseManagerClose(parameters.GitHub.Token, "cake-build", "cake-vs", parameters.Version.Milestone);
})
.OnError(exception =>
Expand All @@ -195,19 +203,21 @@ Task("Upload-Artifact")
.WithCriteria(() => parameters.ShouldPublishToAppVeyor)
.Does(() =>
{
AppVeyor.UploadArtifact(artifacts + "Cake.VisualStudio.vsix");
AppVeyor.UploadArtifact(artifacts + "Cake.VisualStudio.2019.vsix");
AppVeyor.UploadArtifact(artifacts + "Cake.VisualStudio.2022.vsix");
});
Task("Publish-Extension")
.IsDependentOn("Post-Build")
.WithCriteria(() => parameters.ShouldPublishToMyGet)
.Does(() =>
{
var vsixPath = artifacts + "Cake.VisualStudio.vsix";
var client = MyGetClient.GetClient(parameters.MyGet.Url, parameters.MyGet.Key, s => Context.Verbose(s));
Information("Uploading VSIX to {0}...", parameters.MyGet.Url);
var response = client.UploadVsix(GetFile(artifacts + "Cake.VisualStudio.vsix"));
Information("VSIX Upload {0}", response.IsSuccessStatusCode ? "succeeded." : "failed with reason '" + response.ReasonPhrase + "'.");
Information("Uploading VSIXs to {0}...", parameters.MyGet.Url);
var response = client.UploadVsix(GetFile(artifacts + "Cake.VisualStudio.2019.vsix"));
Information("VSIX Upload (2019) {0}", response.IsSuccessStatusCode ? "succeeded." : "failed with reason '" + response.ReasonPhrase + "'.");
response = client.UploadVsix(GetFile(artifacts + "Cake.VisualStudio.2022.vsix"));
Information("VSIX Upload (2019) {0}", response.IsSuccessStatusCode ? "succeeded." : "failed with reason '" + response.ReasonPhrase + "'.");
});
Task("Default")
Expand Down
20 changes: 20 additions & 0 deletions extension-manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"$schema": "http://json.schemastore.org/vsix-publish",
"categories": [
"build"
],
"identity": {
"internalName": "CakeforVisualStudio",
"tags": [
"Build",
"C#",
"Cake"
]
},
"overview": "./README.md",
"priceCategory": "free",
"publisher": "vs-publisher-1392591",
"private": false,
"qna": false,
"repo": "https://github.com/cake-build/cake-vs"
}
Loading

0 comments on commit b50715f

Please sign in to comment.