Skip to content

Commit

Permalink
👷 add github actions and templates
Browse files Browse the repository at this point in the history
  • Loading branch information
Aboudjem committed Nov 7, 2023
1 parent 587a88f commit d82293e
Show file tree
Hide file tree
Showing 5 changed files with 183 additions and 0 deletions.
31 changes: 31 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
## SDK Version

<!-- Please specify the version of the SDK you are using. -->

## Description
<!-- Briefly describe the bug you are facing. -->

## Steps to Reproduce

1.
2.
3.
<!-- Add any other context or screenshots about the feature request here. -->

## Expected Behavior
<!-- Describe what you expected to happen. -->

## Actual Behavior
<!-- Describe what actually happened. Include any error tracebacks if possible. -->

## Possible Fix (optional)
<!-- If you have an idea on how to fix this, please share! -->

## Environment Details

- **Browser Version**:
- **Node.js Version**:
- **NPM/Yarn Version**:

## Additional Context
<!-- Add any other details or context about the bug here. -->
22 changes: 22 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
---
name: Feature Request
about: Propose an enhancement or new feature to improve the project
title: "Feature: <Your Feature>"
labels: feature-request, needs-review
assignees: ""
---

**Problem You're Facing**
<!-- Briefly describe the problem you're trying to solve or the limitation you've encountered. -->

**Proposed Solution**
<!-- What would you like to see happen? -->

**Alternatives Considered**
<!-- Any other solutions or features you've considered. -->

## Use Cases
<!-- Help us understand the broader context by providing some typical use cases where this feature would be helpful. -->

**Additional Info**
<!-- Provide any additional details, context, or screenshots about the feature request. -->
33 changes: 33 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# Summary

<!-- Please provide a brief summary of the changes and the issue number this PR addresses. -->

Related Issue: # (issue number)

## Change Type

- [ ] Bug Fix
- [ ] Refactor
- [ ] New Feature
- [ ] Breaking Change
- [ ] Documentation Update
- [ ] Performance Improvement
- [ ] Other

# Checklist

- [ ] My code follows this project's style guidelines
- [ ] I've reviewed my own code
- [ ] I've added comments for any hard-to-understand areas
- [ ] I've updated the documentation if necessary
- [ ] My changes generate no new warnings
- [ ] I've added tests that prove my fix is effective or my feature works
- [ ] All unit tests pass locally with my changes
- [ ] Any dependent changes have been merged and published

# Additional Information
<!-- Any additional information or context about the PR. -->

# Branch Naming
<!-- Make sure your branch name follows the pattern: `features/`, `fixes/`, or `releases/`. -->
<!-- **Note**: The person creating the PR is responsible for merging and deleting the branch. Ensure the code has been tested, commented, linted, and documents updated if needed. -->
24 changes: 24 additions & 0 deletions .github/workflows/mark_stale.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Mark Inactive Issues and PRs

on:
schedule:
- cron: '0 0 * * *'

jobs:
stale:
runs-on: ubuntu-latest
permissions:
issues: write
pull-requests: write

steps:
- uses: actions/stale@v5
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
stale-issue-message: "This issue has been inactive for 30 days. It will be closed due to inactivity. If this issue is still relevant, please comment to keep it open. Alternatively, you can create a new issue with updated information.
"
stale-pr-message: "This PR has been inactive for 30 days. If it's waiting for a review, please reach out to the team. Otherwise, please update the PR or it will be closed due to inactivity."
stale-issue-label: "inactive-issue"
stale-pr-label: "inactive-pr"
days-before-stale: 30
73 changes: 73 additions & 0 deletions .github/workflows/push_check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
name: Test workflow
on: push
jobs:
lint:
name: Lint sources
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [18.x]

steps:
- name: Checkout
uses: "actions/checkout@main"
- name: Set Node.js
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
with:
version: nightly
- name: Install foundry dependencies
run: forge install
- name: Create a fake .secret file
run: echo "primary twist rack vendor diagram image used route theme frown either will" > .secret
- name: Install hardhat dependencies
run: yarn install --frozen-lockfile && yarn build
- name: Lint sources
run: yarn run lint

unit_test:
name: Unit tests
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [18.x]

steps:
- name: Checkout
uses: "actions/checkout@main"

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

- name: Create a fake .secret file
run: echo "primary twist rack vendor diagram image used route theme frown either will" > .secret

- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
with:
version: nightly

- name: Install foundry dependencies
run: forge install

- name: Install hardhat dependencies
run: yarn install --frozen-lockfile && yarn build

- name: Run Forge build
run: |
forge --version
forge build --sizes
id: forge-build

- name: Run Hardhat Tests
run: yarn test

- name: Run Forge tests
run: |
forge test -vvv
id: forge-test

0 comments on commit d82293e

Please sign in to comment.