Skip to content

Commit

Permalink
feat: initial setup
Browse files Browse the repository at this point in the history
  • Loading branch information
aorumbayev committed Mar 29, 2023
1 parent d3f873d commit 3cb3f4d
Show file tree
Hide file tree
Showing 27 changed files with 7,055 additions and 408 deletions.
3 changes: 3 additions & 0 deletions .commitlintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"extends": ["@commitlint/config-conventional"]
}
19 changes: 19 additions & 0 deletions .github/auto_assign.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# REF: https://probot.github.io/apps/auto-assign/

# Set to true to add reviewers to pull requests
addReviewers: true

# Set to true to add assignees to pull requests
addAssignees: 'author'

# A list of reviewers to be added to pull requests (GitHub user name)
reviewers:
- aorumbayev

# A list of keywords to be skipped the process that add reviewers if pull requests include it
#skipKeywords:
# - wip

# A number of reviewers added to the pull request
# Set 0 to add all the reviewers (default: 0)
numberOfReviewers: 0
12 changes: 12 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
### Description

> _Please explain the changes you made here_
### Checklist

> _Please, make sure to comply with the checklist below before expecting review_
- [ ] Code compiles correctly
- [ ] Created tests which fail without the change (if possible)
- [ ] All tests passing
- [ ] Extended the README / documentation, if necessary
135 changes: 135 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,135 @@
name: Check codebase

on:
push:
branches:
- main
pull_request:
branches:
- main
workflow_dispatch:

jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v2

- name: Setup node
uses: actions/setup-node@v1
with:
node-version: 18

- name: Install dependencies
run: yarn install --frozen-lockfile

- name: Run build
run: yarn build

lint:
name: Linting
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v2

- name: Setup node
uses: actions/setup-node@v1
with:
node-version: 18

- name: Install dependencies
run: yarn install --frozen-lockfile

- name: Lint
run: yarn lint:scripts

unit-tests:
name: Unit tests
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest]
node: [18, 19]
steps:
- name: Check out repository
uses: actions/checkout@v2

- name: Setup node
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node }}

- uses: docker-practice/actions-setup-docker@master
if: runner.os == 'macOS'
timeout-minutes: 12

- name: Install dependencies
run: yarn install --frozen-lockfile

- name: Run sandbox
run: yarn localnet:start

- name: Run tests
run: yarn test:integration

- name: "Upload coverage to Codecov"
uses: codecov/codecov-action@v3
if: runner.os == 'Linux' && matrix.node == '18'
with:
fail_ci_if_error: true
token: ${{ secrets.CODECOV_TOKEN }}

deploy-docs:
permissions: write-all
name: Deploy docs
# needs: [build, lint, unit-tests]
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v2

- name: Setup node
uses: actions/setup-node@v1
with:
node-version: 18

- name: Install dependencies
run: yarn install --frozen-lockfile

- name: Build docs
run: yarn docs

- name: Deploy 🚀
uses: JamesIves/github-pages-deploy-action@v4
with:
branch: gh-pages
commit-message: Refreshing documentation 🚀
folder: docs # The folder the action should deploy.

release:
permissions: write-all
name: Release
# needs: [build, lint, unit-tests, deploy-docs]
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v2

- name: Setup node
uses: actions/setup-node@v1
with:
node-version: 18

- name: Install dependencies
run: yarn install --frozen-lockfile

- name: Run build
run: yarn build

- name: Release
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
run: yarn release
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,7 @@ lerna-debug.log*
*.njsproj
*.sln
*.sw?

# misc
coverage
docs
37 changes: 37 additions & 0 deletions LICENCE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# Subtopia SDK License Agreement

Copyright (c) 2023 Altynbek Orumbayev. All rights reserved.

This Subtopia SDK License Agreement (the "License") applies to the Subtopia SDK software (the "Software") provided by Altynbek Orumbayev ("Licensor"). By using the Software, you ("Licensee") agree to be bound by the terms of this License.

## 1. Grant of License

Subject to the terms of this License, Licensor grants Licensee a non-exclusive, non-transferable, worldwide, royalty-free license to use, reproduce, and distribute the Software, solely for the purpose of interacting with the official Subtopia decentralized platform and its related contracts.

## 2. Restrictions

a. Licensee shall not use the Software for any purpose other than interacting with the official Subtopia decentralized platform and its related contracts.

b. Licensee shall not use the Software for any commercial purposes outside of the context of interacting with the official Subtopia decentralized platform and its related contracts.

c. Licensee shall not copy, modify, distribute, sublicense, sell, or create derivative works of the Software, except as expressly permitted by this License.

## 3. Termination

This License shall terminate immediately upon Licensee's breach of any of its terms. Upon termination, Licensee shall cease all use of the Software and destroy all copies thereof.

## 4. No Warranty

The Software is provided "as is" without warranty of any kind, either express or implied, including, but not limited to, the implied warranties of merchantability, fitness for a particular purpose, or non-infringement.

## 5. Limitation of Liability

In no event shall Licensor be liable for any damages, including, but not limited to, any direct, indirect, special, incidental, or consequential damages, arising out of or in connection with the use or inability to use the Software, even if Licensor has been advised of the possibility of such damages.

## 6. Governing Law

This License shall be governed by and construed in accordance with the laws of jurisdiction in which Licensee is located, without regard to conflicts of law principles. Any legal action or proceeding relating to this License shall be instituted in a court of competent jurisdiction in which Licensee is located.

## 7. Entire Agreement

This License constitutes the entire agreement between Licensor and Licensee with respect to the subject matter hereof and supersedes all prior or contemporaneous agreements, understandings, and communications, whether written or oral, relating thereto.
Loading

0 comments on commit 3cb3f4d

Please sign in to comment.