Skip to content

Commit 31387d6

Browse files
Merge branch 'intersystems-community:master' into contributes-authentication
2 parents d6bfe83 + f8969ca commit 31387d6

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

45 files changed

+5058
-5264
lines changed

.editorconfig

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,19 @@ root = true
33

44
[*]
55
charset = utf-8
6-
indent_style = space
7-
indent_size = 2
6+
indent_style = tab
7+
indent_size = 4
88
end_of_line = lf
99
insert_final_newline = true
1010
trim_trailing_whitespace = true
1111

1212
[*.md]
1313
max_line_length = 0
1414
trim_trailing_whitespace = false
15+
16+
# This section from the microsoft/vscode repo's .editorconfig
17+
# The indent size used in the `package.json` file cannot be changed
18+
# https://github.com/npm/npm/pull/3180#issuecomment-16336516
19+
[{*.yml,*.yaml,package.json}]
20+
indent_style = space
21+
indent_size = 2

.eslintignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
vscode.d.ts
2+
vscode.proposed.d.ts

.eslintrc.json

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
{
2+
"parser": "@typescript-eslint/parser",
3+
"parserOptions": {
4+
"ecmaVersion": 2018,
5+
"sourceType": "module",
6+
"project": "./tsconfig.json"
7+
},
8+
"env": {
9+
"es6": true,
10+
"node": true
11+
},
12+
"extends": [
13+
"eslint:recommended",
14+
"plugin:@typescript-eslint/recommended",
15+
"plugin:@typescript-eslint/eslint-recommended",
16+
"prettier",
17+
"prettier/@typescript-eslint",
18+
"plugin:prettier/recommended"
19+
],
20+
"plugins": [
21+
"@typescript-eslint"
22+
],
23+
"rules": {
24+
"@typescript-eslint/no-explicit-any": 0,
25+
"@typescript-eslint/explicit-function-return-type": 0,
26+
"@typescript-eslint/no-unused-vars": 0
27+
}
28+
}

.github/workflows/main.yml

Lines changed: 23 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
version: ${{ steps.set-version.outputs.version }}
2929
taggedbranch: ${{ steps.find-branch.outputs.taggedbranch }}
3030
steps:
31-
- uses: actions/checkout@v2
31+
- uses: actions/checkout@v3
3232
- run: git fetch --depth=1 origin +refs/tags/*:refs/tags/*
3333
- name: Find which branch the release tag points at
3434
id: find-branch
@@ -38,7 +38,7 @@ jobs:
3838
git fetch --depth=1 origin +refs/heads/*:refs/heads/*
3939
set -x
4040
TAGGEDBRANCH=$(git for-each-ref --points-at=${{github.sha}} --format='%(refname:lstrip=2)' refs/heads/)
41-
echo ::set-output name=taggedbranch::$TAGGEDBRANCH
41+
echo "taggedbranch=$TAGGEDBRANCH" >> $GITHUB_OUTPUT
4242
- name: Set an output
4343
id: set-version
4444
if: runner.os == 'Windows'
@@ -49,33 +49,33 @@ jobs:
4949
[ $GITHUB_EVENT_NAME == 'release' ] && VERSION=${{ github.event.release.tag_name }} && VERSION=${VERSION/v/}
5050
CHANGELOG=$(cat CHANGELOG.md | sed -n "/## \[${VERSION}\]/,/## /p" | sed '/^$/d;1d;$d')
5151
CHANGELOG="${CHANGELOG//$'\n'/'%0A'}"
52-
echo ::set-output name=changelog::$CHANGELOG
52+
echo "changelog=$CHANGELOG" >> $GITHUB_OUTPUT
5353
git tag -l | cat
5454
[ $GITHUB_EVENT_NAME == 'push' ] && VERSION+=-beta && VERSION+=.$(($(git tag -l "v$VERSION.*" | sort -nt. -k4 2>/dev/null | tail -1 | cut -d. -f4)+1))
5555
[ $GITHUB_EVENT_NAME == 'pull_request' ] && VERSION+=-dev.${{ github.event.pull_request.number }}
56-
echo ::set-output name=version::$VERSION
56+
echo "version=$VERSION" >> $GITHUB_OUTPUT
5757
NAME=$(jq -r '.name' package.json)-$VERSION
58-
echo ::set-output name=name::$NAME
58+
echo "name=$NAME" >> $GITHUB_OUTPUT
5959
tmp=$(mktemp)
6060
jq --arg version "$VERSION" '.version = $version' package.json > "$tmp" && mv "$tmp" package.json
6161
mkdir dist
6262
echo $VERSION > .version
6363
echo $NAME > .name
6464
- name: Use Node.js
65-
uses: actions/setup-node@v1
65+
uses: actions/setup-node@v3
6666
with:
67-
node-version: 14.x
67+
node-version: 18
6868
- run: npm install
6969
- run: npm run compile
7070
- name: npm test
71-
uses: GabrielBB/xvfb-action@v1.0
71+
uses: coactions/setup-xvfb@v1
7272
with:
7373
run: npm run test
7474
- name: Build package
7575
if: runner.os == 'Windows'
7676
run: |
7777
npx vsce package -o ${{ steps.set-version.outputs.name }}.vsix
78-
- uses: actions/upload-artifact@v2
78+
- uses: actions/upload-artifact@v4.4.2
7979
if: (runner.os == 'Windows') && (github.event_name != 'release')
8080
with:
8181
name: ${{ steps.set-version.outputs.name }}.vsix
@@ -85,76 +85,57 @@ jobs:
8585
runs-on: windows-latest
8686
needs: build
8787
steps:
88-
- uses: actions/download-artifact@v2
88+
- uses: actions/download-artifact@v4.1.7
8989
with:
9090
name: ${{ needs.build.outputs.name }}.vsix
9191
- name: Create Release
9292
id: create_release
93-
uses: actions/create-release@v1
94-
env:
95-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
93+
uses: softprops/action-gh-release@v1
9694
with:
9795
tag_name: v${{ needs.build.outputs.version }}
98-
release_name: v${{ needs.build.outputs.version }}
96+
name: v${{ needs.build.outputs.version }}
9997
prerelease: ${{ github.event_name != 'release' }}
100-
body: |
101-
Changes in this release
102-
${{ needs.build.outputs.changelog }}
103-
- name: Upload Release Asset
104-
id: upload-release-asset
105-
uses: actions/upload-release-asset@v1
106-
env:
107-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
108-
with:
109-
upload_url: ${{ steps.create_release.outputs.upload_url }}
110-
asset_path: ${{ needs.build.outputs.name }}.vsix
111-
asset_name: ${{ needs.build.outputs.name }}.vsix
112-
asset_content_type: application/zip
98+
token: ${{ secrets.GITHUB_TOKEN }}
99+
files: ${{ needs.build.outputs.name }}.vsix
113100
publish:
114101
needs: build
115102
if: github.event_name == 'release' && needs.build.outputs.taggedbranch == 'master'
116103
runs-on: windows-latest
117104
steps:
118-
- uses: actions/checkout@v2
105+
- uses: actions/checkout@v3
119106
with:
120107
ref: master
121108
token: ${{ secrets.TOKEN }}
122109
- name: Use Node.js
123-
uses: actions/setup-node@v1
110+
uses: actions/setup-node@v3
124111
with:
125-
node-version: 14.x
112+
node-version: 18
126113
- name: Prepare build
127114
id: set-version
128115
shell: bash
129116
run: |
130-
# REMOVE BELOW AFTER TESTING
131-
exit 1
132-
# REMOVE ABOVE AFTER TESTING
133117
VERSION=${{ needs.build.outputs.version }}
134118
NEXT_VERSION=`echo $VERSION | awk -F. '/[0-9]+\./{$NF++;print}' OFS=.`
135119
tmp=$(mktemp)
136120
git config --global user.name 'ProjectBot'
137121
git config --global user.email '[email protected]'
138122
jq --arg version "${NEXT_VERSION}-SNAPSHOT" '.version = $version' package.json > "$tmp" && mv "$tmp" package.json
139123
git add package.json
140-
git commit -m 'auto bump version with release'
124+
git commit -m 'auto bump version with release [skip ci]'
141125
jq --arg version "$VERSION" '.version = $version' package.json > "$tmp" && mv "$tmp" package.json
142-
jq '.enableProposedApi = false' package.json > "$tmp" && mv "$tmp" package.json
126+
jq 'del(.enableProposedApi,.enabledApiProposals)' package.json > "$tmp" && mv "$tmp" package.json
143127
npm install
144128
git push
145129
- name: Build package
146130
run: |
147131
npx vsce package -o ${{ needs.build.outputs.name }}.vsix
148132
- name: Upload Release Asset
149133
id: upload-release-asset
150-
uses: actions/upload-release-asset@v1
151-
env:
152-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
134+
uses: softprops/action-gh-release@v1
153135
with:
154-
upload_url: ${{ github.event.release.upload_url }}
155-
asset_path: ${{ needs.build.outputs.name }}.vsix
156-
asset_name: ${{ needs.build.outputs.name }}.vsix
157-
asset_content_type: application/zip
136+
tag_name: ${{ github.event.release.tag_name }}
137+
files: ${{ needs.build.outputs.name }}.vsix
138+
token: ${{ secrets.GITHUB_TOKEN }}
158139
- name: Publish to VSCode Marketplace
159140
shell: bash
160141
run: |

.github/workflows/prerelease.yml

Lines changed: 24 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
version: ${{ steps.set-version.outputs.version }}
2929
taggedbranch: ${{ steps.find-branch.outputs.taggedbranch }}
3030
steps:
31-
- uses: actions/checkout@v2
31+
- uses: actions/checkout@v3
3232
- run: git fetch --depth=1 origin +refs/tags/*:refs/tags/*
3333
- name: Find which branch the release tag points at
3434
id: find-branch
@@ -38,7 +38,7 @@ jobs:
3838
git fetch --depth=1 origin +refs/heads/*:refs/heads/*
3939
set -x
4040
TAGGEDBRANCH=$(git for-each-ref --points-at=${{github.sha}} --format='%(refname:lstrip=2)' refs/heads/)
41-
echo ::set-output name=taggedbranch::$TAGGEDBRANCH
41+
echo "taggedbranch=$TAGGEDBRANCH" >> $GITHUB_OUTPUT
4242
- name: Set an output
4343
id: set-version
4444
if: runner.os == 'Windows'
@@ -49,33 +49,33 @@ jobs:
4949
[ $GITHUB_EVENT_NAME == 'release' ] && VERSION=${{ github.event.release.tag_name }} && VERSION=${VERSION/v/}
5050
CHANGELOG=$(cat CHANGELOG.md | sed -n "/## \[${VERSION}\]/,/## /p" | sed '/^$/d;1d;$d')
5151
CHANGELOG="${CHANGELOG//$'\n'/'%0A'}"
52-
echo ::set-output name=changelog::$CHANGELOG
52+
echo "changelog=$CHANGELOG" >> $GITHUB_OUTPUT
5353
git tag -l | cat
5454
[ $GITHUB_EVENT_NAME == 'push' ] && VERSION+=-beta && VERSION+=.$(($(git tag -l "v$VERSION.*" | sort -nt. -k4 2>/dev/null | tail -1 | cut -d. -f4)+1))
5555
[ $GITHUB_EVENT_NAME == 'pull_request' ] && VERSION+=-dev.${{ github.event.pull_request.number }}
56-
echo ::set-output name=version::$VERSION
56+
echo "version=$VERSION" >> $GITHUB_OUTPUT
5757
NAME=$(jq -r '.name' package.json)-$VERSION
58-
echo ::set-output name=name::$NAME
58+
echo "name=$NAME" >> $GITHUB_OUTPUT
5959
tmp=$(mktemp)
6060
jq --arg version "$VERSION" '.version = $version' package.json > "$tmp" && mv "$tmp" package.json
6161
mkdir dist
6262
echo $VERSION > .version
6363
echo $NAME > .name
6464
- name: Use Node.js
65-
uses: actions/setup-node@v1
65+
uses: actions/setup-node@v3
6666
with:
67-
node-version: 14.x
67+
node-version: 18
6868
- run: npm install
6969
- run: npm run compile
7070
- name: npm test
71-
uses: GabrielBB/xvfb-action@v1.0
71+
uses: coactions/setup-xvfb@v1
7272
with:
7373
run: npm run test
7474
- name: Build pre-release package
7575
if: runner.os == 'Windows'
7676
run: |
77-
npx vsce package --pre-release -o ${{ steps.set-version.outputs.name }}.vsix
78-
- uses: actions/upload-artifact@v2
77+
npx vsce package --pre-release -o ${{ steps.set-version.outputs.name }}.vsix --githubBranch prerelease
78+
- uses: actions/upload-artifact@v4.4.2
7979
if: (runner.os == 'Windows') && (github.event_name != 'release')
8080
with:
8181
name: ${{ steps.set-version.outputs.name }}.vsix
@@ -85,46 +85,33 @@ jobs:
8585
runs-on: windows-latest
8686
needs: build
8787
steps:
88-
- uses: actions/download-artifact@v2
88+
- uses: actions/download-artifact@v4.1.7
8989
with:
9090
name: ${{ needs.build.outputs.name }}.vsix
9191
- name: Create Pre-Release
9292
id: create_release
93-
uses: actions/create-release@v1
94-
if: runner.os == 'Windows'
93+
uses: softprops/action-gh-release@v1
9594
env:
9695
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
9796
with:
9897
tag_name: v${{ needs.build.outputs.version }}
99-
release_name: v${{ needs.build.outputs.version }}
98+
name: v${{ needs.build.outputs.version }}
10099
prerelease: ${{ github.event_name != 'release' }}
101-
body: |
102-
Changes in this pre-release
103-
${{ needs.build.outputs.changelog }}
104-
- name: Upload Pre-Release Asset
105-
id: upload-release-asset
106-
uses: actions/upload-release-asset@v1
107-
if: runner.os == 'Windows'
108-
env:
109-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
110-
with:
111-
upload_url: ${{ steps.create_release.outputs.upload_url }}
112-
asset_path: ${{ needs.build.outputs.name }}.vsix
113-
asset_name: ${{ needs.build.outputs.name }}.vsix
114-
asset_content_type: application/zip
100+
token: ${{ secrets.GITHUB_TOKEN }}
101+
files: ${{ needs.build.outputs.name }}.vsix
115102
publish:
116103
needs: build
117104
if: github.event_name == 'release' && needs.build.outputs.taggedbranch == 'prerelease'
118105
runs-on: windows-latest
119106
steps:
120-
- uses: actions/checkout@v2
107+
- uses: actions/checkout@v3
121108
with:
122109
ref: prerelease
123110
token: ${{ secrets.TOKEN }}
124111
- name: Use Node.js
125-
uses: actions/setup-node@v1
112+
uses: actions/setup-node@v3
126113
with:
127-
node-version: 14.x
114+
node-version: 18
128115
- name: Prepare pre-release build
129116
id: set-version
130117
shell: bash
@@ -136,25 +123,21 @@ jobs:
136123
git config --global user.email '[email protected]'
137124
jq --arg version "${NEXT_VERSION}-SNAPSHOT" '.version = $version' package.json > "$tmp" && mv "$tmp" package.json
138125
git add package.json
139-
git commit -m 'auto bump version after pre-release'
126+
git commit -m 'auto bump version after pre-release [skip ci]'
140127
jq --arg version "$VERSION" '.version = $version' package.json > "$tmp" && mv "$tmp" package.json
141128
npm install
142129
jq 'del(.enableProposedApi,.enabledApiProposals)' package.json > "$tmp" && mv "$tmp" package.json
143130
git push
144131
- name: Build pre-release package
145132
run: |
146-
npx vsce package --pre-release -o ${{ needs.build.outputs.name }}.vsix
133+
npx vsce package --pre-release -o ${{ needs.build.outputs.name }}.vsix --githubBranch prerelease
147134
- name: Upload Release Asset
148135
id: upload-release-asset
149-
uses: actions/upload-release-asset@v1
150-
if: runner.os == 'Windows'
151-
env:
152-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
136+
uses: softprops/action-gh-release@v1
153137
with:
154-
upload_url: ${{ github.event.release.upload_url }}
155-
asset_path: ${{ needs.build.outputs.name }}.vsix
156-
asset_name: ${{ needs.build.outputs.name }}.vsix
157-
asset_content_type: application/zip
138+
tag_name: ${{ github.event.release.tag_name }}
139+
files: ${{ needs.build.outputs.name }}.vsix
140+
token: ${{ secrets.GITHUB_TOKEN }}
158141
- name: Publish to VSCode Marketplace
159142
shell: bash
160143
run: |

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
.DS_Store
22
node_modules/
33
out/
4+
dist/
45
.vscode-test
56
*.vsix

.vscode/extensions.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"recommendations": [
3+
"dbaeumer.vscode-eslint",
4+
"EditorConfig.EditorConfig"
5+
]
6+
}

0 commit comments

Comments
 (0)