diff --git a/.github/workflows/changelog-check.yml b/.github/workflows/changelog-check.yml new file mode 100644 index 00000000..0d727705 --- /dev/null +++ b/.github/workflows/changelog-check.yml @@ -0,0 +1,26 @@ +name: Changelog in sync for packages + +on: + push: + branches: + - master + pull_request: + +jobs: + test: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v1 + + - name: Setup Node.js 12.x + uses: actions/setup-node@v1 + with: + node-version: 12.x + + - name: Install and run changelog check + run: | + npm ci + npm run changelog:check + env: + CI: true diff --git a/package.json b/package.json index 9d6c66d6..c59c9954 100644 --- a/package.json +++ b/package.json @@ -100,6 +100,7 @@ "test:other": "npm run prettier -- --list-different", "test:typecheck": "tsc", "test:update": "npm run test:app -- --updateSnapshot --watchAll=false", - "test": "npm run test:app" + "test": "npm run test:app", + "changelog:check": "node ./scripts/changelog-check.js" } } diff --git a/scripts/changelog-check.js b/scripts/changelog-check.js new file mode 100644 index 00000000..33d6dfdc --- /dev/null +++ b/scripts/changelog-check.js @@ -0,0 +1,34 @@ +const { exec } = require("child_process"); + +const changeLogCheck = () => { + exec( + "git diff origin/master --cached --name-only", + (error, stdout, stderr) => { + if (error || stderr) { + process.exit(1); + } + + if (!stdout || stdout.includes("packages/excalidraw/CHANGELOG.MD")) { + process.exit(0); + } + + const onlyNonSrcFilesUpdated = stdout.indexOf("src") < 0; + if (onlyNonSrcFilesUpdated) { + process.exit(0); + } + + const changedFiles = stdout.trim().split("\n"); + const filesToIgnoreRegex = /src\/excalidraw-app|packages\/utils/; + + const excalidrawPackageFiles = changedFiles.filter((file) => { + return file.indexOf("src") >= 0 && !filesToIgnoreRegex.test(file); + }); + + if (excalidrawPackageFiles.length) { + process.exit(1); + } + process.exit(0); + }, + ); +}; +changeLogCheck(); diff --git a/src/packages/excalidraw/CHANGELOG.MD b/src/packages/excalidraw/CHANGELOG.MD index 6f1d57ab..0d90d834 100644 --- a/src/packages/excalidraw/CHANGELOG.MD +++ b/src/packages/excalidraw/CHANGELOG.MD @@ -1,10 +1,41 @@ # Changelog + -## 0.1.0 +## [Unreleased] -First release of `@excalidraw/excalidraw` +### Features +- Insert Library items in the middle of the screen [#2527](https://github.com/excalidraw/excalidraw/pull/2527) +- Show shortcut context menu [#2501](https://github.com/excalidraw/excalidraw/pull/2501) +- Aligns arrowhead schemas [#2517](https://github.com/excalidraw/excalidraw/pull/2517) +- Add Cut to menus [#2511](https://github.com/excalidraw/excalidraw/pull/2511) +- More Arrowheads: dot, bar [#2486](https://github.com/excalidraw/excalidraw/pull/2486) +- Support CSV graphs and improve the look and feel [#2495](https://github.com/excalidraw/excalidraw/pull/2495) + +### Fixes +- Fix Library Menu Layout [#2502](https://github.com/excalidraw/excalidraw/pull/2502) + +### Improvements +- RTL support for the stats dialog [#2530](https://github.com/excalidraw/excalidraw/pull/2530) +- Expand canvas padding based on zoom. [#2515](https://github.com/excalidraw/excalidraw/pull/2515) +- Hide shortcuts on pickers for mobile [#2508](https://github.com/excalidraw/excalidraw/pull/2508) +- Hide stats and scrollToContent-button when mobile menus open [#2509](https://github.com/excalidraw/excalidraw/pull/2509) + +### Chore +- Bump ini from 1.3.5 to 1.3.7 in /src/packages/excalidraw [#2500](https://github.com/excalidraw/excalidraw/pull/2500) ## 0.1.1 #### Fix - Update the homepage URL so it redirects to correct readme [#2498](https://github.com/excalidraw/excalidraw/pull/2498) + +## 0.1.0 + +First release of `@excalidraw/excalidraw`