8000 Auto-generated commit · stdlib-js/utils-async-count-by@43d4dd4 · GitHub
[go: up one dir, main page]

Skip to content

Commit 43d4dd4

Browse files
committed
Auto-generated commit
1 parent aa84178 commit 43d4dd4

File tree

12 files changed

+33
-32
lines changed

12 files changed

+33
-32
lines changed

.github/.keepalive

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2022-03-16T08:16:21.723Z
1+
2022-04-01T01:32:50.238Z

.github/workflows/benchmark.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
benchmark:
2929
runs-on: ubuntu-latest
3030
steps:
31-
- uses: actions/checkout@v2
31+
- uses: actions/checkout@v3
3232
- uses: actions/setup-node@v2
3333
with:
3434
node-version: 16

.github/workflows/bundle.yml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -25,15 +25,15 @@ on:
2525
push:
2626
branches:
2727
- main
28-
tags_ignore:
28+
tags-ignore:
2929
- 'v[0-9]+\.[0-9]+\.[0-9]+'
3030

3131
# Workflow jobs:
3232
jobs:
3333
deno:
3434
runs-on: ubuntu-latest
3535
steps:
36-
- uses: actions/checkout@v2
36+
- uses: actions/checkout@v3
3737
- name: Copy files to deno directory
3838
run: |
3939
mkdir -p deno
@@ -92,7 +92,7 @@ jobs:
9292
github_token: ${{ secrets.GITHUB_TOKEN }}
9393
publish_dir: ./deno
9494
publish_branch: deno
95-
keep_files: true
95+
force_orphan: true
9696
user_name: 'stdlib-bot'
9797
user_email: 'noreply@stdlib.io'
9898
commit_message: 'Auto-generated commit'
@@ -107,7 +107,7 @@ jobs:
107107
umd:
108108
runs-on: ubuntu-latest
109109
steps:
110-
- uses: actions/checkout@v2
110+
- uses: actions/checkout@v3
111111
- name: Copy files to umd directory
112112
run: |
113113
mkdir -p umd
@@ -153,7 +153,7 @@ jobs:
153153
find ./umd -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "1 while s/<script type=\"text\/javascript\">\n(var|let|const)\s+([a-zA-Z0-9_]+)\s+=\s*require\( '\@stdlib\/([^']+)' \);?/<script type=\"text\/javascript\" src=\"https:\/\/cdn.jsdelivr.net\/gh\/stdlib-js\/\3\@umd\/bundle.js\"><\/script>\n<script type=\"text\/javascript\">/g"
154154
155155
# Wrap contents of `<script type="text/javascript">` tag contents in an IIFE:
156-
find ./umd -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/<script type=\"text\/javascript\">([\s\S]+?)<\/script>/<script type=\"text\/javascript\">\n\(function \(\) {\1}\)\(\)\n<\/script>/g"
156+
find ./umd -type f -name '*.md' -print0 | xargs -0 perl -0777 -i -pe "s/<script type=\"text\/javascript\">([\s\S]+?)<\/script>/<script type=\"text\/javascript\">\n\(function \(\) {\1}\)\(\);\n<\/script>/g"
157157
158158
# Create package.json file for umd branch:
159159
jq --indent 2 '{"name": .name, "version": .version, "description": .description, "license": .license, "main": "./bundle.js", "homepage": .homepage, "repository": .repository, "bugs": .bugs, "keywords": .keywords, "funding": .funding}' package.json > ./umd/package.json
@@ -164,7 +164,7 @@ jobs:
164164
github_token: ${{ secrets.GITHUB_TOKEN }}
165165
publish_dir: ./umd
166166
publish_branch: umd
167-
keep_files: true
167+
force_orphan: true
168168
user_name: 'stdlib-bot'
169169
user_email: 'noreply@stdlib.io'
170170
commit_message: 'Auto-generated commit'
@@ -179,7 +179,7 @@ jobs:
179179
esm:
180180
runs-on: ubuntu-latest
181181
steps:
182-
- uses: actions/checkout@v2
182+
- uses: actions/checkout@v3
183183
- name: Copy files to umd directory
184184
run: |
185185
mkdir -p esm
@@ -242,7 +242,7 @@ jobs:
242242
github_token: ${{ secrets.GITHUB_TOKEN }}
243243
publish_dir: ./esm
244244
publish_branch: esm
245-
keep_files: true
245+
force_orphan: true
246246
user_name: 'stdlib-bot'
247247
user_email: 'noreply@stdlib.io'
248248
commit_message: 'Auto-generated commit'

.github/workflows/cancel.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
#/
1818

1919
# Workflow name:
20-
name: Cancel Workflow Runs
20+
name: cancel
2121

2222
# Workflow triggers:
2323
on:

.github/workflows/examples.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
examples:
2929
runs-on: ubuntu-latest
3030
steps:
31-
- uses: actions/checkout@v2
31+
- uses: actions/checkout@v3
3232
- uses: actions/setup-node@v2
3333
with:
3434
node-version: 16

.github/workflows/publish.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
#/
1818

1919
# Workflow name:
20-
name: Publish Package
20+
name: publish
2121

2222
# Workflow triggers:
2323
on:
@@ -31,7 +31,7 @@ jobs:
3131
env:
3232
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
3333
steps:
34-
- uses: actions/checkout@v2
34+
- uses: actions/checkout@v3
3535
- uses: actions/setup-node@v2
3636
with:
3737
node-version: 16
@@ -63,7 +63,7 @@ jobs:
6363
runs-on: ubuntu-latest
6464
steps:
6565
- name: Checkout main branch
66-
uses: actions/checkout@v2
66+
uses: actions/checkout@v3
6767
with:
6868
ref: main
6969
- name: Increment version in `package.json` to the version number of the tag

.github/workflows/test.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
#/
1818

1919
# Workflow name:
20-
name: build
20+
name: test
2121

2222
# Workflow triggers:
2323
on:
@@ -34,7 +34,7 @@ jobs:
3434
env:
3535
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
3636
steps:
37-
- uses: actions/checkout@v2
37+
- uses: actions/checkout@v3
3838
- uses: actions/setup-node@v2
3939
with:
4040
node-version: 16

.github/workflows/test_bundles.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,12 @@
1717
#/
1818

1919
# Workflow name:
20-
name: Test Loading Bundles
20+
name: test_bundles
2121

2222
# Workflow triggers:
2323
on:
2424
workflow_run:
25-
workflows: ["bundle"]
25+
workflows: ["test"]
2626
types: [completed]
2727
workflow_dispatch:
2828

@@ -34,7 +34,7 @@ jobs:
3434
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
3535
steps:
3636
- name: Checkout branch with UMD build
37-
uses: actions/checkout@v2
37+
uses: actions/checkout@v3
3838
with:
3939
ref: umd
4040
- name: Setup Node.js
@@ -57,7 +57,7 @@ jobs:
5757
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
5858
steps:
5959
- name: Checkout branch with ESM build
60-
uses: actions/checkout@v2
60+
uses: actions/checkout@v3
6161
with:
6262
ref: esm
6363
- name: Setup Node.js
@@ -80,7 +80,7 @@ jobs:
8080
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
8181
steps:
8282
- name: Checkout branch with Deno build
83-
uses: actions/checkout@v2
83+
uses: actions/checkout@v3
8484
with:
8585
ref: deno
8686
- name: Install Deno

.github/workflows/test_coverage.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,12 @@
1717
#/
1818

1919
# Workflow name:
20-
name: coverage
20+
name: test_coverage
2121

2222
# Workflow triggers:
2323
on:
2424
workflow_run:
25-
workflows: ["build"]
25+
workflows: ["test"]
2626
types: [completed]
2727
workflow_dispatch:
2828

@@ -31,7 +31,7 @@ jobs:
3131
test:
3232
runs-on: ubuntu-latest
3333
steps:
34-
- uses: actions/checkout@v2
34+
- uses: actions/checkout@v3
3535
- uses: actions/setup-node@v2
3636
with:
3737
node-version: 16

.github/workflows/test_install.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,15 +17,15 @@
1717
#/
1818

1919
# Workflow name:
20-
name: Test Installing Dependencies
20+
name: test_install
2121

2222
# Workflow triggers:
2323
on:
2424
schedule:
2525
# * is a special character in YAML so you have to quote this string
2626
- cron: '30 1 * * 6'
2727
workflow_run:
28-
workflows: ["Publish Package"]
28+
workflows: ["publish"]
2929
types: [completed]
3030
workflow_dispatch:
3131

@@ -37,7 +37,7 @@ jobs:
3737
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
3838
if: ${{ github.event.workflow_run.conclusion == 'success' || github.event_name == 'workflow_dispatch' }}
3939
steps:
40-
- uses: actions/checkout@v2
40+
- uses: actions/checkout@v3
4141
- uses: actions/setup-node@v2
4242
with:
4343
node-version: 16

lib/factory.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222

2323
var isFunction = require( '@stdlib/assert-is-function' );
2424
var isCollection = require( '@stdlib/assert-is-collection' );
25+
var format = require( '@stdlib/string-format' );
2526
var PINF = require( '@stdlib/constants-float64-pinf' );
2627
var validate = require( './validate.js' );
2728
var limit = require( './limit.js' );
@@ -104,7 +105,7 @@ function factory( options, indicator ) {
104105
f = options;
105106
}
106107
if ( !isFunction( f ) ) {
107-
throw new TypeError( 'invalid argument. Last argument must be a function. Value: `'+f+'`.' );
108+
throw new TypeError( format( 'invalid argument. Last argument must be a function. Value: `%s`.', f ) );
108109
}
109110
if ( opts.series ) {
110111
opts.limit = 1;
@@ -125,10 +126,10 @@ function factory( options, indicator ) {
125126
*/
126127
function countByAsync( collection, done ) {
127128
if ( !isCollection( collection ) ) {
128-
throw new TypeError( 'invalid argument. First argument must be a collection. Value: `'+collection+'.`' );
129+
throw new TypeError( format( 'invalid argument. First argument must be a collection. Value: `%s`.', collection ) );
129130
}
130131
if ( !isFunction( done ) ) {
131-
throw new TypeError( 'invalid argument. Last argument must be a function. Value: `'+done+'`.' );
132+
throw new TypeError( format( 'invalid argument. Last argument must be a function. Value: `%s`.', done ) );
132133
}
133134
return limit( collection, opts, f, clbk );
134135

lib/validate.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ function validate( opts, options ) {
6262
if ( hasOwnProp( options, 'series' ) ) {
6363
opts.series = options.series;
6464
if ( !isBoolean( opts.series ) ) {
65-
return new TypeError( format( 'invalid option. `%s` option must be a boolean primitive. Option: `%s`.', 'series', opts.series ) );
65+
return new TypeError( format( 'invalid option. `%s` option must be a boolean. Option: `%s`.', 'series', opts.series ) );
6666
}
6767
}
6868
if ( hasOwnProp( options, 'limit' ) ) {

0 commit comments

Comments
 (0)
0