Skip to content

Commit 72ac825

Browse files
authored
chore: update project structure (#4)
1 parent d806a76 commit 72ac825

File tree

12 files changed

+425
-80
lines changed

12 files changed

+425
-80
lines changed

.gitattributes

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1 @@
1-
# Set default behavior to automatically normalize line endings.
2-
* text=auto
1+
* text eol=lf

.github/CODEOWNERS

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# Active Maintainer
2+
* @Shinigami92

.github/workflows/ci.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
9+
permissions:
10+
contents: read # to fetch code (actions/checkout)
11+
12+
jobs:
13+
lint:
14+
runs-on: ubuntu-latest
15+
timeout-minutes: 10
16+
name: 'Lint: node-20, ubuntu-latest'
17+
steps:
18+
- name: Checkout
19+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
20+
with:
21+
fetch-depth: 0
22+
23+
- name: Install pnpm
24+
uses: pnpm/action-setup@a7487c7e89a18df4991f7f222e4898a00d66ddda # v4.1.0
25+
26+
- name: Set node version to 20
27+
uses: actions/setup-node@cdca7365b2dadb8aad0a33bc7601856ffabcc48e # v4.3.0
28+
with:
29+
node-version: 20
30+
cache: 'pnpm'
31+
32+
- name: Install deps
33+
run: pnpm install
34+
35+
# - name: Build
36+
# run: pnpm run build
37+
38+
# - name: Lint
39+
# run: pnpm run lint
40+
41+
- name: Check formatting
42+
run: pnpm prettier --check .

.prettierignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
.pnpm-store/
12
coverage/
23
dist/
34
CHANGELOG.md

.prettierrc.cjs

Lines changed: 0 additions & 20 deletions
This file was deleted.

.prettierrc.mjs

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
// @ts-check
2+
3+
/**
4+
* @type {import('prettier').Config}
5+
*/
6+
export default {
7+
plugins: ['prettier-plugin-organize-imports', 'prettier-plugin-packagejson'],
8+
singleQuote: true,
9+
trailingComma: 'es5',
10+
overrides: [
11+
{
12+
files: '*.json5',
13+
options: {
14+
parser: 'json5',
15+
quoteProps: 'preserve',
16+
singleQuote: false,
17+
trailingComma: 'none',
18+
},
19+
},
20+
{
21+
files: '*.md',
22+
options: {
23+
// @ts-expect-error: known property
24+
organizeImportsSkipDestructiveCodeActions: true,
25+
},
26+
},
27+
{
28+
files: 'package.json',
29+
options: {
30+
packageSortOrder: ['name', 'version', 'description', 'scripts'],
31+
},
32+
},
33+
],
34+
};

.vscode/extensions.json

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"recommendations": [
3+
"dbaeumer.vscode-eslint",
4+
"editorconfig.editorconfig",
5+
"esbenp.prettier-vscode",
6+
"github.vscode-github-actions",
7+
"kravets.vscode-publint",
8+
"pflannery.vscode-versionlens",
9+
"redhat.vscode-yaml"
10+
]
11+
}

.vscode/settings.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
{
2+
"cSpell.words": ["hsml"],
23
"files.associations": {
34
"*.json5": "jsonc"
45
},

CHANGELOG.md

Lines changed: 0 additions & 9 deletions
This file was deleted.

package.json

Lines changed: 22 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,41 +1,47 @@
11
{
22
"name": "hsml",
3-
"displayName": "hsml",
4-
"description": "hsml support for Visual Studio Code",
53
"version": "0.1.0",
4+
"description": "hsml support for Visual Studio Code",
65
"scripts": {
7-
"format": "prettier --cache --write ."
8-
},
9-
"engines": {
10-
"vscode": "^1.78.0"
6+
"format": "prettier --cache --write .",
7+
"preflight": "pnpm install && run-s format"
118
},
9+
"displayName": "hsml",
1210
"categories": [
1311
"Programming Languages"
1412
],
13+
"type": "commonjs",
1514
"contributes": {
15+
"grammars": [
16+
{
17+
"language": "hsml",
18+
"scopeName": "text.hsml",
19+
"path": "./syntaxes/hsml.tmLanguage.json"
20+
}
21+
],
1622
"languages": [
1723
{
1824
"id": "hsml",
1925
"aliases": [
26+
"HSML",
2027
"hsml"
2128
],
2229
"extensions": [
2330
".hsml"
2431
],
2532
"configuration": "./language-configuration.json"
2633
}
27-
],
28-
"grammars": [
29-
{
30-
"language": "hsml",
31-
"scopeName": "text.hsml",
32-
"path": "./syntaxes/hsml.tmLanguage.json"
33-
}
3434
]
3535
},
3636
"devDependencies": {
37-
"@types/node": "~20.2.5",
38-
"prettier": "~2.8.8",
39-
"prettier-plugin-organize-imports": "~3.2.2"
37+
"@types/node": "~20.17.24",
38+
"npm-run-all2": "~7.0.2",
39+
"prettier": "~3.5.3",
40+
"prettier-plugin-organize-imports": "~4.1.0",
41+
"prettier-plugin-packagejson": "~2.5.10"
42+
},
43+
"packageManager": "pnpm@10.6.4",
44+
"engines": {
45+
"vscode": "^1.98.0"
4046
}
4147
}

0 commit comments

Comments
 (0)