Skip to content

Commit

Permalink
chore: bump version, changelog
Browse files Browse the repository at this point in the history
chore: add custom network to readme
  • Loading branch information
krigga committed Feb 15, 2024
1 parent c736e84 commit 4f5864f
Show file tree
Hide file tree
Showing 3 changed files with 48 additions and 6 deletions.
12 changes: 12 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,18 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [0.16.0] - 2024-02-15

### Added

- Added the `network` entry to the global config, which allows one to specify a custom network to be used instead of having to add `--custom` flags on each run
- Added the `convert` command which attempts to convert a legacy bash build script into a blueprint `.compile.ts` file
- Added the ability to pass any user data into the compile hooks

### Changed

- Improved the `verify` command

## [0.15.0] - 2023-12-15

### Added
Expand Down
40 changes: 35 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -103,26 +103,56 @@ Run in terminal:   `npx blueprint help`   or   `yarn blueprint he
2. Implement a deployment script in `scripts/deploy<CONTRACT>.ts`
3. Rely on the wrapper TypeScript class from `wrappers/<CONTRACT>.ts` to initialize the contract

## Plugins
## Config

A config may be created in order to control some of blueprint's features. If a config is needed, create a `blueprint.config.ts` file in the root of your project with something like this:
```typescript
import { Config } from '@ton/blueprint';

export const config: Config = {
// config contents
};
```
It is important that the config is exported, is named `config`, and is not `default` exported.

Config's features are explained below.

### Plugins

Blueprint has a plugin system to allow the community to develop their own additions for the ecosystem without the need to change blueprint's code.

In order to use plugins, create a `blueprint.config.ts` file in the root of your project with something like this:
In order to use plugins, add a `plugins` array to your config:
```typescript
import { Config } from '@ton/blueprint';
import { ScaffoldPlugin } from 'blueprint-scaffold';

export const config: Config = {
plugins: [new ScaffoldPlugin()],
plugins: [new ScaffoldPlugin()],
};
```
(This example shows how to add the [scaffold](https://github.com/1IxI1/blueprint-scaffold) plugin)

It is important that the config is exported, is named `config`, and is not `default` exported.

Here are some of the plugins developed by the community:
- [scaffold](https://github.com/1IxI1/blueprint-scaffold) - allows developers to quickly create a simple dapp automatically using the wrappers' code

### Custom network

A custom network may be specified by using the `--custom` flags, which you can read about by running `blueprint help run`, but it can be tiresome to use these at all times. Instead, to specify a custom network to always be used (unless `--custom` flags are present), add a `network` object to your config:
```typescript
import { Config } from '@ton/blueprint';

export const config: Config = {
network: {
endpoint: 'https://toncenter.com/api/v2/',
type: 'mainnet',
version: 'v2',
key: 'YOUR_API_KEY',
},
};
```

Properties of the `network` object have the same semantics as the `--custom` flags with respective names (see `blueprint help run`).

## Contributors

Special thanks to [@qdevstudio](https://t.me/qdevstudio) for their logo for blueprint.
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@ton/blueprint",
"version": "0.15.0",
"version": "0.16.0",
"description": "Framework for development of TON smart contracts",
"main": "dist/index.js",
"bin": "./dist/cli/cli.js",
Expand Down

0 comments on commit 4f5864f

Please sign in to comment.