8000 Auto-generated commit · stdlib-js/array-base-zero-to@2d3793c · GitHub
[go: up one dir, main page]

Skip to content

Commit 2d3793c

Browse files
committed
Auto-generated commit
1 parent 1e2dd82 commit 2d3793c

File tree

11 files changed

+306
-57
lines changed

11 files changed

+306
-57
lines changed

.editorconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ indent_style = tab
121121
[*.{md,md.txt}]
122122
indent_style = space
123123
indent_size = 4
124-
trim_trailing_whitespace = false
124+
trim_trailing_whitespace = true # Note: this disables using two spaces to force a hard line break, which is permitted in Markdown. As we don't typically follow that practice (TMK), we should be safe to automatically trim.
125125
126126
# Set properties for `usage.txt` files:
127127
[usage.txt]

.github/.keepalive

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
2024-12-30T02:23:29.490Z

.github/workflows/productionize.yml

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -94,8 +94,8 @@ jobs:
9494
node -e "var pkg = require( './package.json' ); pkg.dependencies[ '@stdlib/error-tools-fmtprodmsg' ] = '^$PKG_VERSION'; require( 'fs' ).writeFileSync( 'package.json', JSON.stringify( pkg, null, 2 ) );"
9595
fi
9696
97-
# Configure git:
98-
- name: 'Configure git'
97+
# Configure Git:
98+
- name: 'Configure Git'
9999
run: |
100100
git config --local user.email "noreply@stdlib.io"
101101
git config --local user.name "stdlib-bot"
@@ -191,8 +191,8 @@ jobs:
191191
# Pin action to full length commit SHA
192192
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0
193193

194-
# Configure git:
195-
- name: 'Configure git'
194+
# Configure Git:
195+
- name: 'Configure Git'
196196
run: |
197197
git config --local user.email "noreply@stdlib.io"
198198
git config --local user.name "stdlib-bot"
@@ -366,8 +366,8 @@ jobs:
366366
# Pin action to full length commit SHA
367367
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0
368368

369-
# Configure git:
370-
- name: 'Configure git'
369+
# Configure Git:
370+
- name: 'Configure Git'
371371
run: |
372372
git config --local user.email "noreply@stdlib.io"
373373
git config --local user.name "stdlib-bot"
@@ -539,8 +539,8 @@ jobs:
539539
# Pin action to full length commit SHA
540540
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0
541541

542-
# Configure git:
543-
- name: 'Configure git'
542+
# Configure Git:
543+
- name: 'Configure Git'
544544
run: |
545545
git config --local user.email "noreply@stdlib.io"
546546
git config --local user.name "stdlib-bot"
@@ -735,8 +735,8 @@ jobs:
735735
echo "bump=true" >> $GITHUB_OUTPUT
736736
fi
737737
738-
# Configure git:
739-
- name: 'Configure git'
738+
# Configure Git:
739+
- name: 'Configure Git'
740740
if: steps.check-if-bump.outputs.bump
741741
run: |
742742
git config --local user.email "noreply@stdlib.io"

.github/workflows/publish.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,8 @@ jobs:
7272
node-version: 20
7373
timeout-minutes: 5
7474

75-
# Configure git:
76-
- name: 'Configure git'
75+
# Configure Git:
76+
- name: 'Configure Git'
7777
run: |
7878
git config --local user.email "noreply@stdlib.io"
7979
git config --local user.name "stdlib-bot"
@@ -206,7 +206,7 @@ jobs:
206206
# Publish package to npm:
207207
- name: 'Publish package to npm'
208208
# Pin action to full length commit SHA
209-
uses: JS-DevTools/npm-publish@4b07b26a2f6e0a51846e1870223e545bae91c552 # v3.0.1
209+
uses: JS-DevTools/npm-publish@19c28f1ef146469e409470805ea4279d47c3d35c # v3.1.1
210210
with:
211211
token: ${{ secrets.NPM_TOKEN }}
212212
access: public

.github/workflows/test_install.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,8 @@ jobs:
5050
env:
5151
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
5252

53-
# Run workflow job if `publish` workflow run is successful or when the workflow is manually run:
54-
if: ${{ github.event.workflow_run.conclusion == 'success' || github.event_name == 'workflow_dispatch' }}
53+
# Run workflow job if `publish` workflow run is successful or when the workflow is manually triggered or on a schedule:
54+
if: ${{ github.event.workflow_run.conclusion == 'success' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' }}
5555

5656
# Define the sequence of job steps...
5757
steps:
Lines changed: 105 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,105 @@
1+
#/
2+
# @license Apache-2.0
3+
#
4+
# Copyright (c) 2024 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: test_published_package
21+
22+
# Workflow triggers:
23+
on:
24+
# Run workflow on a weekly schedule:
25+
schedule:
26+
# * is a special character in YAML so you have to quote this string
27+
- cron: '43 19 * * 3'
28+
29+
# Run workflow upon completion of `publish` workflow run:
30+
workflow_run:
31+
workflows: ["publish"]
32+
types: [completed]
33+
34+
# Allow workflow to be manually run:
35+
workflow_dispatch:
36+
37+
# Workflow jobs:
38+
jobs:
39+
test-published:
40+
# Define a display name:
41+
name: 'Test running examples of published package'
42+
43+
# Define the type of virtual host machine:
44+
runs-on: ubuntu-latest
45+
46+
# Define environment variables:
47+
env:
48+
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
49+
50+
# Run workflow job if `publish` workflow run is successful or when the workflow is manually triggered or on a schedule:
51+
if: ${{ github.event.workflow_run.conclusion == 'success' || github.event_name == 'workflow_dispatch' || github.event_name == 'schedule' }}
52+
53+
# Define the job's steps:
54+
steps:
55+
# Checkout the repository:
56+
- name: 'Checkout repository'
57+
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0
58+
59+
# Install Node.js:
60+
- name: 'Install Node.js'
61+
uses: actions/setup-node@b39b52d1213e96004bfcb1c61a8a6fa8ab84f3e8 # v4.0.1
62+
with:
63+
node-version: 20
64+
timeout-minutes: 5
65+
66+
# Create test directory and run examples:
67+
- name: 'Create test directory and run examples'
68+
run: |
69+
cd ..
70+
mkdir test-published
71+
cd test-published
72+
73+
# Copy example file:
74+
cp $GITHUB_WORKSPACE/examples/index.js .
75+
76+
# Create a minimal package.json
77+
echo '{
78+
"name": "test-published",
79+
"version": "1.0.0",
80+
"main": "index.js",
81+
"dependencies": {}
82+
}' > package.json
83+
84+
# Get package name and modify example file:
85+
PACKAGE_NAME=$(jq -r '.name' $GITHUB_WORKSPACE/package.json)
86+
ESCAPED_PACKAGE_NAME=$(echo "$PACKAGE_NAME" | sed 's/[\/&]/\\&/g')
87+
88+
sed -i "s/require( '.\/..\/lib' )/require( '$ESCAPED_PACKAGE_NAME' )/g" index.js
89+
90+
# Extract and install dependencies:
91+
DEPS=$(grep -oP "require\(\s*'([^']+)'\s*\)" index.js | sed "s/require(\s*'//" | sed "s/'\s*)//" | grep -v "^\.")
92+
for dep in $DEPS; do
93+
npm install $dep --save
94+
done
95+
96+
# Run the example:
97+
node index.js
98+
99+
# Send Slack notification if job fails:
100+
- name: 'Send notification to Slack in case of failure'
101+
uses: 8398a7/action-slack@28ba43ae48961b90635b50953d216767a6bea486 # v3.16.2
102+
with:
103+
status: ${{ job.status }}
104+
channel: '#npm-ci'
105+
if: failure()

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,8 @@ docs/**/node_modules/
101101
pids
102102
*.pid
103103
*.seed
104+
yarn.lock
105+
package-lock.json
104106

105107
# Typescript #
106108
##############

.npmrc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,5 +27,5 @@ shrinkwrap = false
2727
# Disable automatically "saving" dependencies on install:
2828
save = false
2929

30-
# Generate provenance metadata:
31-
provenance = true
30+
# Do not generate provenance metadata:
31+
provenance = false

CHANGELOG.md

Lines changed: 118 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
55
<section class="release" id="unreleased">
66

7-
## Unreleased (2024-07-17)
7+
## Unreleased (2024-12-30)
88

99
<section class="commits">
1010

@@ -16,7 +16,7 @@
1616
- [`8d4c46b`](https://github.com/stdlib-js/stdlib/commit/8d4c46b10ca912401e0ff0caa37a17cd3c443c2f) - **refactor:** update paths _(by Athan Reines)_
1717
- [`ed9c0a5`](https://github.com/stdlib-js/stdlib/commit/ed9c0a5e55ff09af3dd6af8c38615480e2c1828e) - **refactor:** update paths _(by Athan Reines)_
1818
- [`18b3c79`](https://github.com/stdlib-js/stdlib/commit/18b3c79c5035c7082618b7379cd6576e64393a96) - **refactor:** update paths _(by Athan Reines)_
19-
- [`ec98887`](https://github.com/stdlib-js/stdlib/commit/ec9888724c28aa7218d88ff62b91b71c0089c559) - **docs:** update related packages sections [(##2241)](#2241) _(by stdlib-bot)_
19+
- [`ec98887`](https://github.com/stdlib-js/stdlib/commit/ec9888724c28aa7218d88ff62b91b71c0089c559) - **docs:** update related packages sections [(#2241)](https://github.com/stdlib-js/stdlib/pull/2241) _(by stdlib-bot)_
2020

2121
</details>
2222

@@ -44,11 +44,65 @@ A total of 1 person contributed to this release. Thank you to this contributor:
4444

4545
## 0.2.1 (2024-02-25)
4646

47+
No changes reported for this release.
48+
49+
</section>
50+
51+
<!-- /.release -->
52+
53+
<section class="release" id="v0.2.0">
54+
55+
## 0.2.0 (2024-02-15)
56+
4757
<section class="features">
4858

4959
### Features
5060

5161
- [`5a9e3a2`](https://github.com/stdlib-js/stdlib/commit/5a9e3a2be378a79829489e2aba08affe51acbaf5) - add `assign` method
62+
63+
</section>
64+
65+
<!-- /.features -->
66+
67+
<section class="commits">
68+
69+
### Commits
70+
71+
<details>
72+
73+
- [`40b06c3`](https://github.com/stdlib-js/stdlib/commit/40b06c38ef5d19e312c34525b5ba7b2977efb0a2) - **refactor:** use `dtype` property rather than assertion API _(by Athan Reines)_
74+
- [`5a9e3a2`](https://github.com/stdlib-js/stdlib/commit/5a9e3a2be378a79829489e2aba08affe51acbaf5) - **feat:** add `assign` method _(by Athan Reines)_
75+
76+
</details>
77+
78+
</section>
79+
80+
<!-- /.commits -->
81+
82+
<section class="contributors">
83+
84+
### Contributors
85+
86+
A total of 1 person contributed to this release. Thank you to this contributor:
87+
88+
- Athan Reines
89+
90+
</section>
91+
92+
<!-- /.contributors -->
93+
94+
</section>
95+
96+
<!-- /.release -->
97+
98+
<section class="release" id="v0.1.0">
99+
100+
## 0.1.0 (2023-09-24)
101+
102+
<section class="features">
103+
104+
### Features
105+
52106
- [`e29732d`](https://github.com/stdlib-js/stdlib/commit/e29732dee616e2d94e91f87f78afd8aceb806017) - update minimum TypeScript version
53107

54108
</section>
@@ -59,8 +113,7 @@ A total of 1 person contributed to this release. Thank you to this contributor:
59113

60114
### BREAKING CHANGES
61115

62-
- [`e29732d`](https://github.com/stdlib-js/stdlib/commit/e29732dee616e2d94e91f87f78afd8aceb806017): update minimum TypeScript version
63-
- [`e29732d`](https://github.com/stdlib-js/stdlib/commit/e29732dee616e2d94e91f87f78afd8aceb806017): update minimum TypeScript version to 4.1
116+
- [`e29732d`](https://github.com/stdlib-js/stdlib/commit/e29732dee616e2d94e91f87f78afd8aceb806017): update minimum TypeScript version to 4.1
64117

65118
- To migrate, users should upgrade their TypeScript version to at least version 4.1.
66119

@@ -74,8 +127,6 @@ A total of 1 person contributed to this release. Thank you to this contributor:
74127

75128
<details>
76129

77-
- [`40b06c3`](https://github.com/stdlib-js/stdlib/commit/40b06c38ef5d19e312c34525b5ba7b2977efb0a2) - **refactor:** use `dtype` property rather than assertion API _(by Athan Reines)_
78-
- [`5a9e3a2`](https://github.com/stdlib-js/stdlib/commit/5a9e3a2be378a79829489e2aba08affe51acbaf5) - **feat:** add `assign` method _(by Athan Reines)_
79130
- [`e29732d`](https://github.com/stdlib-js/stdlib/commit/e29732dee616e2d94e91f87f78afd8aceb806017) - **feat:** update minimum TypeScript version _(by Philipp Burckhardt)_
80131

81132
</details>
@@ -88,9 +139,8 @@ A total of 1 person contributed to this release. Thank you to this contributor:
88139

89140
### Contributors
90141

91-
A total of 2 people contributed to this release. Thank you to the following contributors:
142+
A total of 1 person contributed to this release. Thank you to this contributor:
92143

93-
- Athan Reines
94144
- Philipp Burckhardt
95145

96146
</section>
@@ -101,3 +151,63 @@ A total of 2 people contributed to this release. Thank you to the following cont
101151

102152
<!-- /.release -->
103153

154+
<section class="release" id="v0.0.6">
155+
156+
## 0.0.6 (2023-02-03)
157+
158+
No changes reported for this release.
159+
160+
</section>
161+
162+
<!-- /.release -->
163+
164+
<section class="release" id="v0.0.5">
165+
166+
## 0.0.5 (2023-02-03)
167+
168+
No changes reported for this release.
169+
170+
</section>
171+
172+
<!-- /.release -->
173+
174+
<section class="release" id="v0.0.4">
175+
176+
## 0.0.4 (2023-02-03)
177+
178+
No changes reported for this release.
179+
180+
</section>
181+
182+
<!-- /.release -->
183+
184+
<section class="release" id="v0.0.3">
185+
186+
## 0.0.3 (2023-02-03)
187+
188+
No changes reported for this release.
189+
190+
</section>
191+
192+
<!-- /.release -->
193+
194+
<section class="release" id="v0.0.2">
195+
196+
## 0.0.2 (2023-02-03)
197+
198+
No changes reported for this release.
199+
200+
</section>
201+
202+
<!-- /.release -->
203+
204+
<section class="release" id="v0.0.1">
205+
206+
## 0.0.1 (2023-02-03)
207+
208+
No changes reported for this release.
209+
210+
</section>
211+
212+
<!-- /.release -->
213+

0 commit comments

Comments
 (0)
0