From 2d893e49e9c7692b85f4c3c15fc22f85e7b63fe1 Mon Sep 17 00:00:00 2001 From: Suprun Date: Mon, 13 Jan 2025 22:30:48 +0300 Subject: [PATCH 1/8] docs: add Code of Conduct file --- docs/CODE_OF_CONDUCT.md | 132 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 132 insertions(+) create mode 100644 docs/CODE_OF_CONDUCT.md diff --git a/docs/CODE_OF_CONDUCT.md b/docs/CODE_OF_CONDUCT.md new file mode 100644 index 0000000..24ec622 --- /dev/null +++ b/docs/CODE_OF_CONDUCT.md @@ -0,0 +1,132 @@ +# Contributor Covenant Code of Conduct + +## Our Pledge + +We as members, contributors, and leaders pledge to make participation in our +community a harassment-free experience for everyone, regardless of age, body +size, visible or invisible disability, ethnicity, sex characteristics, gender +identity and expression, level of experience, education, socio-economic status, +nationality, personal appearance, race, caste, color, religion, or sexual +identity and orientation. + +We pledge to act and interact in ways that contribute to an open, welcoming, +diverse, inclusive, and healthy community. + +## Our Standards + +Examples of behavior that contributes to a positive environment for our +community include: + +- Demonstrating empathy and kindness toward other people +- Being respectful of differing opinions, viewpoints, and experiences +- Giving and gracefully accepting constructive feedback +- Accepting responsibility and apologizing to those affected by our mistakes, + and learning from the experience +- Focusing on what is best not just for us as individuals, but for the overall + community + +Examples of unacceptable behavior include: + +- The use of sexualized language or imagery, and sexual attention or advances of + any kind +- Trolling, insulting or derogatory comments, and personal or political attacks +- Public or private harassment +- Publishing others' private information, such as a physical or email address, + without their explicit permission +- Other conduct which could reasonably be considered inappropriate in a + professional setting + +## Enforcement Responsibilities + +Community leaders are responsible for clarifying and enforcing our standards of +acceptable behavior and will take appropriate and fair corrective action in +response to any behavior that they deem inappropriate, threatening, offensive, +or harmful. + +Community leaders have the right and responsibility to remove, edit, or reject +comments, commits, code, wiki edits, issues, and other contributions that are +not aligned to this Code of Conduct, and will communicate reasons for moderation +decisions when appropriate. + +## Scope + +This Code of Conduct applies within all community spaces, and also applies when +an individual is officially representing the community in public spaces. +Examples of representing our community include using an official email address, +posting via an official social media account, or acting as an appointed +representative at an online or offline event. + +## Enforcement + +Instances of abusive, harassing, or otherwise unacceptable behavior may be +reported to the community leaders responsible for enforcement at +[INSERT CONTACT METHOD]. +All complaints will be reviewed and investigated promptly and fairly. + +All community leaders are obligated to respect the privacy and security of the +reporter of any incident. + +## Enforcement Guidelines + +Community leaders will follow these Community Impact Guidelines in determining +the consequences for any action they deem in violation of this Code of Conduct: + +### 1. Correction + +**Community Impact**: Use of inappropriate language or other behavior deemed +unprofessional or unwelcome in the community. + +**Consequence**: A private, written warning from community leaders, providing +clarity around the nature of the violation and an explanation of why the +behavior was inappropriate. A public apology may be requested. + +### 2. Warning + +**Community Impact**: A violation through a single incident or series of +actions. + +**Consequence**: A warning with consequences for continued behavior. No +interaction with the people involved, including unsolicited interaction with +those enforcing the Code of Conduct, for a specified period of time. This +includes avoiding interactions in community spaces as well as external channels +like social media. Violating these terms may lead to a temporary or permanent +ban. + +### 3. Temporary Ban + +**Community Impact**: A serious violation of community standards, including +sustained inappropriate behavior. + +**Consequence**: A temporary ban from any sort of interaction or public +communication with the community for a specified period of time. No public or +private interaction with the people involved, including unsolicited interaction +with those enforcing the Code of Conduct, is allowed during this period. +Violating these terms may lead to a permanent ban. + +### 4. Permanent Ban + +**Community Impact**: Demonstrating a pattern of violation of community +standards, including sustained inappropriate behavior, harassment of an +individual, or aggression toward or disparagement of classes of individuals. + +**Consequence**: A permanent ban from any sort of public interaction within the +community. + +## Attribution + +This Code of Conduct is adapted from the [Contributor Covenant][homepage], +version 2.1, available at +[https://www.contributor-covenant.org/version/2/1/code_of_conduct.html][v2.1]. + +Community Impact Guidelines were inspired by +[Mozilla's code of conduct enforcement ladder][Mozilla CoC]. + +For answers to common questions about this code of conduct, see the FAQ at +[https://www.contributor-covenant.org/faq][FAQ]. Translations are available at +[https://www.contributor-covenant.org/translations][translations]. + +[homepage]: https://www.contributor-covenant.org +[v2.1]: https://www.contributor-covenant.org/version/2/1/code_of_conduct.html +[Mozilla CoC]: https://github.com/mozilla/diversity +[FAQ]: https://www.contributor-covenant.org/faq +[translations]: https://www.contributor-covenant.org/translations From 4d6ca16e88dff8f6fb651b1aaaa91b83b6719a54 Mon Sep 17 00:00:00 2001 From: Suprun Date: Mon, 13 Jan 2025 22:38:11 +0300 Subject: [PATCH 2/8] chore: add pull request template --- .github/pull_request_template.md | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 .github/pull_request_template.md diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md new file mode 100644 index 0000000..06adf2e --- /dev/null +++ b/.github/pull_request_template.md @@ -0,0 +1,5 @@ +**Summary of changes**: + +Please include short summary of changes + +Close # (issue) From bef6b379519241edd20543cbb600eb032b0d99ba Mon Sep 17 00:00:00 2001 From: Suprun Date: Mon, 13 Jan 2025 22:38:43 +0300 Subject: [PATCH 3/8] chore: add issue templates --- .github/ISSUE_TEMPLATE/bug_report.yml | 36 ++++++++++++++++++++ .github/ISSUE_TEMPLATE/config.yml | 1 + .github/ISSUE_TEMPLATE/feature_request.yml | 38 ++++++++++++++++++++++ 3 files changed, 75 insertions(+) create mode 100644 .github/ISSUE_TEMPLATE/bug_report.yml create mode 100644 .github/ISSUE_TEMPLATE/config.yml create mode 100644 .github/ISSUE_TEMPLATE/feature_request.yml diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml new file mode 100644 index 0000000..a8941a7 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -0,0 +1,36 @@ +name: Bug Report +description: Submit bug report. +title: 'Bug: ' +labels: ['bug'] +body: + - type: markdown + attributes: + value: | + Thanks for taking the time to fill out this bug report! + - type: textarea + id: what-happened + attributes: + label: To reproduce + description: Steps to reproduce the behavior + placeholder: | + 1. Send message 0x000 '...' + 2. Contract exit with 1 '....' + 3. See error + validations: + required: true + - type: textarea + id: actual + attributes: + label: Actual result + description: What actually happened? + placeholder: Not OK + validations: + required: true + - type: textarea + id: expected + attributes: + label: Expected result + description: What did you expect to happen? + placeholder: OK + validations: + required: true diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml new file mode 100644 index 0000000..0086358 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -0,0 +1 @@ +blank_issues_enabled: true diff --git a/.github/ISSUE_TEMPLATE/feature_request.yml b/.github/ISSUE_TEMPLATE/feature_request.yml new file mode 100644 index 0000000..f68ff4b --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_request.yml @@ -0,0 +1,38 @@ +name: Feature request +description: Suggest an idea for this project. +title: 'Add ' +labels: ['enhancement'] +body: + - type: markdown + attributes: + value: | + Thank for your attention to project! + - type: textarea + id: related + attributes: + label: Is your feature request related to a problem + description: Please describe + placeholder: A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] + validations: + required: true + - type: textarea + id: solution + attributes: + label: Describe the solution you'd like + description: A clear and concise description of what you want to happen. + validations: + required: false + - type: textarea + id: alternatives + attributes: + label: Describe alternatives you've considered + description: A clear and concise description of any alternative solutions or features you've considered. + validations: + required: false + - type: textarea + id: context + attributes: + label: Additional context + description: Add any other context or screenshots about the feature request here. + validations: + required: false From c8bdef4c257538ba32c59a2ee726b6b0fd647e81 Mon Sep 17 00:00:00 2001 From: Suprun Date: Mon, 13 Jan 2025 22:40:25 +0300 Subject: [PATCH 4/8] chore: update CI jobs --- .github/workflows/ci.yml | 39 ++++++++++++++++++++++++++++ .github/workflows/commitlint.yml | 44 +++++++++++++++----------------- .github/workflows/contracts.yml | 28 -------------------- 3 files changed, 60 insertions(+), 51 deletions(-) create mode 100644 .github/workflows/ci.yml delete mode 100644 .github/workflows/contracts.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..4974932 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,39 @@ +name: Continuous Integration + +on: + pull_request: + branches: ['master'] + merge_group: + types: [checks_requested] + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: 22 + cache: 'npm' + cache-dependency-path: 'package-lock.json' + - name: NPM Install + run: npm install + - name: Build contracts + run: npm run build + + test: + needs: build + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 + with: + node-version: 22 + cache: 'npm' + cache-dependency-path: 'package-lock.json' + - name: NPM Install + run: npm install + - name: Run tests + run: npm test diff --git a/.github/workflows/commitlint.yml b/.github/workflows/commitlint.yml index 9422c43..f9042ef 100644 --- a/.github/workflows/commitlint.yml +++ b/.github/workflows/commitlint.yml @@ -1,31 +1,29 @@ name: Commit Lint on: - push: - branches: [ "master" ] - pull_request: - branches: [ "master" ] - merge_group: - types: [ checks_requested ] + pull_request: + branches: ['master'] + merge_group: + types: [checks_requested] jobs: - commitlint: - runs-on: ubuntu-22.04 - steps: - - uses: actions/checkout@v3 - with: - fetch-depth: 0 - - name: Install commitlint - run: npm install + commitlint: + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v3 + with: + fetch-depth: 0 + - name: Install commitlint + run: npm install - - name: Validate current commit (last commit) with commitlint - if: github.event_name == 'push' - run: npx commitlint --last --verbose + - name: Validate current commit (last commit) with commitlint + if: github.event_name == 'push' + run: npx commitlint --last --verbose - - name: Validate merge queue - if: github.event_name == 'merge_group' - run: npx commitlint --last --verbose + - name: Validate merge queue + if: github.event_name == 'merge_group' + run: npx commitlint --last --verbose - - name: Validate PR commits with commitlint - if: github.event_name == 'pull_request' - run: npx commitlint --from ${{ github.event.pull_request.head.sha }}~${{ github.event.pull_request.commits }} --to ${{ github.event.pull_request.head.sha }} --verbose + - name: Validate PR commits with commitlint + if: github.event_name == 'pull_request' + run: npx commitlint --from ${{ github.event.pull_request.head.sha }}~${{ github.event.pull_request.commits }} --to ${{ github.event.pull_request.head.sha }} --verbose diff --git a/.github/workflows/contracts.yml b/.github/workflows/contracts.yml deleted file mode 100644 index 3ee43b0..0000000 --- a/.github/workflows/contracts.yml +++ /dev/null @@ -1,28 +0,0 @@ -name: Contract checks - -on: - push: - branches: [ "master" ] - pull_request: - branches: [ "master" ] - merge_group: - types: [ checks_requested ] - -jobs: - build: - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-node@v4 - with: - node-version: 22 - - - name: NPM Install - run: npm install - - - name: Build contracts - run: npm run build - - - name: Run tests - run: npm test From 514e734303e3ff23c0988b85591d9b573c20c388 Mon Sep 17 00:00:00 2001 From: Suprun Date: Mon, 13 Jan 2025 22:45:52 +0300 Subject: [PATCH 5/8] docs: add docs section --- README.md | 88 +++++++------------------------------------- docs/CONTRIBUTING.md | 79 +++++++++++++++++++++++++++++++++++++++ docs/PROCESSING.md | 72 ++++++++++++++++++++++++++++++++++++ docs/SECURITY.md | 3 ++ docs/SUMMARY.md | 8 ++++ 5 files changed, 176 insertions(+), 74 deletions(-) create mode 100644 docs/CONTRIBUTING.md create mode 100644 docs/PROCESSING.md create mode 100644 docs/SECURITY.md create mode 100644 docs/SUMMARY.md diff --git a/README.md b/README.md index 35ad055..97ea1e9 100644 --- a/README.md +++ b/README.md @@ -6,88 +6,28 @@ â¤ī¸ I'll be very grateful for any kind of contribution: code, docs, issues, bug reports, github stars or whatever - - # Development This is default Tact blueprint project with default commands: -- `npm run build` - build project and compile contracts -- `npm test` - run contracts tests -- `npx blueprint run` - execute script from `/scripts` directory +- `npm run build` - build project and compile contracts +- `npm test` - run contracts tests +- `npx blueprint run` - execute script from `/scripts` directory # Docs -## Project structure +[Read our docs in Gitbook](https://docs.supadupa.space/jetton) + +## How can i contribute? + +We are very appreciate your attention to project. Please read our [contributing guide](docs/CONTRIBUTING.md). + +## How can i process it? -- `contracts` - source code of all the smart contracts -- - `jetton` - entrypoints of jetton contracts with dependencies (traits) specified -- - - `master.tact` - jetton master contract entrypoint -- - - `wallet.tact` - jetton wallet contract entrypoint -- - `teps` - traits with [TEPs](https://github.com/ton-blockchain/TEPs/) realization -- - - `messages` - API messages for TEP traits -- - - - `discoverable` - messages related to the tep89 "discoverable" trait -- - - - `jettonStandard` - messages related to the tep74 jettons standard -- - - `tep64.tact` - trait implementation of [TEP 64](https://github.com/ton-blockchain/TEPs/blob/master/text/0064-token-data-standard.md) -- - - `tep74.tact` - trait implementation of [TEP 74](https://github.com/ton-blockchain/TEPs/blob/master/text/0074-jettons-standard.md) -- - - `tep89.tact` - trait implementation of [TEP 89](https://github.com/ton-blockchain/TEPs/blob/master/text/0089-jetton-wallet-discovery.md) -- - `consts.tact` - project constants -- - `errors.tact` - custom project error codes (exit codes) -- - `messages.tact` - contracts API messages +We have document that could be helpful if you build application based on this jetton. -## Exit codes +[Link](docs/PROCESSING.md) -[Standard Tact exit codes](https://docs.tact-lang.org/book/exit-codes) +# License - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
CodeDescription
Tact lang exit codes
132 - Invalid owner of contract.
Occurs when sender wallet is not owner of receiver contract when it is required. -
Custom exit codes
6901No enough TON on contract balance.
6902No enough TON in message
6903 - Jetton already initialized.
Occurs when you send 0x133701 message to jetton that has been already initialized. -
6904 - Max supply exceeded.
Occurs when you try mint more tokens than max_supply parameter allow. -
6905 - Invalid transfer amount.
Occurs when you try to send, burn or mint 0 tokens. -
6906 - Minting already disabled.
Occurs when you attempt to enable minting after it has been permanently disabled. -
6907 - Minting is disabled.
Occurs when you try to mint tokens while the minting functionality is disabled. -
+[MIT](https://opensource.org/license/mit) diff --git a/docs/CONTRIBUTING.md b/docs/CONTRIBUTING.md new file mode 100644 index 0000000..31ecec4 --- /dev/null +++ b/docs/CONTRIBUTING.md @@ -0,0 +1,79 @@ +# How to contribute to Jetton + +â¤ī¸ It's great that you are interested in this project! + +📖 This document is guideline for contributing to this repo. If you are looking for "How to work with jetton" please follow [this](PROCESSING.md) document + +â„šī¸ The following text is mostly guideline and not rule. Use your best judgment, and feel free to propose changes to this document in a pull request. + +- [How can i contribute](#how-can-i-contrubute) + - [Reporting bugs](#reporting-bugs) + - [Enhancements proposal](#enhancements-proposal) + - [Code contribution](#code-contribution) + - [How to build smart contract](#how-to-build-smart-contract) + - [How to run tests](#how-to-run-tests) + - [Project structure](#project-structure) + +## How can i contrubute + +### Reporting bugs + +We are tracking bugs in [GitHub issues](https://github.com/supadupadao/jetton/issues). If you found an bug, open new issue with "bug" label. + +If you think you found vulnerabilty or security related issue, do not open issue, [create vulnerability report](https://github.com/supadupadao/jetton/security). + +### Enhancements proposal + +We are tracking feature suggestions in [GitHub issues](https://github.com/supadupadao/jetton/issues). if you want to propose new feature, feel free to open issue with "enhancement" label. + +### Code contribution + +To work with application locally you will need [Node.js](https://nodejs.org/) version 22+. + +Here is a list of used dependencies in project: + +- [Tact Lang](https://tact-lang.org) - programming language for TON Blockchain, we using it for writting smart contract code +- [Typescript](https://www.typescriptlang.org) - programming language we using for testing and scripting smart contracts +- [Jest](https://jestjs.io) - testing framework +- [Prettier](https://prettier.io) - for code formatting +- [Blueprint](https://github.com/ton-org/blueprint) - development environment for TON blockchain for writing, testing, and deploying smart contracts +- [TON Sandbox](https://github.com/ton-org/sandbox) - local TON emulator we are using for testing smart contract + +#### How to build smart contract + +```sh +npx blueprint build +``` + +#### How to run tests + +```sh +npx blueprint test +``` + +#### Project structure + +- `contracts` - source code of all the smart contracts +- - `jetton` - entrypoints of jetton contracts with dependencies (traits) specified +- - - `master.tact` - jetton master contract entrypoint +- - - `wallet.tact` - jetton wallet contract entrypoint +- - `teps` - traits with [TEPs](https://github.com/ton-blockchain/TEPs/) realization +- - - `messages` - API messages for TEP traits +- - - - `discoverable` - messages related to the tep89 "discoverable" trait +- - - - `jettonStandard` - messages related to the tep74 jettons standard +- - - `tep64.tact` - trait implementation of [TEP 64](https://github.com/ton-blockchain/TEPs/blob/master/text/0064-token-data-standard.md) +- - - `tep74.tact` - trait implementation of [TEP 74](https://github.com/ton-blockchain/TEPs/blob/master/text/0074-jettons-standard.md) +- - - `tep89.tact` - trait implementation of [TEP 89](https://github.com/ton-blockchain/TEPs/blob/master/text/0089-jetton-wallet-discovery.md) +- - `consts.tact` - project constants +- - `errors.tact` - custom project error codes (exit codes) +- - `messages.tact` - contracts API messages + +## Styleguide + +### Git Commit Message + +- Use [Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/) commit format +- Use the present tense ("feat: add feature" not "feat: added feature") +- Use the imperative mood ("fix: move file to..." not "fix: moves files...") +- Use lowercase first letter ("docs: update README.md" not "docs: Update README.md") +- Limit the first line to 72 characters or less diff --git a/docs/PROCESSING.md b/docs/PROCESSING.md new file mode 100644 index 0000000..72fb2f4 --- /dev/null +++ b/docs/PROCESSING.md @@ -0,0 +1,72 @@ +# How to process this jetton + +â„šī¸ This document describes how to build application based on this jetton. If you are looking for guideline how to contribute to this project, please read [this](CONTRIBUTING.md) document + +- [Definitions](#definitions) +- [Exit codes](#exit-codes) + +## Definitions + +According to [TON Jetton Standard](https://github.com/ton-blockchain/TEPs/blob/master/text/0074-jettons-standard.md) there are actually 2 smart contracts: + +- **Jetton Master** contract that deploys in single copy for your jetton +- **Jetton Wallet** contract that deploys for each jetton owner + +[Read more about jetton architecture on TON](https://docs.ton.org/develop/dapps/asset-processing/jettons#jetton-architecture) + +## Exit codes + +[Standard Tact exit codes](https://docs.tact-lang.org/book/exit-codes) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
CodeDescription
Tact lang exit codes
132 + Invalid owner of contract.
Occurs when sender wallet is not owner of receiver contract when it is required. +
Custom exit codes
6901No enough TON on contract balance.
6902No enough TON in message
6903 + Jetton already initialized.
Occurs when you send 0x133701 message to jetton that has been already initialized. +
6904 + Max supply exceeded.
Occurs when you try mint more tokens than max_supply parameter allow. +
6905 + Invalid transfer amount.
Occurs when you try to send, burn or mint 0 tokens. +
6906 + Minting already disabled.
Occurs when you attempt to enable minting after it has been permanently disabled. +
6907 + Minting is disabled.
Occurs when you try to mint tokens while the minting functionality is disabled. +
diff --git a/docs/SECURITY.md b/docs/SECURITY.md new file mode 100644 index 0000000..88bbb8f --- /dev/null +++ b/docs/SECURITY.md @@ -0,0 +1,3 @@ +# Reporting Security Issues + +We take seriously to security bugs. To report a security issue, please use the GitHub Security Advisory "[Report a Vulnerability](https://github.com/supadupadao/jetton/security/advisories/new)" tab. diff --git a/docs/SUMMARY.md b/docs/SUMMARY.md new file mode 100644 index 0000000..abb7a2d --- /dev/null +++ b/docs/SUMMARY.md @@ -0,0 +1,8 @@ +# Summary + +- [How to use it?](PROCESSING.md) +- [How to contribute?](CONTRIBUTING.md) +- [GitHub Repo](https://github.com/supadupadao/jetton) +- [Minter](https://minter.supadupa.space/deploy/jetton) +- [Code of Conduct](CODE_OF_CONDUCT.md) +- [Security Policy](SECURITY.md) From 501c1dd88330a9fe8fe30e01e4e783bd2e2ec1b1 Mon Sep 17 00:00:00 2001 From: Suprun Date: Mon, 13 Jan 2025 22:56:42 +0300 Subject: [PATCH 6/8] chore: revert job splitting --- .github/workflows/ci.yml | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4974932..06dbea0 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -21,19 +21,5 @@ jobs: run: npm install - name: Build contracts run: npm run build - - test: - needs: build - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v4 - - uses: actions/setup-node@v4 - with: - node-version: 22 - cache: 'npm' - cache-dependency-path: 'package-lock.json' - - name: NPM Install - run: npm install - name: Run tests run: npm test From 51098786d6ca4d71a04faa6383ffff60a5133c9b Mon Sep 17 00:00:00 2001 From: Suprun Date: Mon, 13 Jan 2025 23:05:28 +0300 Subject: [PATCH 7/8] chore: add exit code description --- docs/PROCESSING.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/PROCESSING.md b/docs/PROCESSING.md index 72fb2f4..8c1259b 100644 --- a/docs/PROCESSING.md +++ b/docs/PROCESSING.md @@ -16,6 +16,8 @@ According to [TON Jetton Standard](https://github.com/ton-blockchain/TEPs/blob/m ## Exit codes +This project using custom exit codes for specific error. You can match received exit code with following list and get human-friednly error text. + [Standard Tact exit codes](https://docs.tact-lang.org/book/exit-codes) From 040f52767fc7223fce26980970596262ae9ecc92 Mon Sep 17 00:00:00 2001 From: Suprun Date: Tue, 14 Jan 2025 22:23:41 +0300 Subject: [PATCH 8/8] docs: update README --- .github/ISSUE_TEMPLATE/docs_report.yml | 31 ++++++++++++++ README.md | 58 +++++++++++++++++++++----- docs/CONTRIBUTING.md | 4 +- docs/{PROCESSING.md => DEVELOPMENT.md} | 0 docs/SUMMARY.md | 4 +- 5 files changed, 83 insertions(+), 14 deletions(-) create mode 100644 .github/ISSUE_TEMPLATE/docs_report.yml rename docs/{PROCESSING.md => DEVELOPMENT.md} (100%) diff --git a/.github/ISSUE_TEMPLATE/docs_report.yml b/.github/ISSUE_TEMPLATE/docs_report.yml new file mode 100644 index 0000000..2c08c52 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/docs_report.yml @@ -0,0 +1,31 @@ +name: Documentation report +description: Something wrong with documentation. +title: 'Docs: ' +labels: ['documentation'] +body: + - type: markdown + attributes: + value: | + Thanks for taking the time to fill out this report! + - type: input + id: url + attributes: + label: Document url + description: Please fill this input with url to page with error + placeholder: README.md + validations: + required: false + - type: textarea + id: wrong + attributes: + label: What is wrong + description: What confused you? + validations: + required: true + - type: textarea + id: fix + attributes: + label: Possible solution + description: If it's possible please specify how do you see good way to fix it + validations: + required: false diff --git a/README.md b/README.md index 97ea1e9..f6123bc 100644 --- a/README.md +++ b/README.md @@ -1,32 +1,70 @@ # TON Jetton contract on Tact -â„šī¸ Jetton implementation for The Open Network written in Tact language. Metadata is fully decentralized, it means that full token metadata is stored on-chain. +[![Build status](https://img.shields.io/github/actions/workflow/status/supadupadao/jetton/ci.yml?label=CI)](https://github.com/supadupadao/jetton/actions/workflows/ci.yml) +[![GitHub License](https://img.shields.io/github/license/supadupadao/jetton)](https://github.com/supadupadao/jetton/blob/master/LICENSE) +[![TON](https://img.shields.io/badge/blockchain-TON-0098EA)](https://ton.org) +[![Tact](https://img.shields.io/badge/lang-Tact-000000)](https://github.com/tact-lang/tact) +[![Work in progress](https://img.shields.io/badge/WORK%20IN%20PROGRESS-DO%20NOT%20USE%20IN%20PRODUCTION-ff0000)](https://github.com/supadupadao/jetton/issues) + +â„šī¸ Implementation of Jetton standard for The Open Network written in Tact language âš ī¸ Warning! This contract is not 100% tested and I would not recommend using it in production yet. â¤ī¸ I'll be very grateful for any kind of contribution: code, docs, issues, bug reports, github stars or whatever +# Features overview + +This project implements TON Jetton standard with following TEPs: + +- [TEP-64](https://github.com/ton-blockchain/TEPs/blob/master/text/0064-token-data-standard.md) - Token Data Standard +- [TEP-74](https://github.com/ton-blockchain/TEPs/blob/master/text/0074-jettons-standard.md) - Fungible tokens (Jettons) standard +- [TEP-89](https://github.com/ton-blockchain/TEPs/blob/master/text/0089-jetton-wallet-discovery.md) - Discoverable Jettons Wallets + +TEPs logic isolated in corresponding Tact Traits in `contracts/teps` directory. + +## On-Chain metadata + +Smart contract code allows to store fully decentralized it means that full token metadata is stored on-chain. Also contract ABI has handlers for flexible managing metadata parameters + +# Docs + +[Read our docs in Gitbook](https://docs.supadupa.space/jetton) + # Development -This is default Tact blueprint project with default commands: +## Prerequisites + +To work with project locally you will need [Node.js](https://nodejs.org/en) version 22+. Clone this repo and run the following command to install dependencies + +``` +npm i +``` + +## How to build contract + +The following command will compile contract source code. TVM byte code files will be stored in `build/` directory. + +``` +npm run build +``` + +## All allowed commands - `npm run build` - build project and compile contracts - `npm test` - run contracts tests - `npx blueprint run` - execute script from `/scripts` directory -# Docs - -[Read our docs in Gitbook](https://docs.supadupa.space/jetton) +# How can i contribute? -## How can i contribute? +We are very appreciate if you want to contribute. Please read out [contributing guideline](docs/CONTRIBUTING.md) document. -We are very appreciate your attention to project. Please read our [contributing guide](docs/CONTRIBUTING.md). +If something was unclear in this document please [open issue](https://github.com/supadupadao/jetton/issues) and we will help you. -## How can i process it? +# How can i process it? -We have document that could be helpful if you build application based on this jetton. +If you want to build application that uses this jetton, read our [development guideline](docs/DEVELOPMENT.md). It describes interaction ways with this jetton. -[Link](docs/PROCESSING.md) +If something was unclear in this document please [open issue](https://github.com/supadupadao/jetton/issues) and we will help you. # License diff --git a/docs/CONTRIBUTING.md b/docs/CONTRIBUTING.md index 31ecec4..bc0db56 100644 --- a/docs/CONTRIBUTING.md +++ b/docs/CONTRIBUTING.md @@ -1,8 +1,8 @@ # How to contribute to Jetton -â¤ī¸ It's great that you are interested in this project! +â¤ī¸ It's great that you are interested! Thank you for investing your time in this project! -📖 This document is guideline for contributing to this repo. If you are looking for "How to work with jetton" please follow [this](PROCESSING.md) document +📖 This document is guideline for contributing to this repo. If you are looking for "How to work with jetton" please follow [this](DEVELOPMENT.md) document â„šī¸ The following text is mostly guideline and not rule. Use your best judgment, and feel free to propose changes to this document in a pull request. diff --git a/docs/PROCESSING.md b/docs/DEVELOPMENT.md similarity index 100% rename from docs/PROCESSING.md rename to docs/DEVELOPMENT.md diff --git a/docs/SUMMARY.md b/docs/SUMMARY.md index abb7a2d..21acf39 100644 --- a/docs/SUMMARY.md +++ b/docs/SUMMARY.md @@ -1,7 +1,7 @@ # Summary -- [How to use it?](PROCESSING.md) -- [How to contribute?](CONTRIBUTING.md) +- [Development guide](DEVELOPMENT.md) +- [Contributing guide](CONTRIBUTING.md) - [GitHub Repo](https://github.com/supadupadao/jetton) - [Minter](https://minter.supadupa.space/deploy/jetton) - [Code of Conduct](CODE_OF_CONDUCT.md)