create-ton 0.0.10 → 0.1.0
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/CHANGELOG.md +24 -0
- package/dist/cli.js +14 -5
- package/dist/template/.prettierignore +1 -0
- package/dist/template/README.md +5 -11
- package/dist/template/package.json +10 -10
- package/package.json +5 -5
- package/dist/template/LICENSE +0 -21
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,30 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [0.1.0] - 2023-03-21
|
|
9
|
+
|
|
10
|
+
### Added
|
|
11
|
+
|
|
12
|
+
- Added support for [TACT](https://github.com/tact-lang/tact), including TACT smart contract templates
|
|
13
|
+
- Added `.prettierignore` to template to ignore generated TACT files
|
|
14
|
+
|
|
15
|
+
### Changed
|
|
16
|
+
|
|
17
|
+
- Updated template dependencies, including blueprint to 0.6.0, sandbox to 0.6.1, test-utils to 0.2.0
|
|
18
|
+
- Edited template's `README.md`
|
|
19
|
+
- Changed template's `.gitignore` to contain a newline at the end
|
|
20
|
+
- Updated dependencies
|
|
21
|
+
|
|
22
|
+
### Removed
|
|
23
|
+
|
|
24
|
+
- Removed dubious `LICENSE` file from template
|
|
25
|
+
|
|
26
|
+
## [0.0.11] - 2023-03-02
|
|
27
|
+
|
|
28
|
+
### Changed
|
|
29
|
+
|
|
30
|
+
- Updated template dependencies' versions: blueprint to 0.4.1, sandbox to 0.5.1, ton to 13.4.1, ton-core to 0.48.0
|
|
31
|
+
|
|
8
32
|
## [0.0.10] - 2023-02-27
|
|
9
33
|
|
|
10
34
|
### Added
|
package/dist/cli.js
CHANGED
|
@@ -32,12 +32,20 @@ async function main() {
|
|
|
32
32
|
type: 'list',
|
|
33
33
|
choices: [
|
|
34
34
|
{
|
|
35
|
-
name: 'An empty contract',
|
|
36
|
-
value: 'empty',
|
|
35
|
+
name: 'An empty contract (FunC)',
|
|
36
|
+
value: 'func-empty',
|
|
37
37
|
},
|
|
38
38
|
{
|
|
39
|
-
name: 'A simple counter contract',
|
|
40
|
-
value: 'counter',
|
|
39
|
+
name: 'A simple counter contract (FunC)',
|
|
40
|
+
value: 'func-counter',
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
name: 'An empty contract (TACT)',
|
|
44
|
+
value: 'tact-empty',
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
name: 'A simple counter contract (TACT)',
|
|
48
|
+
value: 'tact-counter',
|
|
41
49
|
},
|
|
42
50
|
],
|
|
43
51
|
},
|
|
@@ -53,7 +61,8 @@ async function main() {
|
|
|
53
61
|
}
|
|
54
62
|
await fs_extra_1.default.writeFile(path_1.default.join(name, '.gitignore'), `node_modules
|
|
55
63
|
temp
|
|
56
|
-
build
|
|
64
|
+
build
|
|
65
|
+
`);
|
|
57
66
|
await fs_extra_1.default.writeFile(path_1.default.join(name, PACKAGE_JSON), (await fs_extra_1.default.readFile(path_1.default.join(basePath, PACKAGE_JSON))).toString().replace('{{name}}', name));
|
|
58
67
|
console.log(`[2/${steps}] Installing dependencies...\n`);
|
|
59
68
|
const execOpts = {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
build
|
package/dist/template/README.md
CHANGED
|
@@ -1,9 +1,7 @@
|
|
|
1
|
-
# TON project
|
|
1
|
+
# TON project
|
|
2
2
|
|
|
3
3
|
Starter template for a new TON project - FunC contracts, unit tests, compilation and deployment scripts.
|
|
4
4
|
|
|
5
|
-
> This repo is a work in progress and is subject to change
|
|
6
|
-
|
|
7
5
|
## Layout
|
|
8
6
|
|
|
9
7
|
- `contracts` - contains the source code of all the smart contracts of the project and their dependencies.
|
|
@@ -11,18 +9,13 @@ Starter template for a new TON project - FunC contracts, unit tests, compilation
|
|
|
11
9
|
- `tests` - tests for the contracts. Would typically use the wrappers.
|
|
12
10
|
- `scripts` - contains scripts used by the project, mainly the deployment scripts.
|
|
13
11
|
|
|
14
|
-
We ask the community to provide any comments on this layout, the wanted/required changes, or even suggestions for entirely different project structures and/or tool concepts.
|
|
15
|
-
|
|
16
|
-
PRs are welcome!
|
|
17
|
-
|
|
18
12
|
## Repo contents / tech stack
|
|
19
13
|
1. Compiling FunC - [https://github.com/ton-community/func-js](https://github.com/ton-community/func-js)
|
|
20
|
-
2. Testing TON smart contracts - [https://github.com/ton-community/sandbox
|
|
21
|
-
3. Deployment of contracts is supported with [TON Connect 2](https://github.com/ton-connect/), [Tonhub wallet](https://tonhub.com/) or via a direct `ton://` deeplink
|
|
14
|
+
2. Testing TON smart contracts - [https://github.com/ton-community/sandbox](https://github.com/ton-community/sandbox)
|
|
15
|
+
3. Deployment of contracts is supported with [TON Connect 2](https://github.com/ton-connect/), [Tonhub wallet](https://tonhub.com/), using mnemonics, or via a direct `ton://` deeplink
|
|
22
16
|
|
|
23
17
|
## How to use
|
|
24
|
-
*
|
|
25
|
-
* Run `yarn install`
|
|
18
|
+
* Run `npm create ton@latest`
|
|
26
19
|
|
|
27
20
|
### Building a contract
|
|
28
21
|
1. Interactively
|
|
@@ -41,6 +34,7 @@ PRs are welcome!
|
|
|
41
34
|
1. With a TON Connect compatible wallet
|
|
42
35
|
2. A `ton://` deep link / QR code
|
|
43
36
|
3. Tonhub wallet
|
|
37
|
+
4. Mnemonic
|
|
44
38
|
5. Deploy the contract
|
|
45
39
|
2. Non-interactively
|
|
46
40
|
1. Run `yarn blueprint run <CONTRACT> --<NETWORK> --<DEPLOY_METHOD>`
|
|
@@ -6,18 +6,18 @@
|
|
|
6
6
|
"test": "jest"
|
|
7
7
|
},
|
|
8
8
|
"devDependencies": {
|
|
9
|
-
"@ton-community/blueprint": "^0.
|
|
10
|
-
"@ton-community/sandbox": "^0.
|
|
11
|
-
"@ton-community/test-utils": "^0.0
|
|
12
|
-
"@types/jest": "^29.
|
|
13
|
-
"@types/node": "^18.
|
|
14
|
-
"jest": "^29.
|
|
15
|
-
"prettier": "^2.8.
|
|
16
|
-
"ton": "^13.
|
|
17
|
-
"ton-core": "^0.
|
|
9
|
+
"@ton-community/blueprint": "^0.6.0",
|
|
10
|
+
"@ton-community/sandbox": "^0.6.1",
|
|
11
|
+
"@ton-community/test-utils": "^0.2.0",
|
|
12
|
+
"@types/jest": "^29.5.0",
|
|
13
|
+
"@types/node": "^18.15.5",
|
|
14
|
+
"jest": "^29.5.0",
|
|
15
|
+
"prettier": "^2.8.6",
|
|
16
|
+
"ton": "^13.4.1",
|
|
17
|
+
"ton-core": "^0.48.0",
|
|
18
18
|
"ton-crypto": "^3.2.0",
|
|
19
19
|
"ts-jest": "^29.0.5",
|
|
20
20
|
"ts-node": "^10.9.1",
|
|
21
|
-
"typescript": "^4.9.
|
|
21
|
+
"typescript": "^4.9.5"
|
|
22
22
|
}
|
|
23
23
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "create-ton",
|
|
3
|
-
"version": "0.0
|
|
3
|
+
"version": "0.1.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "Tool to quickly create TON projects",
|
|
6
6
|
"author": "TonTech",
|
|
@@ -19,14 +19,14 @@
|
|
|
19
19
|
},
|
|
20
20
|
"devDependencies": {
|
|
21
21
|
"@types/fs-extra": "^11.0.1",
|
|
22
|
-
"@types/inquirer": "^8.2.
|
|
23
|
-
"@types/node": "^18.
|
|
24
|
-
"prettier": "^2.8.
|
|
22
|
+
"@types/inquirer": "^8.2.6",
|
|
23
|
+
"@types/node": "^18.15.5",
|
|
24
|
+
"prettier": "^2.8.6",
|
|
25
25
|
"typescript": "^4.9.5"
|
|
26
26
|
},
|
|
27
27
|
"dependencies": {
|
|
28
28
|
"chalk": "^4.1.0",
|
|
29
|
-
"fs-extra": "^11.1.
|
|
29
|
+
"fs-extra": "^11.1.1",
|
|
30
30
|
"inquirer": "^8.2.5"
|
|
31
31
|
}
|
|
32
32
|
}
|
package/dist/template/LICENSE
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2023 Tontech
|
|
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
|
-
SOFTWARE.
|