@ehmicky/dev-tasks
Automated development tasks for my own projects
Last updated 2 years ago by ehmicky .
Apache-2.0 · Repository · Bugs · Original npm · Tarball · package.json
$ npm install @ehmicky/dev-tasks 
SYNC missed versions from official npm registry.

Node Browsers Mastodon Medium

Automated development tasks (linting, testing, building) for JavaScript/TypeScript code (Node.js and/or browsers).

This is used in my own projects. This is not meant to be shared and semantic versioning is not followed.

The task runner is Gulp, but you don't need to know Gulp to use these tasks.

Also, Docker must be installed globally and executable by the current user without sudo.

Hire me

Please reach out if you're looking for a Node.js API or CLI engineer (11 years of experience). Most recently I have been Netlify Build's and Netlify Plugins' technical lead for 2.5 years. I am available for full-time remote positions.

Workflow

Code is compiled from the src to the build directory using Babel, so you can use the latest JavaScript features.

Linting and formatting are performed with ESLint, Prettier, Jscpd and lychee. We recommend using plugins with your IDE (code editor) for both Prettier and ESLint so that linting/formatting is performed as you code.

We use Ava to run tests. Each line of code must be tested.

We use tsd to test TypeScript types. Each export must be fully typed using either TypeScript regular files (*.ts) or ambient files (*.d.ts).

Usage

Any task can be run using gulp for example:

gulp build

If you're on cmd.exe (Windows) use npx gulp ... instead.

Overview

The main commands are:

  • gulp build: build source files and test files. Must be run before running any code or unit tests.
  • gulp check: lint/format the JavaScript and TypeScript files.
  • gulp type: run TypeScript type tests.
  • gulp unit: run unit tests.
  • gulp test: perform all of the above tasks.

Use gulp buildWatch, gulp checkWatch, gulp typeWatch, and gulp unitWatch to run them in watch mode.

GitHub actions ensures that:

  • tests pass on all supported environments.
  • all source files are covered by tests and follow the same coding style.

Available tasks

gulp build

Build source files and test files:

  • JavaScript and TypeScript files are transpiled with Babel.
  • Other files are copied as is.

Source files and test files are built from the src directory to the build/src directory.

This must be done before linting or running any code or unit tests.

To add TypeScript types, use either:

  • Regular TypeScript files (*.ts). An ambient file is automatically created by tsc --declaration.
  • JavaScript files (*.js) and ambient files (*.d.ts). Ambient files are copied as is.

gulp check

Lint and check source files:

gulp type

Run TypeScript type tests with tsd. The type tests must be named *.test-d.ts.

gulp unit

Run unit tests with Ava. The test files must be named *.test.js.

To specify Ava options, please call ava directly instead. For example: ava --update-snapshots.

To target a single test file, use ava build/test/file.test.js not ava test/file.test.js.

gulp test

Runs gulp build then gulp check then gulp type and gulp unit.

This is performed on CI (GitHub actions) for each OS (Windows, Mac, Linux) and supported Node.js version.

gulp buildWatch, gulp checkWatch, gulp typeWatch, gulp unitWatch, gulp warnWatch

Like gulp build, gulp check, gulp type, gulp unit and gulp warn but in watch mode. The watch mode works even when installing/updating/uninstalling dependencies or changing the Gulp tasks themselves.

They can be performed together, e.g. gulp buildWatch in one terminal tab and gulp unitWatch in another.

Other tasks

gulp links

Detect dead links with lychee.

gulp warn

Check for security vulnerabilities (using npm audit) and outdated dependencies (using npm outdated).

gulp releasePatch, gulp releaseMinor, gulp releaseMajor

Release a new patch/minor/major version on npm and GitHub using release-it.

npm publish must be performed locally afterwards.

Only the repository owner can perform these tasks.

gulp unitCoverage

Like gulp unit but also compute test coverage.

Custom tasks

Repositories with a gulp top-level directory have additional tasks. Please check those files to see which custom tasks are available.

Support

For any question, don't hesitate to submit an issue on GitHub.

Everyone is welcome regardless of personal background. We enforce a Code of conduct in order to promote a positive and inclusive environment.

Contributing

This project was made with ❤️. The simplest way to give back is by starring and sharing it online.

If the documentation is unclear or has a typo, please click on the page's Edit button (pencil icon) and suggest a correction.

If you would like to help us fix a bug, please check our guidelines. Pull requests are welcome!

Current Tags

  • 3.0.25                                ...           latest (13 days ago)

400 Versions

  • 3.0.25                                ...           13 days ago
  • 3.0.24                                ...           14 days ago
  • 3.0.23                                ...           14 days ago
  • 3.0.22                                ...           14 days ago
  • 3.0.21                                ...           14 days ago
  • 3.0.20                                ...           15 days ago
  • 3.0.19                                ...           15 days ago
  • 3.0.18                                ...           15 days ago
  • 3.0.17                                ...           16 days ago
  • 3.0.16                                ...           16 days ago
  • 3.0.15                                ...           17 days ago
  • 3.0.14                                ...           17 days ago
  • 3.0.13                                ...           17 days ago
  • 3.0.12                                ...           18 days ago
  • 3.0.11                                ...           2 months ago
  • 3.0.10                                ...           2 months ago
  • 3.0.9                                ...           3 months ago
  • 3.0.8                                ...           3 months ago
  • 3.0.7                                ...           3 months ago
  • 3.0.6                                ...           3 months ago
  • 3.0.5                                ...           4 months ago
  • 3.0.4                                ...           5 months ago
  • 3.0.3                                ...           5 months ago
  • 3.0.2                                ...           5 months ago
  • 3.0.1                                ...           5 months ago
  • 3.0.0                                ...           5 months ago
  • 2.0.134                                ...           5 months ago
  • 2.0.133                                ...           5 months ago
  • 2.0.132                                ...           5 months ago
  • 2.0.131                                ...           5 months ago
  • 2.0.130                                ...           5 months ago
  • 2.0.129                                ...           5 months ago
  • 2.0.128                                ...           5 months ago
  • 2.0.127                                ...           5 months ago
  • 2.0.126                                ...           5 months ago
  • 2.0.125                                ...           5 months ago
  • 2.0.124                                ...           5 months ago
  • 2.0.123                                ...           5 months ago
  • 2.0.122                                ...           5 months ago
  • 2.0.121                                ...           5 months ago
  • 2.0.120                                ...           5 months ago
  • 2.0.119                                ...           5 months ago
  • 2.0.118                                ...           5 months ago
  • 2.0.117                                ...           5 months ago
  • 2.0.116                                ...           5 months ago
  • 2.0.115                                ...           5 months ago
  • 2.0.114                                ...           5 months ago
  • 2.0.113                                ...           5 months ago
  • 2.0.112                                ...           5 months ago
  • 2.0.111                                ...           6 months ago
  • 2.0.110                                ...           6 months ago
  • 2.0.109                                ...           6 months ago
  • 2.0.108                                ...           6 months ago
  • 2.0.107                                ...           6 months ago
  • 2.0.106                                ...           6 months ago
  • 2.0.105                                ...           7 months ago
  • 2.0.104                                ...           9 months ago
  • 2.0.103                                ...           a year ago
  • 2.0.102                                ...           a year ago
  • 2.0.101                                ...           a year ago
  • 2.0.100                                ...           a year ago
  • 2.0.99                                ...           a year ago
  • 2.0.98                                ...           a year ago
  • 2.0.97                                ...           a year ago
  • 2.0.96                                ...           a year ago
  • 2.0.95                                ...           a year ago
  • 2.0.94                                ...           a year ago
  • 2.0.93                                ...           a year ago
  • 2.0.92                                ...           a year ago
  • 2.0.91                                ...           a year ago
  • 2.0.90                                ...           a year ago
  • 2.0.89                                ...           a year ago
  • 2.0.88                                ...           a year ago
  • 2.0.87                                ...           a year ago
  • 2.0.86                                ...           a year ago
  • 2.0.85                                ...           a year ago
  • 2.0.84                                ...           a year ago
  • 2.0.83                                ...           a year ago
  • 2.0.82                                ...           a year ago
  • 2.0.81                                ...           2 years ago
  • 2.0.80                                ...           2 years ago
  • 2.0.79                                ...           2 years ago
  • 2.0.77                                ...           2 years ago
  • 2.0.76                                ...           2 years ago
  • 2.0.75                                ...           2 years ago
  • 2.0.74                                ...           2 years ago
  • 2.0.73                                ...           2 years ago
  • 2.0.72                                ...           2 years ago
  • 2.0.71                                ...           2 years ago
  • 2.0.70                                ...           2 years ago
  • 2.0.69                                ...           2 years ago
  • 2.0.68                                ...           2 years ago
  • 2.0.67                                ...           2 years ago
  • 2.0.66                                ...           2 years ago
  • 2.0.65                                ...           2 years ago
  • 2.0.64                                ...           2 years ago
  • 2.0.63                                ...           2 years ago
  • 2.0.62                                ...           2 years ago
  • 2.0.61                                ...           2 years ago
  • 2.0.60                                ...           2 years ago
  • 2.0.59                                ...           2 years ago
  • 2.0.58                                ...           2 years ago
  • 2.0.57                                ...           2 years ago
  • 2.0.56                                ...           2 years ago
  • 2.0.55                                ...           2 years ago
  • 2.0.54                                ...           2 years ago
  • 2.0.53                                ...           2 years ago
  • 2.0.52                                ...           2 years ago
  • 2.0.51                                ...           2 years ago
  • 2.0.50                                ...           2 years ago
  • 2.0.49                                ...           2 years ago
  • 2.0.48                                ...           2 years ago
  • 2.0.47                                ...           2 years ago
  • 2.0.46                                ...           2 years ago
  • 2.0.45                                ...           2 years ago
  • 2.0.44                                ...           2 years ago
  • 2.0.43                                ...           2 years ago
  • 2.0.42                                ...           2 years ago
  • 2.0.41                                ...           2 years ago
  • 2.0.40                                ...           2 years ago
  • 2.0.39                                ...           2 years ago
  • 2.0.38                                ...           2 years ago
  • 2.0.37                                ...           2 years ago
  • 2.0.36                                ...           2 years ago
  • 2.0.35                                ...           2 years ago
  • 2.0.34                                ...           2 years ago
  • 2.0.33                                ...           2 years ago
  • 2.0.32                                ...           2 years ago
  • 2.0.31                                ...           2 years ago
  • 2.0.30                                ...           2 years ago
  • 2.0.29                                ...           2 years ago
  • 2.0.28                                ...           2 years ago
  • 2.0.27                                ...           2 years ago
  • 2.0.25                                ...           2 years ago
  • 2.0.24                                ...           2 years ago
  • 2.0.23                                ...           2 years ago
  • 2.0.22                                ...           2 years ago
  • 2.0.21                                ...           2 years ago
  • 2.0.20                                ...           2 years ago
  • 2.0.19                                ...           2 years ago
  • 2.0.18                                ...           2 years ago
  • 2.0.17                                ...           2 years ago
  • 2.0.16                                ...           2 years ago
  • 2.0.15                                ...           2 years ago
  • 2.0.14                                ...           2 years ago
  • 2.0.13                                ...           2 years ago
  • 2.0.12                                ...           2 years ago
  • 2.0.11                                ...           2 years ago
  • 2.0.10                                ...           2 years ago
  • 2.0.9                                ...           2 years ago
  • 2.0.8                                ...           2 years ago
  • 2.0.7                                ...           2 years ago
  • 2.0.6                                ...           2 years ago
  • 2.0.5                                ...           2 years ago
  • 2.0.4                                ...           2 years ago
  • 2.0.3                                ...           2 years ago
  • 2.0.2                                ...           2 years ago
  • 2.0.1                                ...           2 years ago
  • 2.0.0                                ...           2 years ago
  • 1.0.143                                ...           2 years ago
  • 1.0.142                                ...           2 years ago
  • 1.0.141                                ...           2 years ago
  • 1.0.140                                ...           2 years ago
  • 1.0.139                                ...           2 years ago
  • 1.0.133                                ...           2 years ago
  • 1.0.132                                ...           2 years ago
  • 1.0.121                                ...           2 years ago
  • 1.0.115                                ...           2 years ago
  • 1.0.114                                ...           2 years ago
  • 1.0.113                                ...           2 years ago
  • 1.0.112                                ...           2 years ago
  • 1.0.111                                ...           2 years ago
  • 1.0.110                                ...           2 years ago
  • 1.0.109                                ...           2 years ago
  • 1.0.108                                ...           2 years ago
  • 1.0.107                                ...           2 years ago
  • 1.0.106                                ...           2 years ago
  • 1.0.105                                ...           2 years ago
  • 1.0.104                                ...           2 years ago
  • 1.0.103                                ...           2 years ago
  • 1.0.102                                ...           2 years ago
  • 1.0.101                                ...           2 years ago
  • 1.0.100                                ...           2 years ago
  • 1.0.99                                ...           2 years ago
  • 1.0.98                                ...           2 years ago
  • 1.0.97                                ...           2 years ago
  • 1.0.96                                ...           2 years ago
  • 1.0.95                                ...           2 years ago
  • 1.0.94                                ...           2 years ago
  • 1.0.93                                ...           2 years ago
  • 1.0.92                                ...           2 years ago
  • 1.0.91                                ...           2 years ago
  • 1.0.90                                ...           2 years ago
  • 1.0.89                                ...           2 years ago
  • 1.0.88                                ...           2 years ago
  • 1.0.87                                ...           2 years ago
  • 1.0.86                                ...           2 years ago
  • 1.0.85                                ...           2 years ago
  • 1.0.84                                ...           2 years ago
  • 1.0.83                                ...           2 years ago
  • 1.0.82                                ...           2 years ago
  • 1.0.81                                ...           2 years ago
  • 1.0.80                                ...           2 years ago
  • 1.0.79                                ...           2 years ago
  • 1.0.78                                ...           2 years ago
  • 1.0.77                                ...           2 years ago
  • 1.0.76                                ...           2 years ago
  • 1.0.75                                ...           2 years ago
  • 1.0.74                                ...           2 years ago
  • 1.0.73                                ...           3 years ago
  • 1.0.72                                ...           3 years ago
  • 1.0.71                                ...           3 years ago
  • 1.0.70                                ...           3 years ago
  • 1.0.69                                ...           3 years ago
  • 1.0.68                                ...           3 years ago
  • 1.0.67                                ...           3 years ago
  • 1.0.66                                ...           3 years ago
  • 1.0.65                                ...           3 years ago
  • 1.0.64                                ...           3 years ago
  • 1.0.63                                ...           3 years ago
  • 1.0.62                                ...           3 years ago
  • 1.0.61                                ...           3 years ago
  • 1.0.60                                ...           3 years ago
  • 1.0.59                                ...           3 years ago
  • 1.0.58                                ...           3 years ago
  • 1.0.57                                ...           3 years ago
  • 1.0.56                                ...           3 years ago
  • 1.0.55                                ...           3 years ago
  • 1.0.54                                ...           3 years ago
  • 1.0.53                                ...           3 years ago
  • 1.0.52                                ...           3 years ago
  • 1.0.51                                ...           3 years ago
  • 1.0.50                                ...           3 years ago
  • 1.0.49                                ...           3 years ago
  • 1.0.48                                ...           3 years ago
  • 1.0.47                                ...           3 years ago
  • 1.0.46                                ...           3 years ago
  • 1.0.45                                ...           3 years ago
  • 1.0.44                                ...           3 years ago
  • 1.0.43                                ...           3 years ago
  • 1.0.42                                ...           3 years ago
  • 1.0.41                                ...           3 years ago
  • 1.0.40                                ...           3 years ago
  • 1.0.39                                ...           3 years ago
  • 1.0.38                                ...           3 years ago
  • 1.0.37                                ...           3 years ago
  • 1.0.36                                ...           3 years ago
  • 1.0.35                                ...           3 years ago
  • 1.0.34                                ...           3 years ago
  • 1.0.33                                ...           3 years ago
  • 1.0.30                                ...           3 years ago
  • 1.0.29                                ...           3 years ago
  • 1.0.28                                ...           3 years ago
  • 1.0.27                                ...           3 years ago
  • 1.0.26                                ...           3 years ago
  • 1.0.25                                ...           3 years ago
  • 1.0.24                                ...           3 years ago
  • 1.0.23                                ...           3 years ago
  • 1.0.22                                ...           3 years ago
  • 1.0.21                                ...           3 years ago
  • 1.0.20                                ...           3 years ago
  • 1.0.19                                ...           3 years ago
  • 1.0.18                                ...           3 years ago
  • 1.0.17                                ...           3 years ago
  • 1.0.16                                ...           3 years ago
  • 1.0.15                                ...           3 years ago
  • 1.0.14                                ...           3 years ago
  • 1.0.13                                ...           3 years ago
  • 1.0.12                                ...           3 years ago
  • 1.0.11                                ...           3 years ago
  • 1.0.10                                ...           3 years ago
  • 1.0.9                                ...           3 years ago
  • 1.0.8                                ...           3 years ago
  • 1.0.7                                ...           3 years ago
  • 1.0.6                                ...           3 years ago
  • 1.0.5                                ...           3 years ago
  • 1.0.4                                ...           3 years ago
  • 1.0.3                                ...           3 years ago
  • 1.0.2                                ...           3 years ago
  • 1.0.1                                ...           3 years ago
  • 1.0.0                                ...           3 years ago
  • 0.31.92                                ...           3 years ago
  • 0.31.91                                ...           3 years ago
  • 0.31.90                                ...           3 years ago
  • 0.31.89                                ...           4 years ago
  • 0.31.88                                ...           4 years ago
  • 0.31.87                                ...           4 years ago
  • 0.31.86                                ...           4 years ago
  • 0.31.85                                ...           4 years ago
  • 0.31.84                                ...           4 years ago
  • 0.31.83                                ...           4 years ago
  • 0.31.82                                ...           4 years ago
  • 0.31.81                                ...           4 years ago
  • 0.31.80                                ...           4 years ago
  • 0.31.79                                ...           4 years ago
  • 0.31.78                                ...           4 years ago
  • 0.31.77                                ...           4 years ago
  • 0.31.76                                ...           4 years ago
  • 0.31.75                                ...           4 years ago
  • 0.31.74                                ...           4 years ago
  • 0.31.73                                ...           4 years ago
  • 0.31.72                                ...           4 years ago
  • 0.31.71                                ...           4 years ago
  • 0.31.70                                ...           4 years ago
  • 0.31.69                                ...           4 years ago
  • 0.31.68                                ...           4 years ago
  • 0.31.67                                ...           4 years ago
  • 0.31.66                                ...           4 years ago
  • 0.31.65                                ...           4 years ago
  • 0.31.64                                ...           4 years ago
  • 0.31.63                                ...           4 years ago
  • 0.31.62                                ...           4 years ago
  • 0.31.61                                ...           4 years ago
  • 0.31.60                                ...           4 years ago
  • 0.31.59                                ...           4 years ago
  • 0.31.57                                ...           4 years ago
  • 0.31.56                                ...           4 years ago
  • 0.31.55                                ...           4 years ago
  • 0.31.54                                ...           4 years ago
  • 0.31.53                                ...           4 years ago
  • 0.31.52                                ...           4 years ago
  • 0.31.51                                ...           4 years ago
  • 0.31.50                                ...           4 years ago
  • 0.31.49                                ...           4 years ago
  • 0.31.48                                ...           4 years ago
  • 0.31.47                                ...           4 years ago
  • 0.31.46                                ...           4 years ago
  • 0.31.45                                ...           4 years ago
  • 0.31.44                                ...           5 years ago
  • 0.31.43                                ...           5 years ago
  • 0.31.42                                ...           5 years ago
  • 0.31.41                                ...           5 years ago
  • 0.31.40                                ...           5 years ago
  • 0.31.39                                ...           5 years ago
  • 0.31.38                                ...           5 years ago
  • 0.31.37                                ...           5 years ago
  • 0.31.36                                ...           5 years ago
  • 0.31.35                                ...           5 years ago
  • 0.31.34                                ...           5 years ago
  • 0.31.33                                ...           5 years ago
  • 0.31.32                                ...           5 years ago
  • 0.31.31                                ...           5 years ago
  • 0.31.30                                ...           5 years ago
  • 0.31.29                                ...           5 years ago
  • 0.31.28                                ...           5 years ago
  • 0.31.27                                ...           5 years ago
  • 0.31.26                                ...           5 years ago
  • 0.31.25                                ...           5 years ago
  • 0.31.24                                ...           5 years ago
  • 0.31.23                                ...           5 years ago
  • 0.31.22                                ...           5 years ago
  • 0.31.21                                ...           5 years ago
  • 0.31.15                                ...           5 years ago
  • 0.31.14                                ...           5 years ago
  • 0.31.13                                ...           5 years ago
  • 0.31.12                                ...           5 years ago
  • 0.31.11                                ...           5 years ago
  • 0.31.10                                ...           5 years ago
  • 0.31.9                                ...           5 years ago
  • 0.31.8                                ...           5 years ago
  • 0.31.7                                ...           5 years ago
  • 0.31.6                                ...           5 years ago
  • 0.31.5                                ...           5 years ago
  • 0.31.4                                ...           5 years ago
  • 0.31.3                                ...           5 years ago
  • 0.31.2                                ...           5 years ago
  • 0.31.1                                ...           5 years ago
  • 0.31.0                                ...           5 years ago
  • 0.30.71                                ...           5 years ago
  • 0.30.70                                ...           5 years ago
  • 0.30.69                                ...           5 years ago
  • 0.30.68                                ...           5 years ago
  • 0.30.67                                ...           5 years ago
  • 0.30.66                                ...           5 years ago
  • 0.30.65                                ...           5 years ago
  • 0.30.64                                ...           5 years ago
  • 0.30.63                                ...           5 years ago
  • 0.30.62                                ...           5 years ago
  • 0.30.61                                ...           5 years ago
  • 0.30.60                                ...           5 years ago
  • 0.30.59                                ...           5 years ago
  • 0.30.58                                ...           5 years ago
  • 0.30.57                                ...           5 years ago
  • 0.30.56                                ...           5 years ago
  • 0.30.55                                ...           5 years ago
  • 0.30.54                                ...           5 years ago
  • 0.30.53                                ...           5 years ago
  • 0.30.52                                ...           5 years ago
  • 0.30.51                                ...           5 years ago
  • 0.30.50                                ...           5 years ago
  • 0.30.49                                ...           5 years ago
  • 0.30.48                                ...           5 years ago
  • 0.30.47                                ...           5 years ago
  • 0.30.46                                ...           5 years ago
  • 0.30.45                                ...           5 years ago
  • 0.30.44                                ...           5 years ago
  • 0.30.43                                ...           5 years ago
  • 0.30.42                                ...           5 years ago
  • 0.30.41                                ...           5 years ago
  • 0.30.40                                ...           5 years ago
Maintainers (1)
Downloads
Total 0
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (26)
Dev Dependencies (0)
None
Dependents (0)
None

© 2010 - cnpmjs.org x YWFE | Home | YWFE