Skip to content

Commit 63aa76b

Browse files
committed
Add workflow to update namespace Typescript definitions
1 parent df576ff commit 63aa76b

File tree

1 file changed

+76
-0
lines changed

1 file changed

+76
-0
lines changed
Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
#/
2+
# @license Apache-2.0
3+
#
4+
# Copyright (c) 2021 The Stdlib Authors.
5+
#
6+
# Licensed under the Apache License, Version 2.0 (the "License");
7+
# you may not use this file except in compliance with the License.
8+
# You may obtain a copy of the License at
9+
#
10+
# http://www.apache.org/licenses/LICENSE-2.0
11+
#
12+
# Unless required by applicable law or agreed to in writing, software
13+
# distributed under the License is distributed on an "AS IS" BASIS,
14+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15+
# See the License for the specific language governing permissions and
16+
# limitations under the License.
17+
#/
18+
19+
# Workflow name:
20+
name: update_namespace_definitions
21+
22+
# Workflow triggers:
23+
on:
24+
# Allow the workflow to be manually run:
25+
workflow_dispatch:
26+
27+
# Workflow jobs:
28+
jobs:
29+
30+
# Define a job for pushing changes to standalone packages...
31+
update:
32+
33+
# Define a display name:
34+
name: "Update Namespace Typescript Definitions"
35+
36+
# Define the type of virtual host machine:
37+
runs-on: ubuntu-latest
38+
39+
# Define the sequence of job steps...
40+
steps:
41+
42+
# Checkout the repository:
43+
- name: 'Checkout repository'
44+
uses: actions/checkout@v2
45+
with:
46+
# Specify whether to remove untracked files before checking out the repository:
47+
clean: true
48+
49+
# Limit clone depth to the most recent commit:
50+
fetch-depth: 1
51+
52+
# Specify whether to download Git-LFS files:
53+
lfs: false
54+
timeout-minutes: 10
55+
56+
# Install Node.js:
57+
- name: 'Install Node.js'
58+
uses: actions/setup-node@v2
59+
with:
60+
node-version: 15
61+
timeout-minutes: 5
62+
63+
# Install dependencies:
64+
- name: 'Install dependencies'
65+
run: |
66+
make install-node-modules
67+
timeout-minutes: 15
68+
69+
# Update namespace Typescript definitions:
70+
- name: 'Update namespace Typescript definitions'
71+
run: |
72+
make list-pkgs-namespaces | node lib/node_modules/@stdlib/_tools/scripts/create_namespace_types.js
73+
74+
# Create a pull request with the updated definitions:
75+
- name: Create Pull Request
76+
uses: peter-evans/create-pull-request@v3

0 commit comments

Comments
 (0)