@temir.ra/create-template 0.5.5 → 0.6.1
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/LICENSE +20 -20
- package/README.md +145 -90
- package/dist/CHANGELOG.md +123 -110
- package/dist/buildinfo.txt +1 -1
- package/dist/cli.bundle.js +0 -0
- package/dist/cli.bundle.js.map +1 -1
- package/dist/template/CHANGELOG.md +5 -5
- package/dist/template/README.md +162 -166
- package/dist/template/gitignore +8 -8
- package/dist/template/package.json +51 -46
- package/dist/template/scripts/build-bundle.ts +212 -212
- package/dist/template/scripts/buildinfo.ts +25 -25
- package/dist/template/scripts/import-map.json +1 -1
- package/dist/template/src/cli.ts +41 -41
- package/dist/template/src/package-urls.ts +8 -8
- package/dist/template/tests/buildinfo.test.ts +26 -26
- package/dist/template/tsconfig.json +33 -33
- package/package.json +7 -2
- package/dist/template/buildinfo.txt +0 -1
package/LICENSE
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2026 Temir Ra
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Temir Ra
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
21
|
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,90 +1,145 @@
|
|
|
1
|
-
# Introduction
|
|
2
|
-
|
|
3
|
-
This template scaffolds a package that is itself a template for other packages.
|
|
4
|
-
|
|
5
|
-
## Table of Contents
|
|
6
|
-
|
|
7
|
-
1. [Quick Start](#quick-start)
|
|
8
|
-
2. [Documentation](#documentation)
|
|
9
|
-
3. [DevOps](#devops)
|
|
10
|
-
1. [Change Management](#change-management)
|
|
11
|
-
2. [Registry](#registry)
|
|
12
|
-
3. [CI/CD Workflows](#cicd-workflows)
|
|
13
|
-
|
|
14
|
-
# Quick Start
|
|
15
|
-
|
|
16
|
-
```bash
|
|
17
|
-
#
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
#
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
npm
|
|
42
|
-
npm
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
git fetch
|
|
53
|
-
git
|
|
54
|
-
git
|
|
55
|
-
git
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
```
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
```
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
#
|
|
88
|
-
|
|
89
|
-
npm publish
|
|
90
|
-
```
|
|
1
|
+
# Introduction
|
|
2
|
+
|
|
3
|
+
This template scaffolds a package that is itself a template for other packages.
|
|
4
|
+
|
|
5
|
+
## Table of Contents
|
|
6
|
+
|
|
7
|
+
1. [Quick Start](#quick-start)
|
|
8
|
+
2. [Documentation](#documentation)
|
|
9
|
+
3. [DevOps](#devops)
|
|
10
|
+
1. [Change Management](#change-management)
|
|
11
|
+
2. [Registry](#registry)
|
|
12
|
+
3. [CI/CD Workflows](#cicd-workflows)
|
|
13
|
+
|
|
14
|
+
# Quick Start
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
# print the latest version
|
|
18
|
+
npm info "@temir.ra/create-template" version
|
|
19
|
+
|
|
20
|
+
# create/update a package from the template in the current directory
|
|
21
|
+
npm create --no-install --no-git "@temir.ra/template@latest" .
|
|
22
|
+
|
|
23
|
+
# set metadata in package.json
|
|
24
|
+
# update <BINARY_NAME> in package.json#bin
|
|
25
|
+
|
|
26
|
+
npm update
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
# Documentation
|
|
30
|
+
|
|
31
|
+
The following sections explain the configurations and conventions baked into the generated package. Useful when adapting it to fit specific needs.
|
|
32
|
+
|
|
33
|
+
*<DOCUMENTATION>*
|
|
34
|
+
|
|
35
|
+
# DevOps
|
|
36
|
+
|
|
37
|
+
```bash
|
|
38
|
+
npm install
|
|
39
|
+
npm update
|
|
40
|
+
|
|
41
|
+
npm run clean
|
|
42
|
+
npm run build
|
|
43
|
+
npm run tests
|
|
44
|
+
|
|
45
|
+
npx tsx dist/cli.bundle.js -- example/
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
```bash
|
|
49
|
+
git fetch upstream
|
|
50
|
+
git fetch origin
|
|
51
|
+
git fetch . upstream/main:origin/main
|
|
52
|
+
git fetch . origin/main:main
|
|
53
|
+
git push origin main
|
|
54
|
+
git merge --ff-only main
|
|
55
|
+
git push
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
## Change Management
|
|
59
|
+
|
|
60
|
+
1. Create a new branch for the change.
|
|
61
|
+
2. Make the changes and commit.
|
|
62
|
+
3. Bump the version in [`package.json`](package.json).
|
|
63
|
+
4. Add an entry for the new version in [`CHANGELOG.md`](CHANGELOG.md).
|
|
64
|
+
5. Pull-request the branch.
|
|
65
|
+
6. Ensure package artifacts are current.
|
|
66
|
+
7. Publish.
|
|
67
|
+
|
|
68
|
+
## Registry
|
|
69
|
+
|
|
70
|
+
`.npmrc`:
|
|
71
|
+
|
|
72
|
+
```ini
|
|
73
|
+
@temir.ra:registry=https://registry.npmjs.org/
|
|
74
|
+
//registry.npmjs.org/:_authToken=${NPMJSORG_REGISTRY_AUTH_TOKEN}
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
or `bunfig.toml`:
|
|
78
|
+
|
|
79
|
+
```toml
|
|
80
|
+
[install.scopes]
|
|
81
|
+
"temir.ra" = { url = "https://registry.npmjs.org/", token = "$NPMJSORG_REGISTRY_AUTH_TOKEN" }
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
```bash
|
|
85
|
+
# registry.npmjs.org/
|
|
86
|
+
export NPMJSORG_REGISTRY_AUTH_TOKEN=<AUTH_TOKEN>
|
|
87
|
+
# or
|
|
88
|
+
$env:NPMJSORG_REGISTRY_AUTH_TOKEN = "<AUTH_TOKEN>"
|
|
89
|
+
npm publish
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
## CI/CD Workflows
|
|
93
|
+
|
|
94
|
+
### NPM Build and Publish
|
|
95
|
+
|
|
96
|
+
⚠️ `.npmrc` configuring the package registry and its authentication token is required for the workflow to work.
|
|
97
|
+
|
|
98
|
+
|Parameter|Type|Description|
|
|
99
|
+
|-----|-----|-----|
|
|
100
|
+
|`NPM_RUNNER_LABEL`|Variable|The label of the runner to use for the workflow.|
|
|
101
|
+
|`NPM_ACCESS_TOKEN`|Secret|The authentication token for the package registry.|
|
|
102
|
+
|
|
103
|
+
`.github/workflows/npm-build-publish.yml`:
|
|
104
|
+
|
|
105
|
+
```yaml
|
|
106
|
+
name: NPM Build and Publish
|
|
107
|
+
|
|
108
|
+
on:
|
|
109
|
+
push:
|
|
110
|
+
branches:
|
|
111
|
+
- main
|
|
112
|
+
|
|
113
|
+
jobs:
|
|
114
|
+
publish:
|
|
115
|
+
runs-on: ${{ vars.NPM_RUNNER_LABEL }}
|
|
116
|
+
steps:
|
|
117
|
+
- uses: actions/checkout@v4
|
|
118
|
+
|
|
119
|
+
- name: Install
|
|
120
|
+
env:
|
|
121
|
+
NPMJSORG_REGISTRY_AUTH_TOKEN: ${{ secrets.NPM_ACCESS_TOKEN }}
|
|
122
|
+
run: npm ci
|
|
123
|
+
|
|
124
|
+
- name: Build
|
|
125
|
+
run: npm run build
|
|
126
|
+
|
|
127
|
+
- name: Test
|
|
128
|
+
run: npm run tests
|
|
129
|
+
|
|
130
|
+
- name: Publish
|
|
131
|
+
env:
|
|
132
|
+
NPMJSORG_REGISTRY_AUTH_TOKEN: ${{ secrets.NPM_ACCESS_TOKEN }}
|
|
133
|
+
run: |
|
|
134
|
+
PKG_NAME=$(node -p "require('./package.json').name")
|
|
135
|
+
PKG_VERSION=$(node -p "require('./package.json').version")
|
|
136
|
+
NPM_TAG="latest"
|
|
137
|
+
if echo "$PKG_VERSION" | grep -q -- '-'; then
|
|
138
|
+
NPM_TAG="next"
|
|
139
|
+
fi
|
|
140
|
+
if npm view "$PKG_NAME@$PKG_VERSION" version >/dev/null 2>&1; then
|
|
141
|
+
echo "$PKG_NAME@$PKG_VERSION already published, skipping."
|
|
142
|
+
else
|
|
143
|
+
npm publish --tag "$NPM_TAG"
|
|
144
|
+
fi
|
|
145
|
+
```
|
package/dist/CHANGELOG.md
CHANGED
|
@@ -1,110 +1,123 @@
|
|
|
1
|
-
# Version 0
|
|
2
|
-
|
|
3
|
-
## 0.
|
|
4
|
-
|
|
5
|
-
1. Updated template files from `ts-lib@0.
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
## 0.4
|
|
21
|
-
|
|
22
|
-
1.
|
|
23
|
-
|
|
24
|
-
## 0.
|
|
25
|
-
|
|
26
|
-
1.
|
|
27
|
-
|
|
28
|
-
## 0.4.
|
|
29
|
-
|
|
30
|
-
1.
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
4.
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
## 0.
|
|
46
|
-
|
|
47
|
-
1.
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
## 0.1.
|
|
74
|
-
|
|
75
|
-
1.
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
## 0.1.
|
|
101
|
-
|
|
102
|
-
1.
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
1
|
+
# Version 0
|
|
2
|
+
|
|
3
|
+
## 0.6.1
|
|
4
|
+
|
|
5
|
+
1. Updated template files from `ts-lib@0.15.1-pre.1` template.
|
|
6
|
+
2. Updated files from `self` as template.
|
|
7
|
+
3. Parametrized binary name in `template/package.json#bin`.
|
|
8
|
+
4. Updated workflow variables and secrets.
|
|
9
|
+
|
|
10
|
+
## 0.6.0
|
|
11
|
+
|
|
12
|
+
1. Updated template files from `ts-lib@0.15.0-pre.4` template.
|
|
13
|
+
2. Updated from `self` as template.
|
|
14
|
+
3. Added Build and Publish Workflow.
|
|
15
|
+
|
|
16
|
+
## 0.5.5
|
|
17
|
+
|
|
18
|
+
1. Updated template files from `ts-lib@0.14.0-pre.3` template.
|
|
19
|
+
|
|
20
|
+
## 0.5.4
|
|
21
|
+
|
|
22
|
+
1. Minor fixes.
|
|
23
|
+
|
|
24
|
+
## 0.5.0
|
|
25
|
+
|
|
26
|
+
1. Moved `template/` from package root to `dist/`.
|
|
27
|
+
|
|
28
|
+
## 0.4.4
|
|
29
|
+
|
|
30
|
+
1. Synced template files with `ts-lib@0.13.0-pre.7` template.
|
|
31
|
+
2. Synced files with `self` as template.
|
|
32
|
+
|
|
33
|
+
## 0.4.3
|
|
34
|
+
|
|
35
|
+
1. Fixed versioning issue.
|
|
36
|
+
|
|
37
|
+
## 0.4.2
|
|
38
|
+
|
|
39
|
+
1. Updated from `ts-lib@0.12.0-pre.1` template.
|
|
40
|
+
|
|
41
|
+
## 0.4.1
|
|
42
|
+
|
|
43
|
+
1. Minor updates in the README.
|
|
44
|
+
|
|
45
|
+
## 0.4.0
|
|
46
|
+
|
|
47
|
+
1. Synced template files with `ts-lob@0.11.0-pre.11` template.
|
|
48
|
+
2. Replaced `bun run` with `npmx tsx` in DevOps commands.
|
|
49
|
+
3. Cleaned up Quick Start section.
|
|
50
|
+
4. Updated files from self as template.
|
|
51
|
+
|
|
52
|
+
## 0.3.0
|
|
53
|
+
|
|
54
|
+
1. Synced template files with `ts-lib@0.10.0-pre.1` template.
|
|
55
|
+
2. Added `node:` prefix to imports.
|
|
56
|
+
3. Updated files from `self`.
|
|
57
|
+
|
|
58
|
+
## 0.2.1
|
|
59
|
+
|
|
60
|
+
1. Updated Quick Start section.
|
|
61
|
+
|
|
62
|
+
## 0.2.0
|
|
63
|
+
|
|
64
|
+
1. Synced with `ts-lib@0.9.0` template.
|
|
65
|
+
2. Switched to `esbuild` for bundling.
|
|
66
|
+
3. Updated Quick Start section to reflect typical usage patterns.
|
|
67
|
+
4. Updated files from self.
|
|
68
|
+
|
|
69
|
+
## 0.1.11
|
|
70
|
+
|
|
71
|
+
1. Synced with `ts-lib@0.8.4` template.
|
|
72
|
+
|
|
73
|
+
## 0.1.10
|
|
74
|
+
|
|
75
|
+
1. Synced with `ts-lib` template.
|
|
76
|
+
|
|
77
|
+
## 0.1.9
|
|
78
|
+
|
|
79
|
+
1. Fixed template assets paths.
|
|
80
|
+
|
|
81
|
+
## 0.1.8
|
|
82
|
+
|
|
83
|
+
1. Updated template files from `ts-lib@0.8.0` template.
|
|
84
|
+
2. Updated files from self.
|
|
85
|
+
|
|
86
|
+
## 0.1.7
|
|
87
|
+
|
|
88
|
+
1. Updated `typescript` to `6.0.3`.
|
|
89
|
+
2. Updated template files from `ts-lib` template.
|
|
90
|
+
|
|
91
|
+
## 0.1.6
|
|
92
|
+
|
|
93
|
+
1. Removed `bun run --watch scripts/dev.ts` from DevOps commands in `README.md` and `template/README.md`.
|
|
94
|
+
|
|
95
|
+
## 0.1.5
|
|
96
|
+
|
|
97
|
+
1. Updated metadata in `package.json` and `template/package.json`.
|
|
98
|
+
2. Added `bun run --watch scripts/dev.ts` to DevOps commands in `README.md` and `template/README.md`.
|
|
99
|
+
|
|
100
|
+
## 0.1.4
|
|
101
|
+
|
|
102
|
+
1. Updated `template/` files from `@temir.ra/ts-lib@0.7.2` template.
|
|
103
|
+
2. Updated the description in `package.json`.
|
|
104
|
+
|
|
105
|
+
## 0.1.3
|
|
106
|
+
|
|
107
|
+
1. Removed `scripts/dev.ts`.
|
|
108
|
+
|
|
109
|
+
## 0.1.2
|
|
110
|
+
|
|
111
|
+
1. Updated `package.json` from `create-ts-lib` template.
|
|
112
|
+
|
|
113
|
+
## 0.1.1
|
|
114
|
+
|
|
115
|
+
1. Added clarifications to `README.md`.
|
|
116
|
+
|
|
117
|
+
## 0.1.0
|
|
118
|
+
|
|
119
|
+
1. First published version.
|
|
120
|
+
|
|
121
|
+
## 0.0.0
|
|
122
|
+
|
|
123
|
+
1. Package created.
|
package/dist/buildinfo.txt
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
0.
|
|
1
|
+
0.6.1+99d380f
|
package/dist/cli.bundle.js
CHANGED
|
File without changes
|
package/dist/cli.bundle.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../src/cli.ts", "../src/package-urls.ts"],
|
|
4
|
-
"sourcesContent": ["#!/usr/bin/env node\
|
|
4
|
+
"sourcesContent": ["#!/usr/bin/env node\n\nimport { cpSync, readFileSync, renameSync, writeFileSync } from 'node:fs';\nimport { resolve } from 'node:path';\nimport {\n templateUrl,\n changelogUrl,\n buildinfoUrl,\n readmeUrl\n} from './package-urls.js';\n\n\ntry {\n\n const packageNameArgument = process.argv[2];\n if (!packageNameArgument)\n throw new Error('First argument must be the package name (e.g. \"my-package\" or \"@my-scope/my-package\").');\n const packageName = packageNameArgument.replace(/\\\\/g, '/');\n\n const destinationPath = resolve(process.cwd(), packageName);\n\n cpSync(templateUrl, destinationPath, { recursive: true });\n cpSync(changelogUrl, resolve(destinationPath, 'CHANGELOG-template.md'));\n cpSync(buildinfoUrl, resolve(destinationPath, 'buildinfo-template.txt'));\n cpSync(readmeUrl, resolve(destinationPath, 'README-template.md'));\n\n const packageJsonPath = resolve(destinationPath, 'package.json');\n const packageJson = JSON.parse(readFileSync(packageJsonPath, 'utf-8'));\n packageJson.name = packageName;\n writeFileSync(packageJsonPath, JSON.stringify(packageJson, null, 2));\n\n renameSync(resolve(destinationPath, 'gitignore'), resolve(destinationPath, '.gitignore'));\n\n console.log(`Template has been successfully instantiated at '${destinationPath}' with package name '${packageName}'.`);\n\n}\ncatch (error) {\n const err = error instanceof Error ? error : new Error(String(error));\n console.error('Error:', err.message);\n process.exit(1);\n}\n", "export const packageUrl: URL = new URL('../', import.meta.url);\n\nexport const distUrl: URL = new URL('dist/', packageUrl);\nexport const buildinfoUrl: URL = new URL('buildinfo.txt', distUrl);\nexport const changelogUrl: URL = new URL('CHANGELOG.md', distUrl);\nexport const readmeUrl: URL = new URL('README.md', packageUrl);\n\nexport const templateUrl: URL = new URL('template/', distUrl);\n"],
|
|
5
5
|
"mappings": ";AAEA,OAAS,UAAAA,EAAQ,gBAAAC,EAAc,cAAAC,EAAY,iBAAAC,MAAqB,UAChE,OAAS,WAAAC,MAAe,YCHjB,IAAMC,EAAkB,IAAI,IAAI,MAAO,YAAY,GAAG,EAEhDC,EAAe,IAAI,IAAI,QAASD,CAAU,EAC1CE,EAAoB,IAAI,IAAI,gBAAiBD,CAAO,EACpDE,EAAoB,IAAI,IAAI,eAAgBF,CAAO,EACnDG,EAAiB,IAAI,IAAI,YAAaJ,CAAU,EAEhDK,EAAmB,IAAI,IAAI,YAAaJ,CAAO,EDK5D,GAAI,CAEA,IAAMK,EAAsB,QAAQ,KAAK,CAAC,EAC1C,GAAI,CAACA,EACD,MAAM,IAAI,MAAM,wFAAwF,EAC5G,IAAMC,EAAcD,EAAoB,QAAQ,MAAO,GAAG,EAEpDE,EAAkBC,EAAQ,QAAQ,IAAI,EAAGF,CAAW,EAE1DG,EAAOC,EAAaH,EAAiB,CAAE,UAAW,EAAK,CAAC,EACxDE,EAAOE,EAAcH,EAAQD,EAAiB,uBAAuB,CAAC,EACtEE,EAAOG,EAAcJ,EAAQD,EAAiB,wBAAwB,CAAC,EACvEE,EAAOI,EAAWL,EAAQD,EAAiB,oBAAoB,CAAC,EAEhE,IAAMO,EAAkBN,EAAQD,EAAiB,cAAc,EACzDQ,EAAc,KAAK,MAAMC,EAAaF,EAAiB,OAAO,CAAC,EACrEC,EAAY,KAAOT,EACnBW,EAAcH,EAAiB,KAAK,UAAUC,EAAa,KAAM,CAAC,CAAC,EAEnEG,EAAWV,EAAQD,EAAiB,WAAW,EAAGC,EAAQD,EAAiB,YAAY,CAAC,EAExF,QAAQ,IAAI,mDAAmDA,CAAe,wBAAwBD,CAAW,IAAI,CAEzH,OACOa,EAAO,CACV,IAAMC,EAAMD,aAAiB,MAAQA,EAAQ,IAAI,MAAM,OAAOA,CAAK,CAAC,EACpE,QAAQ,MAAM,SAAUC,EAAI,OAAO,EACnC,QAAQ,KAAK,CAAC,CAClB",
|
|
6
6
|
"names": ["cpSync", "readFileSync", "renameSync", "writeFileSync", "resolve", "packageUrl", "distUrl", "buildinfoUrl", "changelogUrl", "readmeUrl", "templateUrl", "packageNameArgument", "packageName", "destinationPath", "resolve", "cpSync", "templateUrl", "changelogUrl", "buildinfoUrl", "readmeUrl", "packageJsonPath", "packageJson", "readFileSync", "writeFileSync", "renameSync", "error", "err"]
|
|
7
7
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
# Version 0
|
|
2
|
-
|
|
3
|
-
## 0.0.0
|
|
4
|
-
|
|
5
|
-
1. Package created.
|
|
1
|
+
# Version 0
|
|
2
|
+
|
|
3
|
+
## 0.0.0
|
|
4
|
+
|
|
5
|
+
1. Package created.
|