Skip to content
Closed
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
3 changes: 3 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
###############################################################################
* text=auto

# Use unix line endings always, even on Windows
.github/**/*.js text eol=lf

###############################################################################
# Set default behavior for command prompt diff.
#
Expand Down
1 change: 1 addition & 0 deletions .github/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
coverage
37 changes: 37 additions & 0 deletions .github/.prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# python customizations
actions
agents
hooks
skills
workflows
PULL_REQUEST_TEMPLATE.md

# this file
.prettierignore

# code coverage
coverage

# specs in test folders
fixtures
specification

# auto-generated agentic workflow lock files
workflows/*.lock.yml

# unmanaged files and folders
**/*instructions.md
chatmodes
ISSUE_TEMPLATE
policies
prompts
PULL_REQUEST_TEMPLATE

# lock files for agent workflows
**/*.lock.yml

# synced from external repos
workflows/post-apiview.yml

# synced GitHub skills
.github/skills/azsdk-common-*
15 changes: 15 additions & 0 deletions .github/.prettierrc.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Keep in sync with eng/tools/.prettierrc.yaml

plugins:
- prettier-plugin-organize-imports

# Aligned with microsoft/typespec
printWidth: 100

overrides:
# tsconfig.json is actually parsed as JSONC
- files:
- tsconfig.json
- tsconfig.*.json
options:
parser: jsonc
17 changes: 17 additions & 0 deletions .github/actions/install-deps-github-script/action.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: Install dependencies for github-script actions
description: Installs dependencies for github-script actions

runs:
using: composite

steps:
- uses: ./.github/actions/setup-node-install-deps
with:
# actions/github-script@v8 uses Node 24
node-version: 24.x
# "--no-audit": improves performance
# "--no-fund": improves performance
# "--prefer-offline": improves performance
# "--omit dev": not needed at runtime, improves performance
install-command: "npm ci --no-audit --no-fund --prefer-offline --omit dev"
working-directory: ./.github
39 changes: 39 additions & 0 deletions .github/actions/setup-node-install-deps/action.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Setup Node and install dependencies
description: Uses specified Node version and installs dependencies (typically using "npm")

inputs:
node-version:
description: "Node version to use"
default: 24.x
install-command:
description: "Command to install dependencies"
default: "npm ci --no-audit --no-fund --prefer-offline"
working-directory:
description: "Working directory"
default: "."

runs:
using: "composite"

steps:
- uses: actions/setup-node@v6
with:
node-version: ${{ inputs.node-version }}
cache: "npm"
cache-dependency-path: ${{ inputs.working-directory }}/package-lock.json

- run: |
echo "::group::$INSTALL_COMMAND"
$INSTALL_COMMAND
echo "::endgroup::"
shell: bash
env:
INSTALL_COMMAND: ${{ inputs.install-command }}
working-directory: ${{ inputs.working-directory }}

- run: |
echo "::group::npm ls -a"
npm ls -a || true
echo "::endgroup::"
shell: bash
working-directory: ${{ inputs.working-directory }}
74 changes: 74 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
open-pull-requests-limit: 10 # default:5
cooldown:
default-days: 7
exclude-paths:
- ".github/workflows/*.lock.{yaml,yml}"
- package-ecosystem: "npm"
directories:
- "/"
- "/eng/tools"
- "/eng/tools/**"
schedule:
interval: "daily"
open-pull-requests-limit: 10 # default:5
cooldown:
default-days: 7
exclude:
# Allow immediate updates of self-owned packages
- "@azure-tools/*"
- "@autorest/*"
- "@azure/*"
- "@microsoft.azure/*"
- "@typespec/*"
- "oav"
ignore:
# Updated manually to align with minimum supported Node version
- dependency-name: "@types/node"
# Updated manually by the team maintaining this package
- dependency-name: "@azure-tools/openai-typespec"
# Updated manually by the Liftr team
- dependency-name: "@azure-tools/typespec-liftr-base"
# Only allow patch updates for spec-gen-sdk
- dependency-name: "@azure-tools/spec-gen-sdk"
update-types: ["version-update:semver-minor", "version-update:semver-major"]
groups:
# Ships separately from other typespec packages
typespec-client-generator-cli:
patterns:
- "@azure-tools/typespec-client-generator-cli"
# Ships separately from other typespec packages
openapi-to-typespec:
patterns:
- "@autorest/openapi-to-typespec"
typespec:
patterns:
- "*typespec*"
eslint:
patterns:
- "*eslint*"
versioning-strategy: increase-if-necessary
- package-ecosystem: "npm"
directories:
- "/.github"
- "/.github/shared"
schedule:
interval: "daily"
open-pull-requests-limit: 10 # default:5
cooldown:
default-days: 7
ignore:
# Updated manually to align with minimum supported Node version
- dependency-name: "@types/node"
# Points to "github:actions/github-script" since package isn't published to npmjs
- dependency-name: "@types/github-script"
groups:
eslint:
patterns:
- "*eslint*"
versioning-strategy: increase-if-necessary
16 changes: 16 additions & 0 deletions .github/eslint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import { defineConfig } from "eslint/config";
import { defineBaseConfig } from "./shared/eslint.base.config.js";

export default defineConfig(
defineBaseConfig({
// ensures the tsconfig path resolves relative to this file (so cannot be defined in base file)
// default is process.cwd() when running eslint, which may be incorrect
tsconfigRootDir: import.meta.dirname,
}),
{
ignores: [
// generated by `vitest --coverage`
"shared/coverage/**",
],
},
);
Loading
Loading