-
Notifications
You must be signed in to change notification settings - Fork 1
91 lines (77 loc) · 3.47 KB
/
publish.yml
File metadata and controls
91 lines (77 loc) · 3.47 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
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
name: Publish to VS Marketplace
on:
workflow_dispatch:
permissions:
contents: write
actions: read
jobs:
changelog:
name: Generate Changelog
uses: CodingWithCalvin/.github/.github/workflows/generate-changelog.yml@main
secrets: inherit
publish:
needs: changelog
runs-on: windows-latest
outputs:
version: ${{ steps.artifact_manifest.outputs.version }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: 1. Download artifact
id: download-artifact
uses: dawidd6/action-download-artifact@v6
with:
workflow: build.yml
workflow_conclusion: success
- name: 2. Parse Artifact Manifest
id: artifact_manifest
uses: ActionsTools/read-json-action@main
with:
file_path: ./artifact/CodingWithCalvin.OpenInNotepadPlusPlus.info
- name: 3. Create Tag & Release
uses: ncipollo/release-action@v1.14.0
with:
artifacts: ./artifact/CodingWithCalvin.OpenInNotepadPlusPlus.vsix
body: ${{ needs.changelog.outputs.changelog }}
makeLatest: true
commit: ${{ steps.artifact_manifest.outputs.sha }}
tag: ${{ steps.artifact_manifest.outputs.version }}
- name: 4. Publish Release to Marketplace
if: success()
uses: CodingWithCalvin/GHA-VSMarketplacePublisher@v1
with:
marketplace-pat: ${{ secrets.VS_PAT }}
publish-manifest-path: ./resources/extension.manifest.json
vsix-path: ./artifact/CodingWithCalvin.OpenInNotepadPlusPlus.vsix
notify-bluesky:
name: Post to BlueSky
needs: publish
uses: CodingWithCalvin/.github/.github/workflows/bluesky-post.yml@main
with:
post_text: |
🚀 Open in Notepad++ v${{ needs.publish.outputs.version }} for #VisualStudio has been released!
📝 [Release Notes](https://github.com/${{ github.repository }}/releases/tag/${{ needs.publish.outputs.version }})
🛒 [Marketplace](https://marketplace.visualstudio.com/items?itemName=CodingWithCalvin.VS-OpenInNotepadPlusPlus)
#dotnet #visualstudio #vsix #notepadplusplus
embed_url: https://marketplace.visualstudio.com/items?itemName=CodingWithCalvin.VS-OpenInNotepadPlusPlus
embed_title: "Open in Notepad++ v${{ needs.publish.outputs.version }}"
embed_description: "Visual Studio extension to open files in Notepad++"
secrets:
BLUESKY_USERNAME: ${{ secrets.BLUESKY_USERNAME }}
BLUESKY_APP_PASSWORD: ${{ secrets.BLUESKY_APP_PASSWORD }}
notify-linkedin:
name: Post to LinkedIn
needs: publish
uses: CodingWithCalvin/.github/.github/workflows/linkedin-post.yml@main
with:
post_text: |
🚀 Open in Notepad++ v${{ needs.publish.outputs.version }} for Visual Studio has been released!
📝 Release Notes: https://github.com/${{ github.repository }}/releases/tag/${{ needs.publish.outputs.version }}
🛒 Marketplace: https://marketplace.visualstudio.com/items?itemName=CodingWithCalvin.VS-OpenInNotepadPlusPlus
#dotnet #visualstudio #vsix #notepadplusplus
article_url: https://marketplace.visualstudio.com/items?itemName=CodingWithCalvin.VS-OpenInNotepadPlusPlus
article_title: "Open in Notepad++ v${{ needs.publish.outputs.version }}"
article_description: "Visual Studio extension to open files in Notepad++"
secrets:
LINKEDIN_ACCESS_TOKEN: ${{ secrets.LINKEDIN_ACCESS_TOKEN }}
LINKEDIN_CLIENT_ID: ${{ secrets.LINKEDIN_CLIENT_ID }}