Skip to content

Commit e313e30

Browse files
committed
Initial public commit
0 parents  commit e313e30

52 files changed

Lines changed: 1672 additions & 0 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/build.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: Build
2+
3+
on:
4+
push:
5+
branches: [ "main" ]
6+
pull_request:
7+
branches: [ "main" ]
8+
9+
jobs:
10+
build:
11+
runs-on: windows-latest
12+
13+
steps:
14+
- uses: actions/checkout@v4
15+
16+
- name: Setup .NET
17+
uses: actions/setup-dotnet@v4
18+
with:
19+
dotnet-version: 9.0.x
20+
21+
- name: Restore dependencies
22+
run: dotnet restore
23+
24+
- name: Build
25+
run: dotnet build --configuration Release --no-restore

.github/workflows/release.yml

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
tags:
6+
- "v*"
7+
workflow_dispatch:
8+
9+
permissions:
10+
contents: write
11+
12+
jobs:
13+
release:
14+
runs-on: windows-latest
15+
16+
steps:
17+
- uses: actions/checkout@v4
18+
19+
- name: Setup .NET
20+
uses: actions/setup-dotnet@v4
21+
with:
22+
dotnet-version: 9.0.x
23+
24+
- name: Restore dependencies
25+
run: dotnet restore
26+
27+
- name: Validate tag matches plugin.json version
28+
if: startsWith(github.ref, 'refs/tags/v')
29+
shell: pwsh
30+
run: |
31+
$plugin = Get-Content "Flow.Launcher.Plugin.MultiprofileBookmarks/plugin.json" | ConvertFrom-Json
32+
$expectedTag = "v$($plugin.Version)"
33+
$actualTag = "${{ github.ref_name }}"
34+
35+
if ($actualTag -ne $expectedTag) {
36+
Write-Error "Tag '$actualTag' does not match plugin version '$($plugin.Version)' (expected '$expectedTag')."
37+
}
38+
39+
- name: Build release package
40+
shell: pwsh
41+
run: ./release.ps1
42+
43+
- name: Upload build artifact
44+
uses: actions/upload-artifact@v4
45+
with:
46+
name: MultiprofileBookmarks
47+
path: Flow.Launcher.Plugin.MultiprofileBookmarks/bin/MultiprofileBookmarks.zip
48+
49+
- name: Create GitHub Release
50+
if: startsWith(github.ref, 'refs/tags/v')
51+
uses: softprops/action-gh-release@v2
52+
with:
53+
files: Flow.Launcher.Plugin.MultiprofileBookmarks/bin/MultiprofileBookmarks.zip

.github/workflows/test.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: Tests
2+
3+
on:
4+
push:
5+
branches: [ "main" ]
6+
pull_request:
7+
branches: [ "main" ]
8+
9+
jobs:
10+
test:
11+
runs-on: windows-latest
12+
13+
steps:
14+
- uses: actions/checkout@v4
15+
16+
- name: Setup .NET
17+
uses: actions/setup-dotnet@v4
18+
with:
19+
dotnet-version: 9.0.x
20+
21+
- name: Restore dependencies
22+
run: dotnet restore
23+
24+
- name: Test
25+
run: dotnet test --configuration Release --verbosity normal

0 commit comments

Comments
 (0)