Skip to content

Commit

Permalink
chore: format workflow file
Browse files Browse the repository at this point in the history
  • Loading branch information
limcheekin committed Sep 14, 2021
1 parent dc46f91 commit 8020b04
Showing 1 changed file with 14 additions and 5 deletions.
19 changes: 14 additions & 5 deletions .github/workflows/truffle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,45 +15,54 @@ jobs:

steps:
- uses: actions/checkout@v2

- name: Setup NodeJS 14
uses: actions/setup-node@v2
with:
node-version: '14'
- name: Show NodeJS version
run: npm --version

- name: Create .env file
run: echo "${{ secrets.DOT_ENV }}" > .env

- name: Install Truffle
run: npm install truffle -g

- name: Install Truffle Dependencies
run: npm install

- name: Run Truffle Test with CI=true for Codechecks
run: CI=true truffle test
- name: Show gasReporterOutput.json
run: cat gasReporterOutput.json

- name: Run Codechecks
run: npx codechecks
env:
CC_SECRET: ${{ secrets.CC_SECRET }}

- name: Run Test Coverage
run: truffle run coverage

- name: Generate .coveralls.yml file
run: echo "${{ secrets.DOT_COVERALLS_YML }}" > .coveralls.yml
run: echo "${{ secrets.DOT_COVERALLS_YML }}" > .coveralls.yml
- name: Send Coverage Info to CoverAlls
run: cat coverage/lcov.info | npx coveralls

- name: Setup Python 3.8
uses: actions/setup-python@v2
with:
python-version: 3.8 # Version range or exact version of a Python version to use, using SemVer's version range syntax
architecture: 'x64' # optional x64 or x86. Defaults to x64 if not specified
- name: Show Python version
run: python --version
- name: Clone SmartBugs Repo

- name: Clone SmartBugs Repo
run: git clone https://github.com/smartbugs/smartbugs.git
- name: Remove SmartBugs Results and Install SmartBugs Dependencies
run: cd smartbugs;rm -r results;pip install -r requirements.txt
- name: Run SmartBugs Analysis
run: DIR=$(pwd);cd smartbugs;python smartBugs.py --tool all --file $DIR/contracts/Greeter.sol

- name: Move SmartBugs Results to Parent Directory
run: rm -r results && cd smartbugs;mv results ../
- name: Commit SmartBugs Results
Expand All @@ -62,4 +71,4 @@ jobs:
author_name: github-actions
author_email: action@github.com
message: 'chore: added smartbugs results'
add: 'results'
add: 'results'

0 comments on commit 8020b04

Please sign in to comment.