Skip to content

Commit d5f3cc6

Browse files
committed
Auto-generated commit
1 parent 5e05281 commit d5f3cc6

File tree

14 files changed

+139
-61
lines changed

14 files changed

+139
-61
lines changed

.github/workflows/publish.yml

Lines changed: 2 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#/
22
# @license Apache-2.0
33
#
4-
# Copyright (c) 2021 The Stdlib Authors.
4+
# Copyright (c) 2023 The Stdlib Authors.
55
#
66
# Licensed under the Apache License, Version 2.0 (the "License");
77
# you may not use this file except in compliance with the License.
@@ -46,7 +46,7 @@ jobs:
4646
publish:
4747

4848
# Define display name:
49-
name: 'Publish package to npm'
49+
name: 'Publish top-level package to npm'
5050

5151
# Define the type of virtual host machine on which to run the job:
5252
runs-on: ubuntu-latest
@@ -103,54 +103,6 @@ jobs:
103103
SLUG=${{ github.repository }}
104104
git push "https://$GITHUB_ACTOR:[email protected]/$SLUG.git" --follow-tags
105105
106-
# Remove CLI:
107-
- name: 'Remove CLI'
108-
if: ${{ github.ref == 'refs/heads/main' }}
109-
run: |
110-
# Exit if the package does not have a CLI:
111-
if ! grep -q '"bin":' package.json; then
112-
exit 0
113-
fi
114-
rm -rf ./bin/cli
115-
rm -f test/test.cli.js
116-
rm -f etc/cli_opts.json
117-
rm -f docs/usage.txt
118-
119-
# For all dependencies, check in all *.js files if they are still used; if not, remove them:
120-
jq -r '.dependencies | keys[]' ./package.json | while read -r dep; do
121-
dep=$(echo "$dep" | xargs)
122-
if ! grep -q "$dep" lib/** && ! grep -q -s "$dep" manifest.json && ! grep -q -s "$dep" include.gypi; then
123-
jq --indent 2 "del(.dependencies[\"$dep\"])" ./package.json > ./package.json.tmp
124-
mv ./package.json.tmp ./package.json
125-
fi
126-
done
127-
jq -r '.devDependencies | keys[]' ./package.json | while read -r dep; do
128-
if [[ "$dep" != "@stdlib"* ]]; then
129-
continue
130-
fi
131-
dep=$(echo "$dep" | xargs)
132-
if ! grep -q "$dep" lib/** && ! grep -q -s "$dep" manifest.json && ! grep -q -s "$dep" include.gypi; then
133-
jq --indent 2 "del(.devDependencies[\"$dep\"])" ./package.json > ./package.json.tmp
134-
mv ./package.json.tmp ./package.json
135-
fi
136-
done
137-
138-
# Remove CLI section:
139-
find . -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/(\* \* \*\n+)?<section class=\"cli\">[\s\S]+?<\!\-\- \/.cli \-\->//"
140-
141-
# Remove CLI from package.json:
142-
jq -r 'del(.bin)' package.json > package.json.tmp
143-
mv package.json.tmp package.json
144-
145-
# Add entry for CLI package to See Also section of README.md:
146-
cliPkgName=$(jq -r '.name' package.json)-cli
147-
escapedPkg=$(echo "$cliPkgName" | sed -e 's/\//\\\//g')
148-
escapedPkg=$(echo "$escapedPkg" | sed -e 's/\@/\\\@/g')
149-
find . -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/<section class=\"related\">(?:\n\n\* \* \*\n\n## See Also\n\n)?/<section class=\"related\">\n\n## See Also\n\n- <span class=\"package-name\">[\`$escapedPkg\`][$escapedPkg]<\/span><span class=\"delimiter\">: <\/span><span class=\"description\">CLI package for use as a command-line utility.<\/span>\n/"
150-
151-
# Add link definition for CLI package to README.md:
152-
find . -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/<section class=\"links\">/<section class=\"links\">\n\n[$escapedPkg]: https:\/\/www.npmjs.com\/package\/$escapedPkg/"
153-
154106
# Replace GitHub MathJax equations with SVGs:
155107
- name: 'Replace GitHub MathJax equations with SVGs'
156108
run: |

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -205,8 +205,8 @@ Copyright &copy; 2016-2023. The Stdlib [Authors][stdlib-authors].
205205
[npm-image]: http://img.shields.io/npm/v/@stdlib/complex.svg
206206
[npm-url]: https://npmjs.org/package/@stdlib/complex
207207

208-
[test-image]: https://github.com/stdlib-js/complex/actions/workflows/test.yml/badge.svg?branch=v0.1.1
209-
[test-url]: https://github.com/stdlib-js/complex/actions/workflows/test.yml?query=branch:v0.1.1
208+
[test-image]: https://github.com/stdlib-js/complex/actions/workflows/test.yml/badge.svg?branch=main
209+
[test-url]: https://github.com/stdlib-js/complex/actions/workflows/test.yml?query=branch:main
210210

211211
[coverage-image]: https://img.shields.io/codecov/c/github/stdlib-js/complex/main.svg
212212
[coverage-url]: https://codecov.io/github/stdlib-js/complex?branch=main

conj/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -223,9 +223,9 @@ int main( void ) {
223223

224224
## See Also
225225

226-
- <span class="package-name">[`@stdlib/complex/double-precision complex floating-point number`][@stdlib/complex/imag]</span><span class="delimiter">: </span><span class="description">return the imaginary component of a complex number.</span>
227-
- <span class="package-name">[`@stdlib/complex/real`][@stdlib/complex/real]</span><span class="delimiter">: </span><span class="description">return the real component of a complex number.</span>
228-
- <span class="package-name">[`@stdlib/complex/reim`][@stdlib/complex/reim]</span><span class="delimiter">: </span><span class="description">return the real and imaginary components of a complex number.</span>
226+
- <span class="package-name">[`@stdlib/complex/imag`][@stdlib/complex/imag]</span><span class="delimiter">: </span><span class="description">return the imaginary component of a double-precision complex floating-point number.</span>
227+
- <span class="package-name">[`@stdlib/complex/real`][@stdlib/complex/real]</span><span class="delimiter">: </span><span class="description">return the real component of a double-precision complex floating-point number.</span>
228+
- <span class="package-name">[`@stdlib/complex/reim`][@stdlib/complex/reim]</span><span class="delimiter">: </span><span class="description">return the real and imaginary components of a double-precision complex floating-point number.</span>
229229

230230
</section>
231231

conjf/README.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -219,6 +219,15 @@ int main( void ) {
219219

220220
<section class="related">
221221

222+
* * *
223+
224+
## See Also
225+
226+
- <span class="package-name">[`@stdlib/complex/conj`][@stdlib/complex/conj]</span><span class="delimiter">: </span><span class="description">return the complex conjugate of a double-precision complex floating-point number.</span>
227+
- <span class="package-name">[`@stdlib/complex/imagf`][@stdlib/complex/imagf]</span><span class="delimiter">: </span><span class="description">return the imaginary component of a single-precision complex floating-point number.</span>
228+
- <span class="package-name">[`@stdlib/complex/realf`][@stdlib/complex/realf]</span><span class="delimiter">: </span><span class="description">return the real component of a single-precision complex floating-point number.</span>
229+
- <span class="package-name">[`@stdlib/complex/reimf`][@stdlib/complex/reimf]</span><span class="delimiter">: </span><span class="description">return the real and imaginary components of a single-precision complex floating-point number.</span>
230+
222231
</section>
223232

224233
<!-- /.related -->
@@ -229,6 +238,18 @@ int main( void ) {
229238

230239
[complex-conjugate]: https://en.wikipedia.org/wiki/Complex_conjugate
231240

241+
<!-- <related-links> -->
242+
243+
[@stdlib/complex/conj]: https://github.com/stdlib-js/complex/tree/main/conj
244+
245+
[@stdlib/complex/imagf]: https://github.com/stdlib-js/complex/tree/main/imagf
246+
247+
[@stdlib/complex/realf]: https://github.com/stdlib-js/complex/tree/main/realf
248+
249+
[@stdlib/complex/reimf]: https://github.com/stdlib-js/complex/tree/main/reimf
250+
251+
<!-- </related-links> -->
252+
232253
</section>
233254

234255
<!-- /.links -->

ctors/README.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,12 @@ for ( i = 0; i < DTYPES.length; i++ ) {
111111

112112
<section class="related">
113113

114+
* * *
115+
116+
## See Also
117+
118+
- <span class="package-name">[`@stdlib/array/typed-complex-ctors`][@stdlib/array/typed-complex-ctors]</span><span class="delimiter">: </span><span class="description">complex typed array constructors.</span>
119+
114120
</section>
115121

116122
<!-- /.related -->
@@ -119,6 +125,12 @@ for ( i = 0; i < DTYPES.length; i++ ) {
119125

120126
<section class="links">
121127

128+
<!-- <related-links> -->
129+
130+
[@stdlib/array/typed-complex-ctors]: https://github.com/stdlib-js/array-typed-complex-ctors
131+
132+
<!-- </related-links> -->
133+
122134
</section>
123135

124136
<!-- /.links -->

dtype/README.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,12 @@ for ( i = 0; i < DTYPES.length; i++ ) {
115115

116116
<section class="related">
117117

118+
* * *
119+
120+
## See Also
121+
122+
- <span class="package-name">[`@stdlib/array/dtype`][@stdlib/array/dtype]</span><span class="delimiter">: </span><span class="description">return the data type of an array.</span>
123+
118124
</section>
119125

120126
<!-- /.related -->
@@ -125,6 +131,12 @@ for ( i = 0; i < DTYPES.length; i++ ) {
125131

126132
[@stdlib/complex/dtypes]: https://github.com/stdlib-js/complex/tree/main/dtypes
127133

134+
<!-- <related-links> -->
135+
136+
[@stdlib/array/dtype]: https://github.com/stdlib-js/array-dtype
137+
138+
<!-- </related-links> -->
139+
128140
</section>
129141

130142
<!-- /.links -->

dtypes/README.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,12 @@ bool = isdtype( 'beep' );
117117

118118
<section class="related">
119119

120+
* * *
121+
122+
## See Also
123+
124+
- <span class="package-name">[`@stdlib/array/typed-complex-dtypes`][@stdlib/array/typed-complex-dtypes]</span><span class="delimiter">: </span><span class="description">list of complex typed array data types.</span>
125+
120126
</section>
121127

122128
<!-- /.related -->
@@ -125,6 +131,12 @@ bool = isdtype( 'beep' );
125131

126132
<section class="links">
127133

134+
<!-- <related-links> -->
135+
136+
[@stdlib/array/typed-complex-dtypes]: https://github.com/stdlib-js/array-typed-complex-dtypes
137+
138+
<!-- </related-links> -->
139+
128140
</section>
129141

130142
<!-- /.links -->

imag/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -206,8 +206,8 @@ int main( void ) {
206206

207207
## See Also
208208

209-
- <span class="package-name">[`@stdlib/complex/real`][@stdlib/complex/real]</span><span class="delimiter">: </span><span class="description">return the real component of a complex number.</span>
210-
- <span class="package-name">[`@stdlib/complex/reim`][@stdlib/complex/reim]</span><span class="delimiter">: </span><span class="description">return the real and imaginary components of a complex number.</span>
209+
- <span class="package-name">[`@stdlib/complex/real`][@stdlib/complex/real]</span><span class="delimiter">: </span><span class="description">return the real component of a double-precision complex floating-point number.</span>
210+
- <span class="package-name">[`@stdlib/complex/reim`][@stdlib/complex/reim]</span><span class="delimiter">: </span><span class="description">return the real and imaginary components of a double-precision complex floating-point number.</span>
211211

212212
</section>
213213

imagf/README.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -202,6 +202,14 @@ int main( void ) {
202202

203203
<section class="related">
204204

205+
* * *
206+
207+
## See Also
208+
209+
- <span class="package-name">[`@stdlib/complex/imag`][@stdlib/complex/imag]</span><span class="delimiter">: </span><span class="description">return the imaginary component of a double-precision complex floating-point number.</span>
210+
- <span class="package-name">[`@stdlib/complex/realf`][@stdlib/complex/realf]</span><span class="delimiter">: </span><span class="description">return the real component of a single-precision complex floating-point number.</span>
211+
- <span class="package-name">[`@stdlib/complex/reimf`][@stdlib/complex/reimf]</span><span class="delimiter">: </span><span class="description">return the real and imaginary components of a single-precision complex floating-point number.</span>
212+
205213
</section>
206214

207215
<!-- /.related -->
@@ -210,6 +218,16 @@ int main( void ) {
210218

211219
<section class="links">
212220

221+
<!-- <related-links> -->
222+
223+
[@stdlib/complex/imag]: https://github.com/stdlib-js/complex/tree/main/imag
224+
225+
[@stdlib/complex/realf]: https://github.com/stdlib-js/complex/tree/main/realf
226+
227+
[@stdlib/complex/reimf]: https://github.com/stdlib-js/complex/tree/main/reimf
228+
229+
<!-- </related-links> -->
230+
213231
</section>
214232

215233
<!-- /.links -->

promotion-rules/README.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -134,6 +134,13 @@ for ( i = 0; i < DTYPES.length; i++ ) {
134134

135135
<section class="related">
136136

137+
* * *
138+
139+
## See Also
140+
141+
- <span class="package-name">[`@stdlib/array/promotion-rules`][@stdlib/array/promotion-rules]</span><span class="delimiter">: </span><span class="description">return the array data type with the smallest size and closest kind to which array data types can be safely cast.</span>
142+
- <span class="package-name">[`@stdlib/ndarray/promotion-rules`][@stdlib/ndarray/promotion-rules]</span><span class="delimiter">: </span><span class="description">return the ndarray data type with the smallest size and closest kind to which ndarray data types can be safely cast.</span>
143+
137144
</section>
138145

139146
<!-- /.related -->
@@ -144,6 +151,14 @@ for ( i = 0; i < DTYPES.length; i++ ) {
144151

145152
[@stdlib/complex/dtypes]: https://github.com/stdlib-js/complex/tree/main/dtypes
146153

154+
<!-- <related-links> -->
155+
156+
[@stdlib/array/promotion-rules]: https://github.com/stdlib-js/array-promotion-rules
157+
158+
[@stdlib/ndarray/promotion-rules]: https://github.com/stdlib-js/ndarray-promotion-rules
159+
160+
<!-- </related-links> -->
161+
147162
</section>
148163

149164
<!-- /.links -->

real/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -206,8 +206,8 @@ int main( void ) {
206206

207207
## See Also
208208

209-
- <span class="package-name">[`@stdlib/complex/imag`][@stdlib/complex/imag]</span><span class="delimiter">: </span><span class="description">return the imaginary component of a complex number.</span>
210-
- <span class="package-name">[`@stdlib/complex/reim`][@stdlib/complex/reim]</span><span class="delimiter">: </span><span class="description">return the real and imaginary components of a complex number.</span>
209+
- <span class="package-name">[`@stdlib/complex/imag`][@stdlib/complex/imag]</span><span class="delimiter">: </span><span class="description">return the imaginary component of a double-precision complex floating-point number.</span>
210+
- <span class="package-name">[`@stdlib/complex/reim`][@stdlib/complex/reim]</span><span class="delimiter">: </span><span class="description">return the real and imaginary components of a double-precision complex floating-point number.</span>
211211

212212
</section>
213213

realf/README.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -202,6 +202,14 @@ int main( void ) {
202202

203203
<section class="related">
204204

205+
* * *
206+
207+
## See Also
208+
209+
- <span class="package-name">[`@stdlib/complex/imagf`][@stdlib/complex/imagf]</span><span class="delimiter">: </span><span class="description">return the imaginary component of a single-precision complex floating-point number.</span>
210+
- <span class="package-name">[`@stdlib/complex/real`][@stdlib/complex/real]</span><span class="delimiter">: </span><span class="description">return the real component of a double-precision complex floating-point number.</span>
211+
- <span class="package-name">[`@stdlib/complex/reimf`][@stdlib/complex/reimf]</span><span class="delimiter">: </span><span class="description">return the real and imaginary components of a single-precision complex floating-point number.</span>
212+
205213
</section>
206214

207215
<!-- /.related -->
@@ -210,6 +218,16 @@ int main( void ) {
210218

211219
<section class="links">
212220

221+
<!-- <related-links> -->
222+
223+
[@stdlib/complex/imagf]: https://github.com/stdlib-js/complex/tree/main/imagf
224+
225+
[@stdlib/complex/real]: https://github.com/stdlib-js/complex/tree/main/real
226+
227+
[@stdlib/complex/reimf]: https://github.com/stdlib-js/complex/tree/main/reimf
228+
229+
<!-- </related-links> -->
230+
213231
</section>
214232

215233
<!-- /.links -->

reim/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -215,8 +215,8 @@ int main( void ) {
215215
216216
## See Also
217217
218-
- <span class="package-name">[`@stdlib/complex/imag`][@stdlib/complex/imag]</span><span class="delimiter">: </span><span class="description">return the imaginary component of a complex number.</span>
219-
- <span class="package-name">[`@stdlib/complex/real`][@stdlib/complex/real]</span><span class="delimiter">: </span><span class="description">return the real component of a complex number.</span>
218+
- <span class="package-name">[`@stdlib/complex/imag`][@stdlib/complex/imag]</span><span class="delimiter">: </span><span class="description">return the imaginary component of a double-precision complex floating-point number.</span>
219+
- <span class="package-name">[`@stdlib/complex/real`][@stdlib/complex/real]</span><span class="delimiter">: </span><span class="description">return the real component of a double-precision complex floating-point number.</span>
220220
221221
</section>
222222

reimf/README.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -211,6 +211,14 @@ int main( void ) {
211211
212212
<section class="related">
213213
214+
* * *
215+
216+
## See Also
217+
218+
- <span class="package-name">[`@stdlib/complex/imagf`][@stdlib/complex/imagf]</span><span class="delimiter">: </span><span class="description">return the imaginary component of a single-precision complex floating-point number.</span>
219+
- <span class="package-name">[`@stdlib/complex/realf`][@stdlib/complex/realf]</span><span class="delimiter">: </span><span class="description">return the real component of a single-precision complex floating-point number.</span>
220+
- <span class="package-name">[`@stdlib/complex/reim`][@stdlib/complex/reim]</span><span class="delimiter">: </span><span class="description">return the real and imaginary components of a double-precision complex floating-point number.</span>
221+
214222
</section>
215223
216224
<!-- /.related -->
@@ -219,6 +227,16 @@ int main( void ) {
219227
220228
<section class="links">
221229
230+
<!-- <related-links> -->
231+
232+
[@stdlib/complex/imagf]: https://github.com/stdlib-js/complex/tree/main/imagf
233+
234+
[@stdlib/complex/realf]: https://github.com/stdlib-js/complex/tree/main/realf
235+
236+
[@stdlib/complex/reim]: https://github.com/stdlib-js/complex/tree/main/reim
237+
238+
<!-- </related-links> -->
239+
222240
</section>
223241
224242
<!-- /.links -->

0 commit comments

Comments
 (0)