@@ -13,52 +13,130 @@ jobs:
1313 environment : production
1414 env :
1515 CURSORLESS_REPO_ROOT : ${{ github.workspace }}
16+
1617 steps :
17- - uses : actions/checkout@v4
18+ - name : Checkout repository
19+ uses : actions/checkout@v4
1820 with :
21+ # This is needed to get the number of commits in the current branch
1922 fetch-depth : 0
20- - run : corepack enable
21- - uses : actions/setup-node@v4
23+
24+ - name : Install pnpm
25+ uses : pnpm/action-setup@v4
26+
27+ - name : Set up Node.js
28+ uses : actions/setup-node@v4
2229 with :
2330 node-version-file : .nvmrc
2431 cache : pnpm
25- - run : pnpm --color install
26- - run : pnpm --color compile
27- - run : pnpm --color --filter '!cursorless-org' --filter '!cursorless-org-*' build
32+
33+ - name : Install dependencies
34+ run : pnpm --color install
35+
36+ - name : Compile
37+ run : pnpm --color compile
38+
39+ - name : Build
40+ run : pnpm --color --filter '!cursorless-org' --filter '!cursorless-org-*' build
2841 env :
2942 CURSORLESS_DEPLOY : true
43+
3044 - name : Publish to Open VSX Registry
3145 id : publishToOpenVSX
3246 uses : HaaLeo/publish-vscode-extension@v1
3347 with :
3448 pat : ${{ secrets.OPEN_VSX_TOKEN }}
3549 packagePath : packages/cursorless-vscode/dist
50+
3651 - name : Publish to Visual Studio Marketplace
3752 uses : HaaLeo/publish-vscode-extension@v1
3853 with :
3954 pat : ${{ secrets.VS_MARKETPLACE_TOKEN }}
4055 registryUrl : https://marketplace.visualstudio.com
4156 extensionFile : ${{ steps.publishToOpenVSX.outputs.vsixPath }}
4257
58+ publish-neovim-extension :
59+ runs-on : ubuntu-latest
60+ if : ${{ github.event.workflow_run.conclusion == 'success' }}
61+ environment : production
62+ env :
63+ CURSORLESS_REPO_ROOT : ${{ github.workspace }}
64+ STAGING_DIRECTORY : ${{ github.workspace }}/cursorless.nvim-staging
65+
66+ steps :
67+ - name : Checkout repository
68+ uses : actions/checkout@v4
69+
70+ - name : Install pnpm
71+ uses : pnpm/action-setup@v4
72+
73+ - name : Set up Node.js
74+ uses : actions/setup-node@v4
75+ with :
76+ node-version-file : .nvmrc
77+ cache : pnpm
78+
79+ - name : Install dependencies
80+ run : pnpm --color install
81+
82+ - name : Compile
83+ run : pnpm --color compile
84+
85+ - name : Build
86+ run : pnpm --color --filter '!cursorless-org' --filter '!cursorless-org-*' build
87+ env :
88+ CURSORLESS_DEPLOY : true
89+
90+ - name : Checkout cursorless.nvim plugin repo
91+ uses : actions/checkout@v4
92+ with :
93+ token : ${{ secrets.CURSORLESS_BOT_TOKEN }}
94+ repository : hands-free-vim/cursorless.nvim
95+ path : ${{ env.STAGING_DIRECTORY }}
96+
97+ - name : Configure GPG Key
98+ working-directory : ${{ env.STAGING_DIRECTORY }}
99+ run : |
100+ echo -n "$GPG_SIGNING_KEY" | base64 --decode | gpg --import
101+ env :
102+ GPG_SIGNING_KEY : ${{ secrets.CURSORLESS_BOT_GPG_SIGNING_KEY }}
103+
104+ - name : git config
105+ working-directory : ${{ env.STAGING_DIRECTORY }}
106+ run : |
107+ git config user.name cursorless-bot
108+ git config user.email [email protected] 109+ git config user.signingkey A9387720AFC62221
110+ git config commit.gpgsign true
111+
112+ - name : Push compiled files to cursorless.nvim plugin repo
113+ run : bash -x scripts/deploy-cursorless-nvim.sh ${{ env.STAGING_DIRECTORY }}
114+
43115 push-cursorless-talon :
44116 name : Push cursorless-talon subrepo
45117 runs-on : ubuntu-latest
46118 needs : publish-extension
47119 environment : production
120+
48121 steps :
49- - uses : actions/checkout@v4
122+ - name : Checkout repository
123+ uses : actions/checkout@v4
50124 with :
51125 fetch-depth : 0
52126 token : ${{ secrets.CURSORLESS_BOT_TOKEN }}
127+
53128 - name : Configure GPG Key
54129 run : |
55130 echo -n "$GPG_SIGNING_KEY" | base64 --decode | gpg --import
56131 env :
57132 GPG_SIGNING_KEY : ${{ secrets.CURSORLESS_BOT_GPG_SIGNING_KEY }}
133+
58134 - name : git config
59135 run : |
60136 git config user.name cursorless-bot
61137 git config user.email [email protected] 62138 git config user.signingkey A9387720AFC62221
63139 git config commit.gpgsign true
64- - run : bash -x scripts/deploy-cursorless-talon.sh
140+
141+ - name : Push cursorless-talon subrepo
142+ run : bash -x scripts/deploy-cursorless-talon.sh
0 commit comments