diff --git a/.eslintrc b/.eslintrc deleted file mode 100644 index a4201be..0000000 --- a/.eslintrc +++ /dev/null @@ -1,63 +0,0 @@ -{ - "env": { - "node": true, - "es6": true - }, - "parserOptions": { - "ecmaVersion": 6, - "sourceType": "module" - }, - "extends": [ - "eslint:recommended" - ], - "rules": { - "dot-notation": "error", - "eqeqeq": ["error", "smart"], - "indent": ["off", 4], - "keyword-spacing": "error", - "linebreak-style": ["error", "unix"], - "no-caller": "error", - "no-catch-shadow": "error", - "no-console": "warn", - "no-div-regex": "error", - "no-extend-native": "error", - "no-extra-bind": "error", - "no-floating-decimal": "error", - "no-implied-eval": "error", - "no-invalid-this": "error", - "no-iterator": "error", - "no-labels": "error", - "no-label-var": "error", - "no-lone-blocks": "error", - "no-loop-func": "error", - "no-multi-str": "error", - "no-native-reassign": "error", - "no-new": "error", - "no-new-func": "error", - "no-new-wrappers": "error", - "no-octal": "error", - "no-octal-escape": "error", - "no-process-env": "error", - "no-proto": "error", - "no-return-assign": "off", - "no-script-url": "error", - "no-self-compare": "error", - "no-sequences": "error", - "no-shadow": "off", - "no-shadow-restricted-names": "error", - "no-throw-literal": "error", - "no-unneeded-ternary": "error", - "no-unused-expressions": "error", - "no-unexpected-multiline": "error", - "no-unused-vars": "warn", - "no-void": "error", - "no-warning-comments": "warn", - "no-with": "error", - "no-use-before-define": ["off", "nofunc"], - "semi": ["error", "always"], - "semi-spacing": "error", - "space-unary-ops": "error", - "wrap-regex": "off", - "quotes": ["error", "single"] - } -} diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 5a60071..f2e7fae 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -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 diff --git a/.gitignore b/.gitignore index 347fc98..0b4b4b4 100644 --- a/.gitignore +++ b/.gitignore @@ -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 diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..6976ddb --- /dev/null +++ b/CONTRIBUTING.md @@ -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! diff --git a/README.md b/README.md index 082accc..12f451e 100644 --- a/README.md +++ b/README.md @@ -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 ` +