File tree Expand file tree Collapse file tree 7 files changed +48
-6
lines changed Expand file tree Collapse file tree 7 files changed +48
-6
lines changed Original file line number Diff line number Diff line change @@ -45,6 +45,10 @@ indent_style = tab
45
45
indent_style = space
46
46
indent_size = 2
47
47
48
+ # Set properties for `cli_opts.json` files:
49
+ [cli_opts.json ]
50
+ indent_style = tab
51
+
48
52
# Set properties for TypeScript files:
49
53
[* .ts ]
50
54
indent_style = tab
Original file line number Diff line number Diff line change 38
38
timeout-minutes : 5
39
39
- name : Replace all GitHub links to individual packages with npm links
40
40
run : |
41
- find . -type f -name '*.md' -print0 | xargs -0 sed -Ei 's/@stdlib\/([^:]*)\]: https:\/\/github.com\/stdlib-js/@stdlib\/\1\]: https:\/\/www.npmjs.com\/package\/@stdlib/g'
41
+ find . -type f -name '*.md' -print0 | xargs -0 sed -Ei '/tree\/main/b; s/@stdlib\/([^:]*)\]: https:\/\/github.com\/stdlib-js/@stdlib\/\1\]: https:\/\/www.npmjs.com\/package\/@stdlib/g'
42
42
- name : Replace all stdlib GitHub dependencies with the respective npm packages
43
43
run : |
44
44
find package.json -type f -print0 | xargs -0 sed -Ei 's/"github:stdlib-js[^"]*"/"^0.0.x"/g'
Original file line number Diff line number Diff line change @@ -44,11 +44,17 @@ jobs:
44
44
run : |
45
45
npm install || npm install || npm install
46
46
timeout-minutes : 15
47
+ - name : Build native add-on (if present)
48
+ run : |
49
+ if [ -f "binding.gyp" ]; then
50
+ npm install node-gyp --no-save && ./node_modules/.bin/node-gyp rebuild
51
+ fi
47
52
- name : Run tests
48
53
id : tests
49
54
run : |
50
55
npm test || npm test || npm test
51
- - uses : act10ns/slack@v1
56
+ - name : Send status to Slack channel in case of failure
57
+ uses : act10ns/slack@v1
52
58
with :
53
59
status : ${{ job.status }}
54
60
steps : ${{ toJson(steps) }}
Original file line number Diff line number Diff line change @@ -40,20 +40,37 @@ jobs:
40
40
run : |
41
41
npm install || npm install || npm install
42
42
timeout-minutes : 15
43
+ - name : Build native add-on (if present)
44
+ run : |
45
+ if [ -f "binding.gyp" ]; then
46
+ npm install node-gyp --no-save && ./node_modules/.bin/node-gyp rebuild
47
+ fi
43
48
- name : Calculate test coverage
44
49
run : |
45
50
npm run test-cov || npm run test-cov || npm run test-cov
46
51
timeout-minutes : 15
47
52
- name : Upload coverage to Codecov
48
53
id : upload
49
- uses : codecov/codecov-action@v1
54
+ uses : codecov/codecov-action@v2
50
55
with :
51
56
directory : reports/coverage
52
57
flags : unittests
53
58
fail_ci_if_error : true
59
+ - name : Extract coverage value and assign to output
60
+ id : extract-coverage
61
+ run : |
62
+ coverage=`cat reports/coverage/lcov-report/index.html | grep "fraction" | grep -oP '\d+/\d+' | printf %s "$(cat)" | jq -R -s -c 'split("\n")'`
63
+ echo "::set-output name=coverage::$coverage"
54
64
- uses : act10ns/slack@v1
55
65
with :
56
66
status : ${{ job.status }}
57
67
steps : ${{ toJson(steps) }}
58
68
channel : ' #npm-ci'
59
69
if : failure()
70
+ - name : Send Webhook with status to stdlib backend
71
+ uses : distributhor/workflow-webhook@v2
72
+ env :
73
+ webhook_url : ${{ secrets.STDLIB_COVERAGE_URL }}
74
+ webhook_secret : ${{ secrets.STDLIB_WEBHOOK_SECRET }}
75
+ data : ' { "coverage": ${{ steps.extract-coverage.outputs.coverage }}, "run_id": "${{ github.run_id }}" }'
76
+ if : ${{ false }}
Original file line number Diff line number Diff line change 27
27
workflow_run :
28
28
workflows : ["Publish Package"]
29
29
types : [completed]
30
+ workflow_dispatch :
30
31
31
32
# Workflow jobs:
32
33
jobs :
33
34
on-success :
34
35
runs-on : ubuntu-latest
35
36
env :
36
37
SLACK_WEBHOOK_URL : ${{ secrets.SLACK_WEBHOOK_URL }}
37
- if : ${{ github.event.workflow_run.conclusion == 'success' }}
38
+ if : ${{ github.event.workflow_run.conclusion == 'success' || github.event_name == 'workflow_dispatch' }}
38
39
steps :
39
40
- uses : actions/checkout@v2
40
41
- uses : actions/setup-node@v2
45
46
run : |
46
47
npm install --only=prod || npm install --only=prod || npm install --only=prod
47
48
timeout-minutes : 15
48
- - uses : act10ns/slack@v1
49
+ - name : Send notification to Slack in case of failure
50
+ uses : act10ns/slack@v1
49
51
with :
50
52
status : ${{ job.status }}
51
53
steps : ${{ toJson(steps) }}
Original file line number Diff line number Diff line change @@ -16,6 +16,7 @@ Justin Dennison <justin1dennison@gmail.com>
16
16
Marcus <mfantham@users.noreply.github.com>
17
17
Matt Cochrane <matthew.cochrane.eng@gmail.com>
18
18
Milan Raj <rajsite@users.noreply.github.com>
19
+ Momtchil Momtchev <momtchil@momtchev.com>
19
20
Ognjen Jevremović <ognjenjevremovic@users.noreply.github.com>
20
21
Philipp Burckhardt <pburckhardt@outlook.com>
21
22
Ricky Reusser <rsreusser@gmail.com>
Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ limitations under the License.
20
20
21
21
# Contiguous Data Buffer
22
22
23
- [ ![ NPM version] [ npm-image ]] [ npm-url ] [ ![ Build Status] [ test-image ]] [ test-url ] [ ![ Coverage Status] [ coverage-image ]] [ coverage-url ] [ ![ dependencies] [ dependencies-image ]] [ dependencies-url ]
23
+ [ ![ NPM version] [ npm-image ]] [ npm-url ] [ ![ Build Status] [ test-image ]] [ test-url ] [ ![ Coverage Status] [ coverage-image ]] [ coverage-url ] <!-- [![dependencies][dependencies-image]][dependencies-url] -->
24
24
25
25
> Create a zero-filled contiguous linear ndarray data buffer.
26
26
@@ -130,6 +130,14 @@ for ( i = 0; i < DTYPES.length; i++ ) {
130
130
131
131
<!-- /.references -->
132
132
133
+ <!-- Section for related `stdlib` packages. Do not manually edit this section, as it is automatically populated. -->
134
+
135
+ <section class =" related " >
136
+
137
+ </section >
138
+
139
+ <!-- /.related -->
140
+
133
141
<!-- Section for all links. Make sure to keep an empty line after the `section` element and another before the `/section` close. -->
134
142
135
143
@@ -175,9 +183,13 @@ Copyright © 2016-2021. The Stdlib [Authors][stdlib-authors].
175
183
[ coverage-image ] : https://img.shields.io/codecov/c/github/stdlib-js/ndarray-base-buffer/main.svg
176
184
[ coverage-url ] : https://codecov.io/github/stdlib-js/ndarray-base-buffer?branch=main
177
185
186
+ <!--
187
+
178
188
[dependencies-image]: https://img.shields.io/david/stdlib-js/ndarray-base-buffer.svg
179
189
[dependencies-url]: https://david-dm.org/stdlib-js/ndarray-base-buffer/main
180
190
191
+ -->
192
+
181
193
[ chat-image ] : https://img.shields.io/gitter/room/stdlib-js/stdlib.svg
182
194
[ chat-url ] : https://gitter.im/stdlib-js/stdlib/
183
195
You can’t perform that action at this time.
0 commit comments