Skip to content

Commit

Permalink
Merge pull request #17 from sablier-labs/build/bun
Browse files Browse the repository at this point in the history
build: use bun for dep management
  • Loading branch information
PaulRBerg authored Jan 11, 2024
2 parents 09ba1fa + 0327d8b commit 6ef543b
Show file tree
Hide file tree
Showing 7 changed files with 8,744 additions and 3,910 deletions.
29 changes: 13 additions & 16 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,41 +13,38 @@ jobs:
needs: "test"
runs-on: "ubuntu-latest"
steps:
- name: "Setup: checkout the repo"
- name: "Check out the repo"
uses: "actions/checkout@v4"

- name: "Dependencies: setup node"
uses: "actions/setup-node@v3"
with:
cache: "yarn"
node-version: "lts/*"
- name: "Install Bun"
uses: "oven-sh/setup-bun@v1"

- name: "Dependencies: install"
run: "yarn install --immutable"
- name: "Install Node.js dependecies"
run: "bun install --frozen-lockfile"

- name: "List: build project"
run: "yarn build"
- name: "Build project"
run: "bun run build"

- name: "IPFS: upload bundle and pin"
id: upload
uses: aquiladev/ipfs-action@master
id: "upload"
uses: "aquiladev/ipfs-action@master"
with:
path: "build/sablier-community.tokenlist.json"
service: "infura"
pinName: "tokenlist"
infuraProjectId: ${{ secrets.INFURA_PROJECT_ID }}
infuraProjectSecret: ${{ secrets.INFURA_PROJECT_SECRET }}

- name: "IPFS: hash summary"
- name: "IPFS hash summary"
run: |
echo "Successfully deployed on IPFS: [${{ steps.upload.outputs.hash }}](https://cloudflare-ipfs.com/ipfs/${{
steps.upload.outputs.hash }})"
- name: "Cloudflare: update DNS with latest IPFS hash"
- name: "Update Cloudflare DNS with latest IPFS hash"
env:
CLOUDFLARE_GATEWAY_ID: ${{ secrets.CLOUDFLARE_GATEWAY_ID }}
CLOUDFLARE_TOKEN: ${{ secrets.CLOUDFLARE_TOKEN }}
CLOUDFLARE_ZONE_ID: ${{ secrets.CLOUDFLARE_ZONE_ID }}
CLOUDFLARE_GATEWAY_ID: ${{ secrets.CLOUDFLARE_GATEWAY_ID }}
uses: sablier-labs/action-cloudflare-web3-gateway@main
uses: "sablier-labs/action-cloudflare-web3-gateway@main"
with:
cid: ${{ steps.upload.outputs.hash }}
16 changes: 7 additions & 9 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,14 @@ jobs:
test:
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v4"
- name: "Check out the repo"
uses: "actions/checkout@v4"

- name: "Install Node.js"
uses: "actions/setup-node@v3"
with:
cache: "yarn"
node-version: "lts/*"
- name: "Install Bun"
uses: "oven-sh/setup-bun@v1"

- name: "Install Node.js dependecies"
run: "yarn install --frozen-lockfile"
run: "bun install --frozen-lockfile"

- name: "Test: run test suite"
run: "yarn test"
- name: "Run test suite"
run: "bun run test"
162 changes: 10 additions & 152 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,156 +1,14 @@
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
lerna-debug.log*

# Diagnostic reports (https://nodejs.org/api/report.html)
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json

# Runtime data
pids
*.pid
*.seed
*.pid.lock

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage
*.lcov

# Nyc test coverage
.nyc_output

# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# Bower dependency directory (https://bower.io/)
bower_components

# node-waf configuration
.lock-wscript

# Compiled binary addons (https://nodejs.org/api/addons.html)
build/Release

# Dependency directories
node_modules/
jspm_packages/

# TypeScript v1 declaration files
typings/

# TypeScript cache
*.tsbuildinfo

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Microbundle cache
.rpt2_cache/
.rts2_cache_cjs/
.rts2_cache_es/
.rts2_cache_umd/

# Optional REPL history
.node_repl_history

# Output of "npm pack"
*.tgz

# Yarn Integrity file
.yarn-integrity

# Dotenv environment variables file
.env
.env.test

# Parcel-bundler cache (https://parceljs.org/)
.cache

# Next.js build output
.next
.vercel
**/next-env.d.ts

# Nuxt.js build / generate output
.nuxt
# directories
build
dist
node_modules

# Gatsby files
.cache/
# Comment in the public line in if your project uses Gatsby and *not* Next.js
# https://nextjs.org/blog/next-9-1#public-directory-support
# public

# Vuepress build output
.vuepress/dist

# Serverless directories
.serverless/

# FuseBox cache
.fusebox/

# DynamoDB Local files
.dynamodb/

# TernJS port file
.tern-port

# Dependencies
/node_modules
/.pnp
.pnp.js

# Testing
/coverage

# Production
/packages/*/build
/apps/*/build
/scripts/*/build

/packages/*/dist
/apps/*/dist
/scripts/*/dist

# Misc
# files
*.env
*.log
.DS_Store
.env.local
.env.development.local
.env.test.local
.env.production.local
.idea

npm-debug.log*
yarn-debug.log*
yarn-error.log*

#Prettier
!.prettierrc
!.prettierrc.*


#Yarn Berry: https://yarnpkg.com/getting-started/qa#which-files-should-be-gitignored
.pnp.*
.yarn/*
!.yarn/patches
!.yarn/releases
!.yarn/plugins
!.yarn/sdks
!.yarn/versions

#XState
tsconfig.tsbuildinfo


#Editor Configuration
.vscode/
package-lock.json
pnpm-lock.yaml
yarn.lock
`
12 changes: 9 additions & 3 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,13 @@
# directories
.yarn
**/build
**/node_modules
build
node_modules

# files
*.env
*.log
.DS_Store
.pnp.*
bun.lockb
package-lock.json
pnpm-lock.yaml
yarn.lock
Loading

0 comments on commit 6ef543b

Please sign in to comment.