virmator 4.0.1 → 4.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/base-configs/base-cspell.js +1 -0
- package/configs/.github/workflows/build-for-gh-pages.yml +24 -0
- package/configs/.github/workflows/tagged-release.yml +42 -0
- package/configs/.github/workflows/tests.yml +26 -0
- package/configs/.vscode/settings.json +3 -0
- package/configs/npmignore.txt +8 -8
- package/configs/package.json +4 -4
- package/configs/src/index.d.ts +5 -0
- package/dist/commands/extra-configs/all-extra-configs.js +21 -0
- package/package.json +8 -7
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
name: build-for-gh-pages
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches:
|
|
6
|
+
- main
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
build-for-gh-pages:
|
|
10
|
+
runs-on: 'ubuntu-latest'
|
|
11
|
+
|
|
12
|
+
steps:
|
|
13
|
+
- uses: actions/checkout@v3
|
|
14
|
+
- uses: actions/setup-node@v3
|
|
15
|
+
with:
|
|
16
|
+
node-version: 16.x
|
|
17
|
+
- name: build
|
|
18
|
+
run: |
|
|
19
|
+
npm ci
|
|
20
|
+
npm run build
|
|
21
|
+
- uses: JamesIves/github-pages-deploy-action@v4
|
|
22
|
+
with:
|
|
23
|
+
branch: 'gh-pages'
|
|
24
|
+
folder: 'dist'
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
name: 'tagged-release'
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
tags:
|
|
6
|
+
- 'v*'
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
tagged-release:
|
|
10
|
+
name: 'Tagged Release'
|
|
11
|
+
if: github.event.base_ref == 'refs/heads/main' || github.event.base_ref == 'refs/heads/master'
|
|
12
|
+
runs-on: 'ubuntu-latest'
|
|
13
|
+
|
|
14
|
+
steps:
|
|
15
|
+
- uses: actions/checkout@v3
|
|
16
|
+
- name: Use Node.js
|
|
17
|
+
uses: actions/setup-node@v3
|
|
18
|
+
with:
|
|
19
|
+
node-version: 16.x
|
|
20
|
+
- name: run test
|
|
21
|
+
run: |
|
|
22
|
+
npm ci
|
|
23
|
+
npx playwright install --with-deps
|
|
24
|
+
npm run test:all
|
|
25
|
+
- name: pack and set vars
|
|
26
|
+
id: vars
|
|
27
|
+
run: |
|
|
28
|
+
tagName="${GITHUB_REF#refs/*/}"
|
|
29
|
+
originalTarName="$(npm pack)"
|
|
30
|
+
packageNameWithoutFileExtension="${originalTarName%.tgz}"
|
|
31
|
+
tagNameWithoutV="${tagName##v}"
|
|
32
|
+
packageName="${packageNameWithoutFileExtension%-$tagNameWithoutV}"
|
|
33
|
+
newTarName="$packageName-$tagName.tgz"
|
|
34
|
+
mv "$originalTarName" "$newTarName"
|
|
35
|
+
echo ::set-output name=tarName::"$newTarName"
|
|
36
|
+
|
|
37
|
+
- uses: 'marvinpinto/action-automatic-releases@latest'
|
|
38
|
+
with:
|
|
39
|
+
repo_token: '${{ secrets.GITHUB_TOKEN }}'
|
|
40
|
+
prerelease: false
|
|
41
|
+
files: |
|
|
42
|
+
${{ steps.vars.outputs.tarName }}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
name: tests
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches:
|
|
6
|
+
- '**'
|
|
7
|
+
|
|
8
|
+
jobs:
|
|
9
|
+
build:
|
|
10
|
+
runs-on: ${{ matrix.os }}
|
|
11
|
+
strategy:
|
|
12
|
+
fail-fast: false
|
|
13
|
+
matrix:
|
|
14
|
+
os: [ubuntu-latest, windows-latest, macos-latest]
|
|
15
|
+
node-version: [16.x, 18.x]
|
|
16
|
+
steps:
|
|
17
|
+
- uses: actions/checkout@v3
|
|
18
|
+
- name: Use Node.js ${{ matrix.node-version }}
|
|
19
|
+
uses: actions/setup-node@v3
|
|
20
|
+
with:
|
|
21
|
+
node-version: ${{ matrix.node-version }}
|
|
22
|
+
- name: run test
|
|
23
|
+
run: |
|
|
24
|
+
npm ci
|
|
25
|
+
npx playwright install --with-deps
|
|
26
|
+
npm run test:all
|
package/configs/npmignore.txt
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
.*
|
|
2
|
-
*.test-helper
|
|
3
|
-
*.test
|
|
4
|
-
*.test.js
|
|
5
|
-
*.test.ts
|
|
2
|
+
*.test-helper.*
|
|
3
|
+
*.test.*
|
|
6
4
|
**/*/readme-examples/
|
|
7
5
|
**/*/test/
|
|
8
6
|
/*.tgz
|
|
7
|
+
/coverage/
|
|
8
|
+
/cspell.config.js
|
|
9
|
+
/graphics/
|
|
9
10
|
/Icon?
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
test-files/
|
|
11
|
+
/scripts/
|
|
12
|
+
/src/
|
|
13
|
+
/test-files/
|
|
14
14
|
tsconfig*.json
|
package/configs/package.json
CHANGED
|
@@ -5,15 +5,15 @@
|
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "virmator frontend build",
|
|
7
7
|
"compile": "rm -rf dist && virmator compile",
|
|
8
|
-
"docs:check": "virmator code-in-markdown check",
|
|
9
8
|
"docs:update": "virmator code-in-markdown",
|
|
10
9
|
"format": "virmator format",
|
|
11
|
-
"prepublishOnly": "npm run compile && npm run test:
|
|
10
|
+
"prepublishOnly": "npm run compile && npm run test:all",
|
|
12
11
|
"preview": "virmator frontend preview",
|
|
13
12
|
"spellcheck": "virmator spellcheck",
|
|
14
13
|
"start": "npm install && virmator frontend",
|
|
15
|
-
"test": "virmator test",
|
|
16
|
-
"test:
|
|
14
|
+
"test": "virmator test && npm run test:types",
|
|
15
|
+
"test:all": "npm run test:types && npm test && npm run spellcheck && virmator format check && npm run test:docs",
|
|
16
|
+
"test:docs": "virmator code-in-markdown check",
|
|
17
17
|
"test:types": "tsc --noEmit",
|
|
18
18
|
"test:web": "virmator test-web"
|
|
19
19
|
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
/** This file helps ensure that test calls are imported from the correct package. */
|
|
2
|
+
|
|
3
|
+
declare var it: 'Don\'t use it directly: import "it" from Mocha.';
|
|
4
|
+
declare var expect: 'Don\'t use expect directly: import "expect" from Chai.';
|
|
5
|
+
declare var describe: 'Don\'t use describe directly: import "describe" from Mocha.';
|
|
@@ -42,4 +42,25 @@ exports.nonCommandConfigs = [
|
|
|
42
42
|
updateExistingConfigFileCallback: combine_json_config_1.combineJsonConfig,
|
|
43
43
|
required: true,
|
|
44
44
|
},
|
|
45
|
+
{
|
|
46
|
+
copyFromInternalPath: (0, path_1.join)(package_paths_1.virmatorConfigsDir, 'src', 'index.d.ts'),
|
|
47
|
+
copyToPathRelativeToRepoDir: (0, path_1.join)('src', 'index.d.ts'),
|
|
48
|
+
updateExistingConfigFileCallback: combine_text_config_1.combineTextConfig,
|
|
49
|
+
required: true,
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
copyFromInternalPath: (0, path_1.join)(package_paths_1.virmatorConfigsDir, '.github', 'workflows', 'build-for-gh-pages.yml'),
|
|
53
|
+
copyToPathRelativeToRepoDir: (0, path_1.join)('.github', 'workflows', 'build-for-gh-pages.yml'),
|
|
54
|
+
required: true,
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
copyFromInternalPath: (0, path_1.join)(package_paths_1.virmatorConfigsDir, '.github', 'workflows', 'tagged-release.yml'),
|
|
58
|
+
copyToPathRelativeToRepoDir: (0, path_1.join)('.github', 'workflows', 'tagged-release.yml'),
|
|
59
|
+
required: true,
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
copyFromInternalPath: (0, path_1.join)(package_paths_1.virmatorConfigsDir, '.github', 'workflows', 'tests.yml'),
|
|
63
|
+
copyToPathRelativeToRepoDir: (0, path_1.join)('.github', 'workflows', 'tests.yml'),
|
|
64
|
+
required: true,
|
|
65
|
+
},
|
|
45
66
|
];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "virmator",
|
|
3
|
-
"version": "4.0.
|
|
3
|
+
"version": "4.0.3",
|
|
4
4
|
"description": "Handle all the stuffs in one package.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"automation",
|
|
@@ -31,27 +31,27 @@
|
|
|
31
31
|
"format": "npm run format:base -- --write --list-different",
|
|
32
32
|
"format:base": "prettier \"./**/*.+(ts|json|html|css|md|js)\"",
|
|
33
33
|
"format:check": "npm run format:base -- --check",
|
|
34
|
-
"
|
|
35
|
-
"prepublishOnly": "npm run test:full",
|
|
34
|
+
"prepublishOnly": "npm run test:all",
|
|
36
35
|
"readme:check": "npm run compile && ts-node -r tsconfig-paths/register src/scripts/save-help-message.ts check && md-code --check README.md",
|
|
37
36
|
"readme:update": "npm run compile && ts-node -r tsconfig-paths/register src/scripts/save-help-message.ts && md-code README.md",
|
|
38
37
|
"spellcheck": "cspell \"{*,.*,**/{.*,*}/**/{.*,*}}\" --exclude \"test-files/spellcheck/invalid-spellcheck-repo/**/*\" --exclude \"extender-configs\"",
|
|
39
38
|
"test": "bash src/scripts/run-tests.sh",
|
|
40
|
-
"test:
|
|
39
|
+
"test:all": "npm run test && npm run spellcheck -- --no-progress && npm run format:check && npm run readme:check",
|
|
41
40
|
"test:help": "ts-node -r tsconfig-paths/register src/cli/cli.ts --help",
|
|
42
41
|
"test:types": "tsc --noEmit"
|
|
43
42
|
},
|
|
44
43
|
"dependencies": {
|
|
45
44
|
"ansi-colors": "^4.1.3",
|
|
46
45
|
"augment-vir": "2.5.1",
|
|
47
|
-
"semver": "7.3.
|
|
46
|
+
"semver": "7.3.8",
|
|
48
47
|
"simple-git": "3.14.1"
|
|
49
48
|
},
|
|
50
49
|
"devDependencies": {
|
|
51
50
|
"@open-wc/testing": "3.1.6",
|
|
52
51
|
"@types/chai": "4.3.3",
|
|
52
|
+
"@types/fs-extra": "^9.0.13",
|
|
53
53
|
"@types/mocha": "10.0.0",
|
|
54
|
-
"@types/node": "18.8.
|
|
54
|
+
"@types/node": "18.8.3",
|
|
55
55
|
"@types/semver": "7.3.12",
|
|
56
56
|
"@web/dev-server-esbuild": "0.3.2",
|
|
57
57
|
"@web/test-runner": "0.14.0",
|
|
@@ -61,6 +61,7 @@
|
|
|
61
61
|
"augment-vir": "2.5.1",
|
|
62
62
|
"chai": "4.3.6",
|
|
63
63
|
"cspell": "6.12.0",
|
|
64
|
+
"fs-extra": "^10.1.0",
|
|
64
65
|
"markdown-code-example-inserter": "0.1.11",
|
|
65
66
|
"mocha": "10.0.0",
|
|
66
67
|
"prettier": "2.7.1",
|
|
@@ -73,7 +74,7 @@
|
|
|
73
74
|
"ts-node": "10.9.1",
|
|
74
75
|
"tsconfig-paths": "4.1.0",
|
|
75
76
|
"typescript": "4.8.4",
|
|
76
|
-
"vite": "3.1.
|
|
77
|
+
"vite": "3.1.6"
|
|
77
78
|
},
|
|
78
79
|
"engines": {
|
|
79
80
|
"node": ">=16",
|