Skip to content

Commit

Permalink
circleci (#33)
Browse files Browse the repository at this point in the history
* circleci

* add nyc

* Fix build

* Fix build
  • Loading branch information
0xslipk authored Feb 24, 2022
1 parent 3bf3dd7 commit 4bec761
Show file tree
Hide file tree
Showing 8 changed files with 367 additions and 134 deletions.
62 changes: 62 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
# Use the latest 2.1 version of CircleCI pipeline process engine.
# See: https://circleci.com/docs/2.0/configuration-reference
version: 2.1

orbs:
# The Node.js orb contains a set of prepackaged CircleCI configuration you can utilize
# Orbs reduce the amount of configuration required for common tasks.
# See the orb documentation here: https://circleci.com/developer/orbs/orb/circleci/node
node: circleci/[email protected]
coveralls: coveralls/[email protected]

jobs:
test:
parameters:
node-version:
type: string
docker:
- image: circleci/node:<< parameters.node-version >>
resource_class: small
steps:
- checkout
- restore_cache:
# See the configuration reference documentation for more details on using restore_cache and save_cache steps
# https://circleci.com/docs/2.0/configuration-reference/?section=reference#save_cache
keys:
- node-deps-v1-{{ .Branch }}-{{checksum "package-lock.json"}}
- run:
name: install packages
command: npm ci
- save_cache:
key: node-deps-v1-{{ .Branch }}-{{checksum "package-lock.json"}}
paths:
- ~/.npm
- run:
name: Run Lint
command: npm run lint:ci
- run:
name: Run Tests
command: npm run test:cov
- run:
name: Run Build
command: npm run build
- run:
name: Run Build CJS
command: npm run build-cjs
- run:
name: Run Build Esnext
command: npm run build-esnext
- run:
name: Run Build Esm
command: npm run build-esm
- coveralls/upload:
path_to_lcov: coverage/lcov.info
verbose: true

workflows:
test-workflow:
jobs:
- test:
matrix:
parameters:
node-version: ['16.13', '14.18', '12.22']
45 changes: 45 additions & 0 deletions .github/ISSUE_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
<!--
PLEASE HELP US PROCESS GITHUB ISSUES FASTER BY PROVIDING THE FOLLOWING INFORMATION.
ISSUES MISSING IMPORTANT INFORMATION MAY BE CLOSED WITHOUT INVESTIGATION.
-->

## I'm submitting a...
<!--
Please search GitHub for a similar issue or PR before submitting.
Check one of the following options with "x" -->
<pre><code>
[ ] Regression <!--(a behavior that used to work and stopped working in a new release)-->
[ ] Bug report
[ ] Feature request
[ ] Documentation issue or request
[ ] Support request => Please do not submit support request here, instead post your question on Stack Overflow.
</code></pre>

## Current behavior
<!-- Describe how the issue manifests. -->

## Expected behavior
<!-- Describe what the desired behavior would be. -->

## Minimal reproduction of the problem with instructions
<!-- Please share a repo, a gist, or step-by-step instructions. -->

## What is the motivation / use case for changing the behavior?
<!-- Describe the motivation or the concrete use case. -->

## Environment

<pre><code>
Harmony RPC endpoint: https://api.harmony.one <!-- `mainnet or testnet` -->
Harmony Marketplace SDK version: X.Y.Z
<!-- Check whether this is still an issue in the most recent version -->

For Tooling issues:
- Node/JS/TS version: XX <!-- run `node --version` -->
- Platform: <!-- Mac, Linux, Windows -->
- Environment: <!-- Browser, Server -->

Others:
<!-- Anything else relevant? Operating system version, IDE, package manager, ... -->
</code></pre>
37 changes: 37 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
## PR Checklist
Please check if your PR fulfills the following requirements:

- [ ] The commit message follows our guidelines: https://github.com/blockcoders/harmony-marketplace-sdk/blob/main/CONTRIBUTING.md
- [ ] Tests for the changes have been added (for bug fixes / features)
- [ ] Docs have been added / updated (for bug fixes / features)

## PR Type
What kind of change does this PR introduce?

<!-- Please check the one that applies to this PR using "x". -->
- [ ] Bugfix
- [ ] Feature
- [ ] Code style update (formatting, local variables)
- [ ] Refactoring (no functional changes, no api changes)
- [ ] Build related changes
- [ ] CI related changes
- [ ] Other... Please describe:

## What is the current behavior?
<!-- Please describe the current behavior that you are modifying, or link to a relevant issue. -->

Issue Number: N/A

## What is the new behavior?
<!-- Please describe how the issue was solved. -->


## Does this PR introduce a breaking change?

- [ ] Yes
- [ ] No

<!-- If this PR contains a breaking change, please describe the impact and migration path for existing applications below. -->

## Other information
<!-- Anything else relevant? Operating system version, IDE, package manager, ... -->
7 changes: 6 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -128,4 +128,9 @@ dist
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json
!.vscode/extensions.json

# Builds
lib.esm/
lib.esnext/
lib/
28 changes: 28 additions & 0 deletions .nycrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{
"cache": false,
"check-coverage": false,
"extension": [
".ts"
],
"include": [
"**/*.ts"
],
"exclude": [
"coverage/**",
"node_modules/**",
"**/*.d.ts",
"**/*.test.ts",
"**/*.spec.ts",
"src/tests/**/*",
"src/index.ts"
],
"sourceMap": true,
"reporter": [
"html",
"text",
"lcov",
"text-summary"
],
"all": true,
"instrument": true
}
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Changelog

## 0.1.0
Published by **[jarcodallo](https://github.com/jarcodallo)** on **2022/03/22**
- Pending...
Loading

0 comments on commit 4bec761

Please sign in to comment.