Skip to content

Commit d20fcae

Browse files
committed
Standardization 2.0
1 parent afaa781 commit d20fcae

18 files changed

+268
-128
lines changed

.github/workflows/publish.yml

+45
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
name: Publish to VS Marketplace
2+
3+
on:
4+
workflow_dispatch:
5+
6+
jobs:
7+
publish:
8+
runs-on: windows-latest
9+
steps:
10+
- name: Checkout
11+
uses: actions/checkout@v4
12+
13+
- name: 1. Download artifact
14+
id: download-artifact
15+
uses: dawidd6/action-download-artifact@v2
16+
with:
17+
github_token: ${{ secrets.GH_SECRET }}
18+
workflow: release_build_and_deploy.yml
19+
workflow_conclusion: success
20+
21+
- name: 2. Parse Artifact Manifest
22+
id: artifact_manifest
23+
uses: ActionsTools/read-json-action@main
24+
with:
25+
file_path: ./artifact/CodingWithCalvin.WebcamStudio.info
26+
27+
- name: 3. Create Tag & Release
28+
uses: ncipollo/release-action@v1.14.0
29+
with:
30+
artifacts: ./artifact/CodingWithCalvin.WebcamStudio.vsix
31+
generateReleaseNotes: true
32+
makeLatest: true
33+
token: ${{ secrets.GH_SECRET }}
34+
commit: ${{ steps.artifact_manifest.outputs.sha }}
35+
tag: ${{ steps.artifact_manifest.outputs.version }}
36+
37+
- name: 4. Publish Release to Marketplace
38+
if: success()
39+
uses: CodingWithCalvin/GHA-VSMarketplacePublisher@v1
40+
with:
41+
marketplace-pat: ${{ secrets.VS_PAT }}
42+
publish-manifest-path: ./resources/extension.manifest.json
43+
vsix-path: ./artifact/CodingWithCalvin.WebcamStudio.vsix
44+
45+
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: 'Build and Deploy'
2+
3+
on:
4+
workflow_dispatch:
5+
pull_request:
6+
types: [opened, reopened]
7+
push:
8+
branches:
9+
- main
10+
tags-ignore:
11+
- '[0-9]+.[0-9]+.[0-9]+.[0-9]+'
12+
13+
jobs:
14+
Release-Build-and-Deploy:
15+
runs-on: windows-latest
16+
17+
steps:
18+
- uses: actions/checkout@v4
19+
- uses: microsoft/setup-msbuild@v2
20+
- uses: nuget/setup-nuget@v2
21+
22+
- name: 1. Versioning Release
23+
id: step-version
24+
uses: CodingWithCalvin/GHA-VSVsixVersioner@v1
25+
with:
26+
extension-manifest-file: 'src/CodingWithCalvin.WebcamStudio/source.extension.vsixmanifest'
27+
extension-source-file: 'src/CodingWithCalvin.WebcamStudio/source.extension.cs'
28+
29+
- name: 2. Restoring Packages
30+
run: nuget restore src/CodingWithCalvin.WebcamStudio.sln
31+
32+
- name: 3. Building Project
33+
run: msbuild 'src/CodingWithCalvin.WebcamStudio/CodingWithCalvin.WebcamStudio.csproj' /p:configuration='Release' /p:platform='x64' /p:DeployExtension=False
34+
35+
- name: 4. Create Information File
36+
uses: jsdaniell/create-json@v1.2.3
37+
with:
38+
name: 'src/CodingWithCalvin.WebcamStudio/bin/x64/Release/CodingWithCalvin.WebcamStudio.info'
39+
json: '{"sha":"${{ github.sha }}", "version":"${{ steps.step-version.outputs.version }}"}'
40+
41+
- name: 5. Publishing Build Artifact
42+
uses: actions/upload-artifact@v4
43+
with:
44+
path: |
45+
src/CodingWithCalvin.WebcamStudio/bin/x64/Release/CodingWithCalvin.WebcamStudio.info
46+
src/CodingWithCalvin.WebcamStudio/bin/x64/Release/CodingWithCalvin.WebcamStudio.vsix

.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
assemblies/
2+
13
## Ignore Visual Studio temporary files, build results, and
24
## files generated by popular Visual Studio add-ons.
35
##

README.md

+38-1
Original file line numberDiff line numberDiff line change
@@ -1 +1,38 @@
1-
# VisualStudioCam
1+
# Webcam Studio (BETA)
2+
3+
A Visual Studio extension that embeds the Telerik Radcam control into a Visual Studio tool window, allowing you to embed yourself right inside Visual Studio!
4+
5+
## License
6+
7+
[![License - MIT](https://img.shields.io/github/license/codingwithcalvin/VS-WebcamStudio?style=for-the-badge)](https://img.shields.io/github/license/codingwithcalvin/VS-WebcamStudio?style=for-the-badge)
8+
9+
## Build Status
10+
11+
![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/CodingWithCalvin/VS-WebcamStudio/release_build_and_deploy.yml?style=for-the-badge)
12+
13+
## Marketplace Status
14+
15+
[![Marketplace Installations](https://img.shields.io/visual-studio-marketplace/i/codingwithcalvin.VS-WebcamStudio?style=for-the-badge)](https://img.shields.io/visual-studio-marketplace/i/codingwithcalvin.VS-WebcamStudio?style=for-the-badge) [![Marketplace Downloads](https://img.shields.io/visual-studio-marketplace/d/codingwithcalvin.VS-WebcamStudio?style=for-the-badge)](https://img.shields.io/visual-studio-marketplace/d/codingwithcalvin.VS-WebcamStudio?style=for-the-badge)
16+
[![Marketplace Version](https://img.shields.io/visual-studio-marketplace/v/codingwithcalvin.VS-WebcamStudio?style=for-the-badge)](https://img.shields.io/visual-studio-marketplace/v/codingwithcalvin.VS-WebcamStudio?style=for-the-badge) [![Marketplace Rating](https://img.shields.io/visual-studio-marketplace/r/codingwithcalvin.VS-WebcamStudio?style=for-the-badge)](https://img.shields.io/visual-studio-marketplace/r/codingwithcalvin.VS-WebcamStudio?style=for-the-badge)
17+
18+
## Contribute
19+
20+
Contributions are welcome! Issues, PRs, etc. While it may seem this extension is "done", who knows what the future may hold for it?
21+
22+
For cloning and building this project yourself, make sure to install the [Extensibility Essentials 2022 extension](https://marketplace.visualstudio.com/items?itemName=MadsKristensen.ExtensibilityEssentials2022) for Visual Studio which enables some features used by this project.
23+
24+
This extension requires the usage of Telerik controls that are NOT available via the GitHub repository. You must provide these libraries yourself.
25+
26+
## NOTICE
27+
28+
The following files need added to your extension's installation directory AFTER install as they cannot be shipped inside the VSIX (for some reason?)
29+
30+
Locate the extension's installation directory (it is installed per-user, so it will be somewhere in `%USERPROFILE%\AppData\Local\Microsoft\VisualStudio\<version>\Extensions\<weird directory>`).
31+
Create a subfolder here called `assemblies`, and place the following files:
32+
33+
1. MediaFoundation.dll
34+
1. SharpDX.Direct3D9.dll
35+
1. SharpDX.dll
36+
1. Telerik.Windows.Controls.dll
37+
1. Telerik.Windows.Controls.Media.dll
38+
1. Telerik.Windows.MediaFoundation

resources/extension.manifest.json

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"$schema": "http://json.schemastore.org/vsix-publish",
3+
"categories": [
4+
"coding",
5+
"build",
6+
"programming languages"
7+
],
8+
"identity": {
9+
"internalName": "VS-WebcamStudio"
10+
},
11+
"overview": "../README.md",
12+
"publisher": "CodingWithCalvin"
13+
}

resources/icon.png

303 KB
Loading

src/CodingWithCalvin.VisualStudioCam/CodingWithCalvin.VisualStudioCam/ToolWindow.cs

-20
This file was deleted.

src/CodingWithCalvin.VisualStudioCam/CodingWithCalvin.VisualStudioCam/WebcamView.xaml.cs

-25
This file was deleted.

src/CodingWithCalvin.VisualStudioCam/CodingWithCalvin.VisualStudioCam/source.extension.vsixmanifest

-30
This file was deleted.
+9-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,15 @@ Microsoft Visual Studio Solution File, Format Version 12.00
33
# Visual Studio Version 17
44
VisualStudioVersion = 17.7.33711.374
55
MinimumVisualStudioVersion = 10.0.40219.1
6-
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CodingWithCalvin.VisualStudioCam", "CodingWithCalvin.VisualStudioCam\CodingWithCalvin.VisualStudioCam.csproj", "{9E680E03-63F9-40AD-9FBB-3BAA4BCFDC25}"
6+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CodingWithCalvin.WebcamStudio", "CodingWithCalvin.WebcamStudio\CodingWithCalvin.WebcamStudio.csproj", "{9E680E03-63F9-40AD-9FBB-3BAA4BCFDC25}"
7+
EndProject
8+
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{635B9963-AF24-4329-A80C-FB14FBE96264}"
9+
ProjectSection(SolutionItems) = preProject
10+
..\resources\extension.manifest.json = ..\resources\extension.manifest.json
11+
..\.github\workflows\publish.yml = ..\.github\workflows\publish.yml
12+
..\README.md = ..\README.md
13+
..\.github\workflows\release_build_and_deploy.yml = ..\.github\workflows\release_build_and_deploy.yml
14+
EndProjectSection
715
EndProject
816
Global
917
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@
3232
<ProjectGuid>{9E680E03-63F9-40AD-9FBB-3BAA4BCFDC25}</ProjectGuid>
3333
<OutputType>Library</OutputType>
3434
<AppDesignerFolder>Properties</AppDesignerFolder>
35-
<RootNamespace>CodingWithCalvin.VisualStudioCam</RootNamespace>
36-
<AssemblyName>CodingWithCalvin.VisualStudioCam</AssemblyName>
35+
<RootNamespace>CodingWithCalvin.WebcamStudio</RootNamespace>
36+
<AssemblyName>CodingWithCalvin.WebcamStudio</AssemblyName>
3737
<TargetFrameworkVersion>v4.8</TargetFrameworkVersion>
3838
<GeneratePkgDefFile>true</GeneratePkgDefFile>
3939
<UseCodebase>true</UseCodebase>
@@ -65,15 +65,26 @@
6565
</PropertyGroup>
6666
<ItemGroup>
6767
<Compile Include="Properties\AssemblyInfo.cs" />
68+
<Compile Include="source.extension.cs">
69+
<AutoGen>True</AutoGen>
70+
<DesignTime>True</DesignTime>
71+
<DependentUpon>source.extension.vsixmanifest</DependentUpon>
72+
</Compile>
6873
<Compile Include="ToolWindow.cs" />
69-
<Compile Include="VSPackage.cs" />
74+
<Compile Include="WebcamStudioPackage.cs" />
7075
<Compile Include="WebcamView.xaml.cs">
7176
<DependentUpon>WebcamView.xaml</DependentUpon>
7277
</Compile>
7378
</ItemGroup>
7479
<ItemGroup>
80+
<Content Include="..\..\LICENSE">
81+
<Link>resources\LICENSE</Link>
82+
<IncludeInVSIX>true</IncludeInVSIX>
83+
</Content>
7584
<None Include="source.extension.vsixmanifest">
7685
<SubType>Designer</SubType>
86+
<Generator>VsixManifestGenerator</Generator>
87+
<LastGenOutput>source.extension.cs</LastGenOutput>
7788
</None>
7889
</ItemGroup>
7990
<ItemGroup>
@@ -90,10 +101,10 @@
90101
<Reference Include="WindowsBase" />
91102
</ItemGroup>
92103
<ItemGroup>
93-
<PackageReference Include="Microsoft.VisualStudio.SDK" Version="17.6.36389" ExcludeAssets="runtime">
104+
<PackageReference Include="Microsoft.VisualStudio.SDK" Version="17.9.37000" ExcludeAssets="runtime">
94105
<IncludeAssets>compile; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
95106
</PackageReference>
96-
<PackageReference Include="Microsoft.VSSDK.BuildTools" Version="17.6.2164">
107+
<PackageReference Include="Microsoft.VSSDK.BuildTools" Version="17.9.3184">
97108
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
98109
<PrivateAssets>all</PrivateAssets>
99110
</PackageReference>
@@ -106,41 +117,9 @@
106117
</ItemGroup>
107118
<ItemGroup />
108119
<ItemGroup>
109-
<Content Include="C:\Program Files %28x86%29\Progress\Telerik UI for WPF R1 2023\Binaries\WPF45\MediaFoundation\MediaFoundation.dll">
110-
<Link>Assemblies\MediaFoundation.dll</Link>
111-
<IncludeInVSIX>true</IncludeInVSIX>
112-
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
113-
<InstallRoot>ReferenceAssemblies</InstallRoot>
114-
</Content>
115-
<Content Include="C:\Program Files %28x86%29\Progress\Telerik UI for WPF R1 2023\Binaries\WPF45\SharpDX\SharpDX.Direct3D9.dll">
116-
<Link>Assemblies\SharpDX.Direct3D9.dll</Link>
117-
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
118-
<IncludeInVSIX>true</IncludeInVSIX>
119-
<InstallRoot>ReferenceAssemblies</InstallRoot>
120-
</Content>
121-
<Content Include="C:\Program Files %28x86%29\Progress\Telerik UI for WPF R1 2023\Binaries\WPF45\SharpDX\SharpDX.dll">
122-
<Link>Assemblies\SharpDX.dll</Link>
123-
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
124-
<IncludeInVSIX>true</IncludeInVSIX>
125-
<InstallRoot>ReferenceAssemblies</InstallRoot>
126-
</Content>
127-
<Content Include="C:\Program Files %28x86%29\Progress\Telerik UI for WPF R1 2023\Binaries\WPF45\Telerik.Windows.Controls.dll">
128-
<Link>Assemblies\Telerik.Windows.Controls.dll</Link>
129-
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
130-
<IncludeInVSIX>true</IncludeInVSIX>
131-
<InstallRoot>ReferenceAssemblies</InstallRoot>
132-
</Content>
133-
<Content Include="C:\Program Files %28x86%29\Progress\Telerik UI for WPF R1 2023\Binaries\WPF45\Telerik.Windows.Controls.Media.dll">
134-
<Link>Assemblies\Telerik.Windows.Controls.Media.dll</Link>
135-
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
136-
<IncludeInVSIX>true</IncludeInVSIX>
137-
<InstallRoot>ReferenceAssemblies</InstallRoot>
138-
</Content>
139-
<Content Include="C:\Program Files %28x86%29\Progress\Telerik UI for WPF R1 2023\Binaries\WPF45\Telerik.Windows.MediaFoundation.dll">
140-
<Link>Assemblies\Telerik.Windows.MediaFoundation.dll</Link>
141-
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
120+
<Content Include="..\..\resources\icon.png">
121+
<Link>resources\icon.png</Link>
142122
<IncludeInVSIX>true</IncludeInVSIX>
143-
<InstallRoot>ReferenceAssemblies</InstallRoot>
144123
</Content>
145124
</ItemGroup>
146125
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
using System.Runtime.InteropServices;
2+
using Microsoft.VisualStudio.Shell;
3+
4+
namespace CodingWithCalvin.WebcamStudio
5+
{
6+
[Guid("79FC33BF-8DA0-477A-B315-5A48A38FD54D")]
7+
public class ToolWindow : ToolWindowPane
8+
{
9+
public ToolWindow()
10+
{
11+
Caption = "Webcam";
12+
Content = new WebcamView();
13+
}
14+
}
15+
}

0 commit comments

Comments
 (0)