Skip to content

Commit 5be1a93

Browse files
authored
Merge pull request #94 from DanilKazanov/patch-1
Update snippets.md
2 parents 07cf1c4 + a570ff5 commit 5be1a93

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

docs/snippets.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,11 @@ All snippets are published under the MIT License.
1919
```js
2020
const globby = require('globby');
2121
const paths = await globby(['./**', './**/.*'], { gitignore: true });
22-
for (const filepath of paths) {
23-
await git.add({ fs, dir, filepath });
24-
}
22+
await Promise.all(
23+
paths.map(async (filepath) => {
24+
await git.add({ fs, dir, filepath });
25+
})
26+
);
2527
```
2628

2729
## git add -A .

0 commit comments

Comments
 (0)