Skip to content

Commit

Permalink
fix: drop Node 8 support (#20)
Browse files Browse the repository at this point in the history
BREAKING CHANGE: Please upgrade to Node 10 or later
  • Loading branch information
kentcdodds committed Jan 28, 2020
1 parent 1e15c4a commit 1ed0f33
Show file tree
Hide file tree
Showing 8 changed files with 105 additions and 121 deletions.
6 changes: 4 additions & 2 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,9 @@ merge of your pull request!

- [ ] Documentation
- [ ] Tests
- [ ] Ready to be merged <!-- In your opinion, is this ready to be merged as soon as it's reviewed? -->
- [ ] Added myself to contributors table <!-- this is optional, see the contributing guidelines for instructions -->
- [ ] Ready to be merged
<!-- In your opinion, is this ready to be merged as soon as it's reviewed? -->
- [ ] Added myself to contributors table
<!-- this is optional, see the contributing guidelines for instructions -->

<!-- feel free to add additional comments -->
5 changes: 3 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# CHANGELOG

The changelog is automatically updated using [semantic-release](https://github.com/semantic-release/semantic-release).
You can see it on the [releases page](../../releases).
The changelog is automatically updated using
[semantic-release](https://github.com/semantic-release/semantic-release). You
can see it on the [releases page](../../releases).
51 changes: 9 additions & 42 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

Thanks for being willing to contribute!

**Working on your first Pull Request?** You can learn how from this _free_ series
[How to Contribute to an Open Source Project on GitHub][egghead]
**Working on your first Pull Request?** You can learn how from this _free_
series [How to Contribute to an Open Source Project on GitHub][egghead]

## Project setup

Expand All @@ -20,45 +20,11 @@ Thanks for being willing to contribute!
> git branch --set-upstream-to=upstream/master master
> ```
>
> This will add the original repository as a "remote" called "upstream,"
> Then fetch the git information from that remote, then set your local `master`
> branch to use the upstream master branch whenever you run `git pull`.
> Then you can make all of your pull request branches based on this `master`
> branch. Whenever you want to update your version of `master`, do a regular
> `git pull`.
## Add yourself as a contributor

This project follows the [all contributors][all-contributors] specification.
To add yourself to the table of contributors on the `README.md`, please use the
automated script as part of your PR:

```console
npm run add-contributor
```

Follow the prompt and commit `.all-contributorsrc` and `README.md` in the PR.
If you've already added yourself to the list and are making
a new type of contribution, you can run it again and select the added
contribution type.

## Committing and Pushing changes

Please make sure to run the tests before you commit your changes. You can run
`npm run test:update` which will update any snapshots that need updating.
Make sure to include those changes (if they exist) in your commit.

### opt into git hooks

There are git hooks set up with this project that are automatically installed
when you install dependencies. They're really handy, but are turned off by
default (so as to not hinder new contributors). You can opt into these by
creating a file called `.opt-in` at the root of the project and putting this
inside:

```
pre-commit
```
> This will add the original repository as a "remote" called "upstream," Then
> fetch the git information from that remote, then set your local `master`
> branch to use the upstream master branch whenever you run `git pull`. Then you
> can make all of your pull request branches based on this `master` branch.
> Whenever you want to update your version of `master`, do a regular `git pull`.
## Help needed

Expand All @@ -67,6 +33,7 @@ Please checkout the [the open issues][issues]
Also, please watch the repo and respond to questions/bug reports/feature
requests! Thanks!

[egghead]: https://egghead.io/series/how-to-contribute-to-an-open-source-project-on-github
[egghead]:
https://egghead.io/series/how-to-contribute-to-an-open-source-project-on-github
[all-contributors]: https://github.com/kentcdodds/all-contributors
[issues]: https://github.com/kentcdodds/netlify-shortener/issues
42 changes: 24 additions & 18 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,8 @@ a custom function for your shell.
#!/usr/bin/env node
require('netlify-shortener')
```
3. From your project directory, run the following to register the command globally:
3. From your project directory, run the following to register the command
globally:
```sh
npm link
```
Expand All @@ -152,7 +153,8 @@ function shorten --description "Shorten a URL"
end
```

(Alternatively, run `funced -s shorten` and Fish will open your editor. Paste this code into the opened file.)
(Alternatively, run `funced -s shorten` and Fish will open your editor. Paste
this code into the opened file.)

### Windows (cmd)

Expand Down Expand Up @@ -193,7 +195,8 @@ this for and now you can use it too!

## Other Solutions

- [netlify-shortener-sh](https://github.com/caarlos0/netlify-shortener-sh): plain shell script version
- [netlify-shortener-sh](https://github.com/caarlos0/netlify-shortener-sh):
plain shell script version

If you know more alternatives, please [make a pull request][prs] and add it
here!
Expand Down Expand Up @@ -231,27 +234,30 @@ MIT

[npm]: https://www.npmjs.com/
[node]: https://nodejs.org
[build-badge]: https://img.shields.io/travis/kentcdodds/netlify-shortener.svg?style=flat-square
[build-badge]:
https://img.shields.io/travis/kentcdodds/netlify-shortener.svg?style=flat-square
[build]: https://travis-ci.org/kentcdodds/netlify-shortener
[coverage-badge]: https://img.shields.io/codecov/c/github/kentcdodds/netlify-shortener.svg?style=flat-square
[coverage-badge]:
https://img.shields.io/codecov/c/github/kentcdodds/netlify-shortener.svg?style=flat-square
[coverage]: https://codecov.io/github/kentcdodds/netlify-shortener
[version-badge]: https://img.shields.io/npm/v/netlify-shortener.svg?style=flat-square
[version-badge]:
https://img.shields.io/npm/v/netlify-shortener.svg?style=flat-square
[package]: https://www.npmjs.com/package/netlify-shortener
[downloads-badge]: https://img.shields.io/npm/dm/netlify-shortener.svg?style=flat-square
[downloads-badge]:
https://img.shields.io/npm/dm/netlify-shortener.svg?style=flat-square
[npmtrends]: http://www.npmtrends.com/netlify-shortener
[license-badge]: https://img.shields.io/npm/l/netlify-shortener.svg?style=flat-square
[license-badge]:
https://img.shields.io/npm/l/netlify-shortener.svg?style=flat-square
[license]: https://github.com/kentcdodds/netlify-shortener/blob/master/LICENSE
[prs-badge]: https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square
[prs-badge]:
https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square
[prs]: http://makeapullrequest.com
[donate-badge]: https://img.shields.io/badge/$-support-green.svg?style=flat-square
[coc-badge]: https://img.shields.io/badge/code%20of-conduct-ff69b4.svg?style=flat-square
[coc]: https://github.com/kentcdodds/netlify-shortener/blob/master/other/CODE_OF_CONDUCT.md
[github-watch-badge]: https://img.shields.io/github/watchers/kentcdodds/netlify-shortener.svg?style=social
[github-watch]: https://github.com/kentcdodds/netlify-shortener/watchers
[github-star-badge]: https://img.shields.io/github/stars/kentcdodds/netlify-shortener.svg?style=social
[github-star]: https://github.com/kentcdodds/netlify-shortener/stargazers
[twitter]: https://twitter.com/intent/tweet?text=Check%20out%20netlify-shortener%20by%20%40kentcdodds%20https%3A%2F%2Fgithub.com%2Fkentcdodds%2Fnetlify-shortener%20%F0%9F%91%8D
[twitter-badge]: https://img.shields.io/twitter/url/https/github.com/kentcdodds/netlify-shortener.svg?style=social
[donate-badge]:
https://img.shields.io/badge/$-support-green.svg?style=flat-square
[coc-badge]:
https://img.shields.io/badge/code%20of-conduct-ff69b4.svg?style=flat-square
[coc]:
https://github.com/kentcdodds/netlify-shortener/blob/master/other/CODE_OF_CONDUCT.md
[emojis]: https://github.com/kentcdodds/all-contributors#emoji-key
[all-contributors]: https://github.com/kentcdodds/all-contributors
[npm-bin]: https://docs.npmjs.com/files/package.json#bin
25 changes: 13 additions & 12 deletions other/CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
In the interest of fostering an open and welcoming environment, we as
contributors and maintainers pledge to making participation in our project and
our community a harassment-free experience for everyone, regardless of age, body
size, disability, ethnicity, gender identity and expression, level of experience,
nationality, personal appearance, race, religion, or sexual identity and
orientation.
size, disability, ethnicity, gender identity and expression, level of
experience, nationality, personal appearance, race, religion, or sexual identity
and orientation.

## Our Standards

Expand Down Expand Up @@ -37,11 +37,11 @@ Project maintainers are responsible for clarifying the standards of acceptable
behavior and are expected to take appropriate and fair corrective action in
response to any instances of unacceptable behavior.

Project maintainers have the right and responsibility to remove, edit, or
reject comments, commits, code, wiki edits, issues, and other contributions
that are not aligned to this Code of Conduct, or to ban temporarily or
permanently any contributor for other behaviors that they deem inappropriate,
threatening, offensive, or harmful.
Project maintainers have the right and responsibility to remove, edit, or reject
comments, commits, code, wiki edits, issues, and other contributions that are
not aligned to this Code of Conduct, or to ban temporarily or permanently any
contributor for other behaviors that they deem inappropriate, threatening,
offensive, or harmful.

## Scope

Expand All @@ -58,17 +58,18 @@ Instances of abusive, harassing, or otherwise unacceptable behavior may be
reported by contacting the project team at kent+coc@doddsfamily.us. All
complaints will be reviewed and investigated and will result in a response that
is deemed necessary and appropriate to the circumstances. The project team is
obligated to maintain confidentiality with regard to the reporter of an incident.
Further details of specific enforcement policies may be posted separately.
obligated to maintain confidentiality with regard to the reporter of an
incident. Further details of specific enforcement policies may be posted
separately.

Project maintainers who do not follow or enforce the Code of Conduct in good
faith may face temporary or permanent repercussions as determined by other
members of the project's leadership.

## Attribution

This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
available at [http://contributor-covenant.org/version/1/4][version]
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
version 1.4, available at [http://contributor-covenant.org/version/1/4][version]

[homepage]: http://contributor-covenant.org
[version]: http://contributor-covenant.org/version/1/4/
77 changes: 42 additions & 35 deletions other/MAINTAINING.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,60 +4,67 @@ This is documentation for maintainers of this project.

## Code of Conduct

Please review, understand, and be an example of it. Violations of the code of conduct are
taken seriously, even (especially) for maintainers.
Please review, understand, and be an example of it. Violations of the code of
conduct are taken seriously, even (especially) for maintainers.

## Issues

We want to support and build the community. We do that best by helping people learn to solve
their own problems. We have an issue template and hopefully most folks follow it. If it's
not clear what the issue is, invite them to create a minimal reproduction of what they're trying
to accomplish or the bug they think they've found.
We want to support and build the community. We do that best by helping people
learn to solve their own problems. We have an issue template and hopefully most
folks follow it. If it's not clear what the issue is, invite them to create a
minimal reproduction of what they're trying to accomplish or the bug they think
they've found.

Once it's determined that a code change is necessary, point people to
[makeapullrequest.com](http://makeapullrequest.com) and invite them to make a pull request.
If they're the one who needs the feature, they're the one who can build it. If they need
some hand holding and you have time to lend a hand, please do so. It's an investment into
another human being, and an investment into a potential maintainer.
[makeapullrequest.com](http://makeapullrequest.com) and invite them to make a
pull request. If they're the one who needs the feature, they're the one who can
build it. If they need some hand holding and you have time to lend a hand,
please do so. It's an investment into another human being, and an investment
into a potential maintainer.

Remember that this is open source, so the code is not yours, it's ours. If someone needs a change
in the codebase, you don't have to make it happen yourself. Commit as much time to the project
as you want/need to. Nobody can ask any more of you than that.
Remember that this is open source, so the code is not yours, it's ours. If
someone needs a change in the codebase, you don't have to make it happen
yourself. Commit as much time to the project as you want/need to. Nobody can ask
any more of you than that.

## Pull Requests

As a maintainer, you're fine to make your branches on the main repo or on your own fork. Either
way is fine.
As a maintainer, you're fine to make your branches on the main repo or on your
own fork. Either way is fine.

When we receive a pull request, a travis build is kicked off automatically (see the `.travis.yml`
for what runs in the travis build). We avoid merging anything that breaks the travis build.
When we receive a pull request, a travis build is kicked off automatically (see
the `.travis.yml` for what runs in the travis build). We avoid merging anything
that breaks the travis build.

Please review PRs and focus on the code rather than the individual. You never know when this is
someone's first ever PR and we want their experience to be as positive as possible, so be
uplifting and constructive.
Please review PRs and focus on the code rather than the individual. You never
know when this is someone's first ever PR and we want their experience to be as
positive as possible, so be uplifting and constructive.

When you merge the pull request, 99% of the time you should use the
[Squash and merge](https://help.github.com/articles/merging-a-pull-request/) feature. This keeps
our git history clean, but more importantly, this allows us to make any necessary changes to the
commit message so we release what we want to release. See the next section on Releases for more
about that.
[Squash and merge](https://help.github.com/articles/merging-a-pull-request/)
feature. This keeps our git history clean, but more importantly, this allows us
to make any necessary changes to the commit message so we release what we want
to release. See the next section on Releases for more about that.

## Release

Our releases are automatic. They happen whenever code lands into `master`. A travis build gets
kicked off and if it's successful, a tool called
[`semantic-release`](https://github.com/semantic-release/semantic-release) is used to
automatically publish a new release to npm as well as a changelog to GitHub. It is only able to
determine the version and whether a release is necessary by the git commit messages. With this
in mind, **please brush up on [the commit message convention][commit] which drives our releases.**
Our releases are automatic. They happen whenever code lands into `master`. A
travis build gets kicked off and if it's successful, a tool called
[`semantic-release`](https://github.com/semantic-release/semantic-release) is
used to automatically publish a new release to npm as well as a changelog to
GitHub. It is only able to determine the version and whether a release is
necessary by the git commit messages. With this in mind, **please brush up on
[the commit message convention][commit] which drives our releases.**

> One important note about this: Please make sure that commit messages do NOT contain the words
> "BREAKING CHANGE" in them unless we want to push a major version. I've been burned by this
> more than once where someone will include "BREAKING CHANGE: None" and it will end up releasing
> a new major version. Not a huge deal honestly, but kind of annoying...
> One important note about this: Please make sure that commit messages do NOT
> contain the words "BREAKING CHANGE" in them unless we want to push a major
> version. I've been burned by this more than once where someone will include
> "BREAKING CHANGE: None" and it will end up releasing a new major version. Not
> a huge deal honestly, but kind of annoying...
## Thanks!

Thank you so much for helping to maintain this project!

[commit]: https://github.com/conventional-changelog-archived-repos/conventional-changelog-angular/blob/ed32559941719a130bb0327f886d6a32a8cbc2ba/convention.md
[commit]:
https://github.com/conventional-changelog-archived-repos/conventional-changelog-angular/blob/ed32559941719a130bb0327f886d6a32a8cbc2ba/convention.md
9 changes: 5 additions & 4 deletions other/manual-releases.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
# manual-releases

This project has an automated release set up. So things are only released when there are
useful changes in the code that justify a release. But sometimes things get messed up one way or another
and we need to trigger the release ourselves. When this happens, simply bump the number below and commit
that with the following commit message based on your needs:
This project has an automated release set up. So things are only released when
there are useful changes in the code that justify a release. But sometimes
things get messed up one way or another and we need to trigger the release
ourselves. When this happens, simply bump the number below and commit that with
the following commit message based on your needs:

**Major**

Expand Down
11 changes: 5 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,10 @@
"netlify-shortener": "./dist/index.js"
},
"engines": {
"node": ">=8",
"node": ">=10",
"npm": ">=6"
},
"scripts": {
"add-contributor": "kcd-scripts contributors add",
"build": "kcd-scripts build",
"lint": "kcd-scripts lint",
"test": "kcd-scripts test",
Expand All @@ -26,12 +25,12 @@
"author": "Kent C. Dodds <kent@doddsfamily.us> (http://kentcdodds.com/)",
"license": "MIT",
"dependencies": {
"@babel/runtime": "^7.2.0",
"clipboardy": "^1.2.3",
"read-pkg-up": "^4.0.0"
"@babel/runtime": "^7.8.3",
"clipboardy": "^2.1.0",
"read-pkg-up": "^7.0.1"
},
"devDependencies": {
"kcd-scripts": "^0.47.0"
"kcd-scripts": "^4.1.0"
},
"husky": {
"hooks": {
Expand Down

0 comments on commit 1ed0f33

Please sign in to comment.