- Submitting a Bug/Feature Request
- Contributing Code
- Tests
- Running Benchmarks
- Merging Pull Requests
- Releasing
Bugs/Feature requests are always welcome. Make sure to follow the .github/ISSUE_TEMPLATE.md and submit them to Github Issues.
It is always best to submit a feature/bug request to make sure that what you see actually needs to be fixed/changed. That will save hurt feelings and wasted time.
Make sure that you have the following installed:
- fork the repo on github:
https://github.com/BrandonOCasey/npm-preset
- clone your fork:
https://github.com/<userName>/npm-preset
- move into that directory:
cd npm-preset
- create a branch to work in:
git checkout -b some-awesome-feature
- install dependencies:
npm i
- verify that unit tests/linter run and pass:
npm run test
- Make your changes, be sure to update/add unit tests accordingly
- Make sure that the unit tests/linter still pass:
npm run test
- Commit your changes:
git commit -m 'change' -a
- Push your changes up to your repo:
git push -u origin some-awesome-feature
- Open a pull request on Github
- Be sure to follow the .github/PULL_REQUEST_TEMPLATE.md
See https://github.com/videojs/eslint-config-videojs for our linting rules
Make sure that you have the following installed:
- clone the repo:
git clone https://github.com/BrandonOCasey/npm-preset
- move into that directory:
cd npm-preset
- install dependencies:
npm i
- run the test setup:
npm run test-setup
- move into the playground directory: 'cd test/fixtures/playground'
- test npmp with
npmp echo
Make sure that you have the following installed:
- clone the repo:
git clone https://github.com/BrandonOCasey/npm-preset
- move into that directory:
cd npm-preset
- install dependencies:
npm i
- run the tests:
npm run test
Note: We use ava for our unit tests. See their docs for other ways to run tests
Note: We use ava for our unit tests. See their docs for other ways to run tests FYI: all of these steps return a Promise and run asyncronously
- Before any tests start unit tests are started by running the script in
test/scripts/setup.js
- This emulates an
npm-link
onnpm-preset
for all directories intest/fixtures/*
. We do not use acuallynpm link
because it takes too long. - mainly unit tests are concerned with the
test/fixtures/unit-tests
directory
- Before each test is run we copy
test/fixtures/unit-tests
to a temporary directory - Tests do whatever they need to in that temporary directory
- Wether that tests passes or fails the temporary directory is then deleted
To view the most recent benchmarks look at BENCHMARKS.md
Make sure that you have the following installed:
- clone the repo:
git clone https://github.com/BrandonOCasey/npm-preset
- move into that directory:
cd npm-preset
- install dependencies:
npm i
- run the benchmarks:
npm run bench
Once code has been reviewed it should be squashed and merged
and the commit should follow our commit guidelines
so that a changelog can automatically be generated during a release.
- If this release is only bug fixes it is a patch
- If this release contains any features it is a minor
- if this release contains any breaking changes it is a major
Travis will handle the github release and the npm publish on a tag. All you have to do is:
- version with npm:
npm version <versiontype>
- push changes to git:
git push
- push tags to git:
git push --tags