Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
63 changes: 0 additions & 63 deletions .eslintrc

This file was deleted.

17 changes: 10 additions & 7 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,16 @@ jobs:
strategy:
fail-fast: false
matrix:
node-version: ['18', '20', '22']
bun-version: ['1.3']

steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
- uses: actions/checkout@v5
- name: Use Bun ${{ matrix.bun-version }}
uses: oven-sh/setup-bun@v2
with:
node-version: ${{ matrix.node-version }}
- run: npm install
- run: npm run all
bun-version: ${{ matrix.bun-version }}
- run: bun install
- run: |
echo "::remove-matcher owner=eslint-compact::"
echo "::remove-matcher owner=eslint-stylish::"
- run: bun run all
13 changes: 4 additions & 9 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,14 +1,9 @@
/coverage
/dist
/node_modules

.DS_Store
.esm-cache
.vscode
.coverage

.nyc_output/
built/
coverage/
dist/
node_modules/

npm-debug.log
lerna-debug.log
package-lock.json
Expand Down
31 changes: 31 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# Contributing

This project uses **GitHub** to track issues and manage our source code.
- Check out the [Git Guides](https://github.com/git-guides) to learn more.

This project uses the **JavaScript** programming language.
- [MDN's JavaScript guide](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide) is a great resource for learning about JavaScript.

This project uses the **TypeScript** programming language.
- Check out the [TypeScript Docs](https://www.typescriptlang.org/docs/) to learn more.
- (It's a superset of JavaScript, so knowing that already will help you a lot).

This project uses **Bun** as our development environment.
- Check out the [Bun Docs](https://bun.com/docs) to learn more.
- (It's similar to other JavaScript tools like Node/Jest/Esbuild/Vite, so knowing any of those already will help you a lot).
- Bun supports both JavaScript and TypeScript.

If you want to contribute to node-diff3, you'll probably need to:
- [Install Bun](https://bun.com/docs/installation)
- `git clone` node-diff3
- `cd` into the project folder
- `bun install` the dependencies

As you change things, you'll want to `bun run all` to ensure that things are working.
(This command just runs `clean`, `lint`, `build`, and `test`.)

It's also good to check on the dependencies sometimes with commands like:
- `bun outdated` - what packages have updates available?
- `bun update --interactive` - choose which updates to apply

Try to keep things simple!
8 changes: 7 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ You can also use **node-diff3** directly in a web browser. A good way to do thi
When you load this file in a `<script>` tag, you'll get a `Diff3` global to use elsewhere in your scripts:
```html
<head>
<script src="https://cdn.jsdelivr.net/npm/node-diff3@3.1/dist/index.iife.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/node-diff3@3.1/dist/diff3.iife.min.js"></script>
</head>
<script>
Expand All @@ -54,6 +54,12 @@ When you load this file in a `<script>` tag, you'll get a `Diff3` global to use

&nbsp;

## Contributing

See the [CONTRIBUTING.md](CONTRIBUTING.md) file for more info.

&nbsp;

## API Reference

* [3-way diff and merging](#3-way-diff-and-merging)
Expand Down
32 changes: 20 additions & 12 deletions RELEASE.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,26 @@
## Release Checklist

#### Update version, tag, and publish

```bash
$ git checkout main
$ npm install
$ npm run test
$ Update CHANGELOG
$ Update version number in `package.json`
$ git add .
$ git commit -m 'vA.B.C'
$ git tag vA.B.C
$ git push origin main vA.B.C
$ npm publish
# Make sure your main branch is up to date and all tests pass
git checkout main
git pull origin
bun install
bun run all

# Pick a version, see https://semver.org/ - for example: 'A.B.C' or 'A.B.C-pre.D'
# Update version number in `package.json`
# Update CHANGELOG.md

export VERSION=vA.B.C-pre.D
git add . && git commit -m "$VERSION"
git tag "$VERSION"
git push origin main "$VERSION"
bun publish
```
* Open https://github.com/bhousel/node-diff3/tags
* Click "Add Release Notes" and link to the CHANGELOG#version

Set as latest release on GitHub:
- Open https://github.com/bhousel/node-diff3/blob/main/CHANGELOG.md and copy the URL to the new release
- Open https://github.com/bhousel/node-diff3/tags and pick the new tag you just pushed
- There should be a link like "create a release from the tag", click that, and paste in the link to the changelog.
Loading