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
32 changes: 15 additions & 17 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,23 +15,6 @@ jobs:
lint-and-format:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
ref: ${{ github.head_ref }}

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: "lts/iron"
cache: "npm"

- name: Install dependencies
run: npm install

- name: Check that project is able to be packaged
run: npm run package

- name: Check that PR title follows conventional commits using regex
env:
TITLE: ${{ github.event.pull_request.title }}
Expand All @@ -48,3 +31,18 @@ jobs:
echo "See the following link for more information: https://www.conventionalcommits.org/en/v1.0.0/"
exit 1
fi

- name: Checkout code
uses: actions/checkout@v6

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: "lts/krypton"
cache: "npm"

- name: Install dependencies
run: npm install

- name: Check that project is able to be packaged
run: npm run package
5 changes: 5 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"recommendations": [
"econnor4312.esbuild-problem-matchers",
]
}
3 changes: 2 additions & 1 deletion .vscodeignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,5 @@ esbuild.js
eslint.config.mjs
package-lock.json
tsconfig.json
*.vsix
*.vsix
CONTRIBUTING.md
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [1.0.4]

- Upgrade dependencies

## [1.0.3]

- Add support for relative and workspace-relative config paths
Expand Down
15 changes: 15 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Contributing

## Setup

1. Run `npm install` to install dependencies

2. Using the VS Code `Run and Debug` tab, run the `Run Extension` launch configuration

Whenever you make a change, remember to restart the `Run Extension` launch configuration.

## Deploying

1. Run `vsce package` to create a `.vsix` file

2. If you have the proper permissions, run `vsce publish`
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,10 @@ The `Output` channel will display information about how this config file path is

## Release Notes

### 1.0.4

- Upgrade dependencies

### 1.0.3

- Add support for relative and workspace-relative config paths
Expand Down
1 change: 1 addition & 0 deletions esbuild.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ const esbuildProblemMatcherPlugin = {
build.onStart(() => {
console.log("[watch] build started");
});

build.onEnd((result) => {
result.errors.forEach(({ text, location }) => {
console.error(`✘ [ERROR] ${text}`);
Expand Down
42 changes: 32 additions & 10 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -1,35 +1,57 @@
// @ts-check
import eslint from "@eslint/js";
import { defineConfig } from "eslint/config";
import eslintPluginImport from "eslint-plugin-import";
import eslintPluginPrettierRecommended from "eslint-plugin-prettier/recommended";
import simpleImportSort from "eslint-plugin-simple-import-sort";
import tseslint from "typescript-eslint";

export default tseslint.config(
// ignore output directory
{
ignores: ["dist"],
},
// recommended rules
export default defineConfig(
eslint.configs.recommended,
tseslint.configs.recommended,
tseslint.configs.stylistic,

// prettier rules
eslintPluginPrettierRecommended,

// enable typed linting
{
languageOptions: {
parserOptions: {
projectService: true,
},
},
},

{
plugins: {
"simple-import-sort": simpleImportSort,
import: eslintPluginImport,
},
rules: {
// import sorting rules
// Formatting and style rules
"prettier/prettier": "error",
"no-console": "error",

// Import rules
"simple-import-sort/imports": "error",
"simple-import-sort/exports": "error",
"import/first": "error",
"import/newline-after-import": "error",
"import/no-duplicates": "error",
"import/no-default-export": "error",

// allow for unused variables as long as they are marked
// typescript rules
"@typescript-eslint/consistent-type-definitions": ["error", "type"],
"@typescript-eslint/no-floating-promises": "error",
"@typescript-eslint/await-thenable": "error",
"@typescript-eslint/require-await": "error",
"@typescript-eslint/explicit-function-return-type": "error",
"@typescript-eslint/no-unused-vars": [
"error",
{
argsIgnorePattern: "^_",
caughtErrorsIgnorePattern: "^_",
destructuredArrayIgnorePattern: "^_",
varsIgnorePattern: "^_",
},
],
},
Expand Down
Loading