Skip to content

Commit ef08eae

Browse files
committed
feat: manual action
1 parent e8f6480 commit ef08eae

File tree

1 file changed

+96
-0
lines changed

1 file changed

+96
-0
lines changed
Lines changed: 96 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,96 @@
1+
name: Manual NPM deploy
2+
3+
on:
4+
# Trigger the workflow only manually
5+
workflow_dispatch:
6+
7+
# env:
8+
# GHR_PROJECT_REPONAME: ui5-language-assistant
9+
# GHR_PROJECT_USERNAME: SAP
10+
11+
jobs:
12+
# build:
13+
# # if: github.repository == 'SAP/ui5-language-assistant' && github.ref == 'refs/heads/master'
14+
# if: github.repository == 'vadson71/ui5-language-assistant-vk' && github.ref == 'refs/heads/master'
15+
# strategy:
16+
# matrix:
17+
# os: [ubuntu-latest]
18+
# node-version: [14.x]
19+
# runs-on: ${{ matrix.os }}
20+
# steps:
21+
# - name: Checkout code repository
22+
# uses: actions/checkout@v3
23+
# with:
24+
# fetch-depth: 0 # will fetch all history
25+
# - name: Run install
26+
# uses: borales/actions-yarn@v4
27+
# with:
28+
# cmd: install # will run `yarn install` command
29+
# - name: Run build
30+
# uses: borales/actions-yarn@v4
31+
# with:
32+
# cmd: ci # will run `yarn run ci` command
33+
34+
# - name: Upload vsix artifact
35+
# uses: actions/upload-artifact@v3
36+
# with:
37+
# name: vscode-extension-file
38+
# path: ./packages/vscode-ui5-language-assistant/vscode-ui5-language-assistant*.vsix
39+
# if-no-files-found: error # 'warn' or 'ignore' are also available, defaults to `warn`
40+
41+
# # Get release version number
42+
# - name: get-npm-version
43+
# id: package-version
44+
# uses: martinbeentjes/npm-get-version-action@main
45+
# with:
46+
# path: ./packages/vscode-ui5-language-assistant
47+
48+
deploy-npm:
49+
if: github.repository == 'vadson71/ui5-language-assistant-vk' && github.ref == 'refs/heads/feat/migrate-to-github-actions'
50+
strategy:
51+
matrix:
52+
os: [ubuntu-latest]
53+
node-version: [14.x]
54+
runs-on: ${{ matrix.os }}
55+
# needs: build
56+
57+
steps:
58+
- name: Prerequisite
59+
run: sudo apt-get install libxss1
60+
61+
- name: Checkout code repository
62+
uses: actions/checkout@v3
63+
with:
64+
fetch-depth: 0 # will fetch all history
65+
66+
# Pure lockfile simply doesn't write the lockfile if it has changes.
67+
- name: Run install
68+
uses: borales/actions-yarn@v4
69+
with:
70+
cmd: install --pure-lockfile
71+
72+
# reuse stored generated vsix
73+
- name: Download artifact
74+
uses: actions/download-artifact@v3
75+
with:
76+
name: vscode-extension-file
77+
path: ./packages/vscode-ui5-language-assistant-bas-ext
78+
79+
- name: Check
80+
run: ls ./packages/vscode-ui5-language-assistant-bas-ext -la
81+
82+
- name: Prepare .npmrc
83+
run:
84+
echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" >> ~/.npmrc
85+
86+
# To help debug when lerna detects changes to the working tree and fails the publish
87+
- name: Status
88+
run: git status
89+
90+
# - name: Publish
91+
# # https://github.com/lerna/lerna/issues/2788
92+
# uses: borales/actions-yarn@v4
93+
# with:
94+
# cmd: run release:publish --no-verify-access
95+
96+

0 commit comments

Comments
 (0)