Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
136 commits
Select commit Hold shift + click to select a range
1c1dd44
Bump dependabot/fetch-metadata from 2.0.0 to 2.1.0
dependabot[bot] Apr 29, 2024
570624f
Merge pull request #301 from microsoftgraph/dependabot/github_actions…
github-actions[bot] Apr 29, 2024
52c1e5d
Bump @typescript-eslint/parser from 7.7.1 to 7.8.0
dependabot[bot] Apr 29, 2024
5e2d03f
Merge pull request #302 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Apr 29, 2024
22bc009
Bump @octokit/openapi-types from 22.1.0 to 22.2.0
dependabot[bot] May 6, 2024
aab0906
Merge pull request #304 from microsoftgraph/dependabot/npm_and_yarn/o…
github-actions[bot] May 6, 2024
fafe47b
Bump @typescript-eslint/eslint-plugin from 7.7.1 to 7.8.0
dependabot[bot] May 6, 2024
a904224
Merge pull request #303 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] May 6, 2024
1274840
Bump @typescript-eslint/parser from 7.8.0 to 7.9.0
dependabot[bot] May 13, 2024
a0420fc
Merge pull request #305 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] May 13, 2024
98b59e7
- updates code of conduct to the latest standard
baywet May 17, 2024
d2ee57b
Merge pull request #307 from baywet/main
jasonjoh May 17, 2024
67a817d
Bump @typescript-eslint/eslint-plugin from 7.8.0 to 7.9.0
dependabot[bot] May 17, 2024
20a38f7
Merge pull request #306 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] May 17, 2024
f360e87
dependabot[bot] May 20, 2024
6103afa
Merge pull request #308 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] May 20, 2024
c7b8e7e
Bump @typescript-eslint/parser from 7.9.0 to 7.11.0
dependabot[bot] May 27, 2024
aeb0ad9
Bump ts-jest from 29.1.2 to 29.1.3
dependabot[bot] May 27, 2024
421da07
Merge pull request #310 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] May 27, 2024
e5d782e
Merge pull request #311 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] May 27, 2024
a1ccc4a
Bump ts-jest from 29.1.3 to 29.1.4
dependabot[bot] Jun 3, 2024
c9d09c7
Merge pull request #313 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jun 3, 2024
da17f2e
Bump @typescript-eslint/parser from 7.11.0 to 7.12.0
dependabot[bot] Jun 3, 2024
179987f
Merge pull request #316 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jun 3, 2024
6b51e2b
Bump @typescript-eslint/parser from 7.12.0 to 7.13.0
dependabot[bot] Jun 10, 2024
3ba09d0
Merge pull request #317 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jun 10, 2024
ea31eca
Bump prettier from 3.2.5 to 3.3.1
dependabot[bot] Jun 10, 2024
0bb561c
Merge pull request #319 from microsoftgraph/dependabot/npm_and_yarn/p…
github-actions[bot] Jun 10, 2024
cc0aeb7
Bump @typescript-eslint/eslint-plugin from 7.10.0 to 7.13.0
dependabot[bot] Jun 10, 2024
f302af9
Merge pull request #318 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jun 10, 2024
3758a86
Bump braces from 3.0.2 to 3.0.3
dependabot[bot] Jun 16, 2024
57d8fa2
Merge pull request #320 from microsoftgraph/dependabot/npm_and_yarn/b…
github-actions[bot] Jun 16, 2024
dbe7c0e
Bump @typescript-eslint/eslint-plugin from 7.13.0 to 7.13.1
dependabot[bot] Jun 17, 2024
0ece7c6
Bump ts-jest from 29.1.4 to 29.1.5
dependabot[bot] Jun 17, 2024
26f023e
Merge pull request #321 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jun 17, 2024
dd5de6d
Merge pull request #322 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jun 17, 2024
c4c573d
Bump prettier from 3.3.1 to 3.3.2
dependabot[bot] Jun 17, 2024
bd91f5e
Merge pull request #323 from microsoftgraph/dependabot/npm_and_yarn/p…
github-actions[bot] Jun 17, 2024
6c334bb
Bump @typescript-eslint/parser from 7.13.0 to 7.13.1
dependabot[bot] Jun 17, 2024
a0edd2b
Merge pull request #324 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jun 17, 2024
4c151ba
Bump @typescript-eslint/eslint-plugin from 7.13.1 to 7.14.1
dependabot[bot] Jun 24, 2024
a16b63f
Merge pull request #326 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jun 24, 2024
156b8aa
Bump typescript from 5.4.5 to 5.5.2
dependabot[bot] Jun 24, 2024
178bdf6
Merge pull request #328 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jun 24, 2024
4e95ffc
Bump @typescript-eslint/parser from 7.13.1 to 7.14.1
dependabot[bot] Jun 24, 2024
055bfd7
Merge pull request #329 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jun 24, 2024
537257a
Bump typescript from 5.5.2 to 5.5.3
dependabot[bot] Jul 1, 2024
21eb1d5
Bump @typescript-eslint/eslint-plugin from 7.14.1 to 7.15.0
dependabot[bot] Jul 1, 2024
1036ff4
Merge pull request #330 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jul 1, 2024
51c6f62
Bump minimatch from 9.0.4 to 9.0.5
dependabot[bot] Jul 1, 2024
c933849
Merge pull request #331 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jul 1, 2024
29c1885
Merge pull request #332 from microsoftgraph/dependabot/npm_and_yarn/m…
github-actions[bot] Jul 1, 2024
a2e5e68
Bump @typescript-eslint/parser from 7.14.1 to 7.15.0
dependabot[bot] Jul 1, 2024
875fa64
Merge pull request #333 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jul 1, 2024
ee2e135
Bump @typescript-eslint/parser from 7.15.0 to 7.16.0
dependabot[bot] Jul 8, 2024
a5e9bd2
Bump ts-jest from 29.1.5 to 29.2.0
dependabot[bot] Jul 8, 2024
f97cbd8
Merge pull request #334 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jul 8, 2024
6b320ea
Merge pull request #335 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jul 8, 2024
b9b5dca
Bump dependabot/fetch-metadata from 2.1.0 to 2.2.0
dependabot[bot] Jul 8, 2024
e62a110
Merge pull request #338 from microsoftgraph/dependabot/github_actions…
github-actions[bot] Jul 8, 2024
63bfefd
Bump @typescript-eslint/eslint-plugin from 7.15.0 to 7.16.1
dependabot[bot] Jul 15, 2024
f3c2524
Bump ts-jest from 29.2.0 to 29.2.2
dependabot[bot] Jul 15, 2024
c06575b
Merge pull request #339 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jul 15, 2024
4e5c8ea
Merge pull request #340 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jul 15, 2024
7144f2f
Bump ts-jest from 29.2.2 to 29.2.3
dependabot[bot] Jul 22, 2024
1b06138
Bump @typescript-eslint/parser from 7.16.0 to 7.17.0
dependabot[bot] Jul 22, 2024
650eb5c
Merge pull request #345 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jul 22, 2024
bd3a1de
Merge pull request #346 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jul 22, 2024
f7f88be
Bump prettier from 3.3.2 to 3.3.3
dependabot[bot] Jul 22, 2024
d486b53
Merge pull request #342 from microsoftgraph/dependabot/npm_and_yarn/p…
github-actions[bot] Jul 22, 2024
5db8f21
Bump @typescript-eslint/eslint-plugin from 7.16.1 to 7.17.0
dependabot[bot] Jul 22, 2024
bebcc0c
Merge pull request #347 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jul 22, 2024
eb4c07b
Bump @typescript-eslint/parser from 7.17.0 to 7.18.0
dependabot[bot] Jul 29, 2024
660103e
Bump typescript from 5.5.3 to 5.5.4
dependabot[bot] Jul 29, 2024
2471079
Merge pull request #349 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jul 29, 2024
64b1414
Merge pull request #350 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Jul 29, 2024
70fdac3
Bump ts-jest from 29.2.3 to 29.2.4
dependabot[bot] Aug 5, 2024
3e52312
Merge pull request #353 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Aug 5, 2024
1b1ad81
Bump ts-jest from 29.2.4 to 29.2.5
dependabot[bot] Aug 26, 2024
aedf774
Merge pull request #361 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Aug 26, 2024
d686d31
Bump eslint from 8.57.0 to 8.57.1
dependabot[bot] Sep 16, 2024
ba423b1
Merge pull request #366 from microsoftgraph/dependabot/npm_and_yarn/e…
github-actions[bot] Sep 16, 2024
9cdd7e1
Bump typescript from 5.5.4 to 5.6.2
dependabot[bot] Sep 16, 2024
850d10d
Merge pull request #365 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Sep 16, 2024
fb71d6f
Bump @vercel/ncc from 0.38.1 to 0.38.2
dependabot[bot] Sep 23, 2024
1905d88
Merge pull request #368 from microsoftgraph/dependabot/npm_and_yarn/v…
github-actions[bot] Sep 23, 2024
f17cf50
Bump anothrNick/github-tag-action from 1.69.0 to 1.71.0
dependabot[bot] Sep 23, 2024
f57d48d
Merge pull request #371 from microsoftgraph/dependabot/github_actions…
github-actions[bot] Sep 23, 2024
123f980
Bump @actions/core from 1.10.1 to 1.11.1
dependabot[bot] Oct 7, 2024
71a356e
Bump @octokit/webhooks-types from 7.5.1 to 7.6.1
dependabot[bot] Oct 7, 2024
fbdbe81
Merge pull request #374 from microsoftgraph/dependabot/npm_and_yarn/a…
github-actions[bot] Oct 7, 2024
f4eab45
Bump typescript from 5.6.2 to 5.6.3
dependabot[bot] Oct 14, 2024
cb727fc
Merge pull request #377 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Oct 14, 2024
5c3520e
Bump @vercel/ncc from 0.38.2 to 0.38.3
dependabot[bot] Nov 18, 2024
d151f58
Merge pull request #386 from microsoftgraph/dependabot/npm_and_yarn/v…
github-actions[bot] Nov 18, 2024
3210bd5
Bump typescript from 5.6.3 to 5.7.2
dependabot[bot] Nov 25, 2024
464d04e
Merge pull request #389 from microsoftgraph/dependabot/npm_and_yarn/t…
github-actions[bot] Nov 25, 2024
d350b43
Bump prettier from 3.3.3 to 3.4.1
dependabot[bot] Dec 2, 2024
df62379
Merge pull request #390 from microsoftgraph/dependabot/npm_and_yarn/p…
github-actions[bot] Dec 2, 2024
43ade07
Bump prettier from 3.4.1 to 3.4.2
dependabot[bot] Dec 9, 2024
23d6210
Merge pull request #392 from microsoftgraph/dependabot/npm_and_yarn/p…
github-actions[bot] Dec 9, 2024
f2a7e4e
Bump ncipollo/release-action from 1.14.0 to 1.15.0
dependabot[bot] Jan 13, 2025
28bbcf0
Merge pull request #398 from microsoftgraph/dependabot/github_actions…
github-actions[bot] Jan 13, 2025
0037547
Bump dependabot/fetch-metadata from 2.2.0 to 2.3.0
dependabot[bot] Jan 27, 2025
bade1bf
Merge pull request #402 from microsoftgraph/dependabot/github_actions…
github-actions[bot] Jan 27, 2025
0bbf6a7
Bump undici from 5.28.4 to 5.28.5
dependabot[bot] Jan 27, 2025
4d3aa62
Merge pull request #403 from microsoftgraph/dependabot/npm_and_yarn/u…
github-actions[bot] Jan 27, 2025
29a626f
Bump @octokit/request from 8.4.0 to 8.4.1
dependabot[bot] Feb 18, 2025
c40032d
Merge pull request #410 from microsoftgraph/dependabot/npm_and_yarn/o…
github-actions[bot] Feb 18, 2025
fab506b
Bump @octokit/plugin-paginate-rest from 9.2.1 to 9.2.2
dependabot[bot] Feb 18, 2025
b79330e
Merge pull request #411 from microsoftgraph/dependabot/npm_and_yarn/o…
github-actions[bot] Feb 18, 2025
ab114b9
Bump ncipollo/release-action from 1.15.0 to 1.16.0
dependabot[bot] Feb 24, 2025
8d1661b
Merge pull request #414 from microsoftgraph/dependabot/github_actions…
github-actions[bot] Feb 24, 2025
adcc98c
Bump undici from 5.28.5 to 5.29.0
dependabot[bot] May 15, 2025
8514b06
Bump anothrNick/github-tag-action from 1.71.0 to 1.75.0
dependabot[bot] Jun 18, 2026
8352ae4
Bump actions/checkout from 4 to 7
dependabot[bot] Jun 18, 2026
c2abd20
Bump dependabot/fetch-metadata from 2.3.0 to 3.1.0
dependabot[bot] Jun 18, 2026
99898ba
Bump ncipollo/release-action from 1.16.0 to 1.21.0
dependabot[bot] Jun 18, 2026
d8532a7
Bump actions/setup-node from 4 to 6
dependabot[bot] Jun 18, 2026
6ffe9ec
Merge pull request #436 from microsoftgraph/dependabot/github_actions…
github-actions[bot] Jun 18, 2026
f0ce87d
Merge pull request #430 from microsoftgraph/dependabot/npm_and_yarn/u…
github-actions[bot] Jun 18, 2026
12d76fe
Bump form-data from 4.0.0 to 4.0.6
dependabot[bot] Jun 18, 2026
b6c7cd0
Bump flatted from 3.3.1 to 3.4.2
dependabot[bot] Jun 18, 2026
7cb4afc
Merge pull request #443 from microsoftgraph/dependabot/npm_and_yarn/f…
github-actions[bot] Jun 18, 2026
de8da12
Merge pull request #442 from microsoftgraph/dependabot/npm_and_yarn/f…
github-actions[bot] Jun 18, 2026
e889035
Merge pull request #433 from microsoftgraph/dependabot/github_actions…
jasonjoh Jun 18, 2026
b77e33c
Merge pull request #376 from microsoftgraph/dependabot/npm_and_yarn/o…
jasonjoh Jun 18, 2026
958893a
Merge pull request #434 from microsoftgraph/dependabot/github_actions…
jasonjoh Jun 18, 2026
e8d66b9
Merge pull request #435 from microsoftgraph/dependabot/github_actions…
jasonjoh Jun 18, 2026
2f9f31f
Merge pull request #438 from microsoftgraph/dependabot/github_actions…
jasonjoh Jun 18, 2026
e3dc80b
Modernize toolchain: ESM, Node 24, major dependency upgrades
jasonjoh Jun 19, 2026
a387759
Replace fetch-mock with native jest mock
jasonjoh Jun 19, 2026
6247485
Make file exclusion case-insensitive, expand test coverage
jasonjoh Jun 19, 2026
a2780a0
Update index.js
jasonjoh Jun 19, 2026
0f5e064
Update node.yml
jasonjoh Jun 19, 2026
961511d
Merge pull request #444 from microsoftgraph/refresh
jasonjoh Jun 30, 2026
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
25 changes: 0 additions & 25 deletions .eslintrc.json

This file was deleted.

53 changes: 53 additions & 0 deletions .github/copilot-instructions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# Copilot Instructions

## Architecture

This is a **GitHub Action** (Node.js, TypeScript) that detects CRLF line endings in pull request files and blocks merges. It runs on `pull_request_target` events.

**Flow:** `src/index.ts` (entry point) uses `@actions/github` to fetch PR files via the GitHub API, passes them to `src/validation.ts` which downloads each file's base64 content and checks for `\r\n`. If CRLF is found, the action posts a PR comment with fix instructions, adds a `crlf detected` label, and calls `core.setFailed()`.

**Key modules:**

- `src/index.ts` — Action entry point, orchestrates GitHub API calls
- `src/validation.ts` — Core logic: file content checking, exclusion matching (minimatch), PR comment generation
- `src/types.ts` — TypeScript types derived from `@octokit/openapi-types`
- `src/strings.ts` — User-facing string constants for PR comments

The `dist/` directory contains the bundled action output (committed to the repo) produced by Rollup.

## Build, Test, and Lint

```bash
# Build (TypeScript compilation)
npm run build

# Run all tests
npm run test

# Run a single test by name
npx cross-env NODE_OPTIONS='--experimental-vm-modules' jest -t "File with CRLF is detected properly"

# Lint
npm run lint

# Bundle for distribution (must be committed)
npm run package

# Full pipeline (format + build + test + package)
npm run all
```

After making changes, run `npm run package` and commit the updated `dist/` directory.

## Conventions

- **ESM modules** — The project uses `"type": "module"` with `.js` extensions in import paths (e.g., `'./types.js'`).
- **Copyright header** — Every `.ts` and `.js` file must start with:
```
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
```
This is enforced by ESLint (`@tony.ganchev/eslint-plugin-header`).
- **Prettier** — Single quotes, auto line endings. Integrated via ESLint.
- **Tests** — Jest with `ts-jest` in ESM mode. Tests live in `test/` and mock Octokit HTTP calls by injecting a `jest.fn()` via Octokit's `request: { fetch }` option with native `Response` objects. Test files match `**/*.test.ts`.
- **Unused variables** — Prefix with `_` (enforced by `@typescript-eslint/no-unused-vars`).
2 changes: 1 addition & 1 deletion .github/workflows/auto-merge-dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
steps:
- name: Dependabot metadata
id: metadata
uses: dependabot/fetch-metadata@v2.0.0
uses: dependabot/fetch-metadata@v3.1.0
with:
github-token: "${{ secrets.GITHUB_TOKEN }}"

Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/node.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ jobs:
permissions:
contents: read
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v7
- name: Verify npm all runs and build output matches
uses: actions/setup-node@v4
uses: actions/setup-node@v6
with:
node-version: '20'
node-version: '24'
- run: npm ci
- run: npm run all
6 changes: 3 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,19 +13,19 @@ jobs:
permissions:
contents: write
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v7
with:
fetch-depth: '0'
- name: Bump version and push tag
id: version
uses: anothrNick/github-tag-action@1.69.0
uses: anothrNick/github-tag-action@1.75.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
WITH_V: true
DEFAULT_BUMP: patch
RELEASE_BRANCHES: release
- name: Create release
uses: ncipollo/release-action@v1.14.0
uses: ncipollo/release-action@v1.21.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
Expand Down
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -104,4 +104,5 @@ typings/
.tern-port

# TSC output
lib
dist/*
!dist/index.js
10 changes: 10 additions & 0 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Microsoft Open Source Code of Conduct

This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).

Resources:

- [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/)
- [Microsoft Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/)
- Contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with questions or concerns
- Employees can reach out at [aka.ms/opensource/moderation-support](https://aka.ms/opensource/moderation-support)
2 changes: 1 addition & 1 deletion action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ inputs:
description: 'Custom exclusion list. Semi-colon delimited list of glob patterns.'
required: false
runs:
using: 'node20'
using: 'node24'
main: 'dist/index.js'
Loading
Loading