Skip to content

Commit

Permalink
chore(effect): improving spans usage (#39)
Browse files Browse the repository at this point in the history
* chore: struff

* chore: refreshing lockfile

* chore: esm

* chore: esm

* fix: naming

* chore: useless
  • Loading branch information
jpb06 authored Nov 9, 2024
1 parent b5c22a6 commit 5cc6925
Show file tree
Hide file tree
Showing 62 changed files with 716 additions and 114,448 deletions.
3 changes: 0 additions & 3 deletions .eslintignore

This file was deleted.

112 changes: 0 additions & 112 deletions .eslintrc.js

This file was deleted.

16 changes: 7 additions & 9 deletions .github/workflows/bump-version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,35 +6,33 @@ on:
types:
- completed

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
version-bump:
name: 🆕 Version bump
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- name: 🛑 Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.12.1

- name: ⬇️ Checkout repo
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: 📦 Setup pnpm
uses: pnpm/action-setup@v3
with:
version: latest
- name: 📦 Setup bun
uses: oven-sh/setup-bun@v2

- name: ⎔ Setup node
uses: actions/setup-node@v4
with:
node-version-file: '.node-version'
registry-url: 'https://registry.npmjs.org'
cache: 'pnpm'
cache-dependency-path: ./package.json

- name: 📥 Install deps
run: pnpm install --frozen-lockfile
run: bun install --frozen-lockfile

- name: ⏫ Bump package version
id: bumping-version
Expand Down
18 changes: 8 additions & 10 deletions .github/workflows/coverage-badges-generation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,38 +5,36 @@ on:
branches:
- master

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
coverage-badges-generation:
name: 📣 Coverage badges generation
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- name: 🛑 Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.12.1

- name: ⬇️ Checkout repo
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: 📦 Setup pnpm
uses: pnpm/action-setup@v3
with:
version: latest
- name: 📦 Setup bun
uses: oven-sh/setup-bun@v2

- name: ⎔ Setup node
uses: actions/setup-node@v4
with:
node-version-file: '.node-version'
registry-url: 'https://registry.npmjs.org'
cache: 'pnpm'
cache-dependency-path: ./package.json

- name: 📥 Install deps
run: pnpm install --frozen-lockfile
run: bun install --frozen-lockfile

- name: 🔍 Tests
run: pnpm test-ci
run: bun test-ci

- name: ⚙️ Generating coverage badges
uses: jpb06/coverage-badges-action@latest
45 changes: 12 additions & 33 deletions .github/workflows/tests-scan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,85 +19,67 @@ jobs:
name: ⬣ ESLint
runs-on: ubuntu-latest
steps:
- name: 🛑 Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.12.1

- name: ⬇️ Checkout repo
uses: actions/checkout@v4

- name: 📦 Setup pnpm
uses: pnpm/action-setup@v3
with:
version: latest
- name: 📦 Setup bun
uses: oven-sh/setup-bun@v2

- name: ⎔ Setup node
uses: actions/setup-node@v4
with:
node-version-file: '.node-version'
cache: 'pnpm'
cache-dependency-path: ./package.json

- name: 📥 Install deps
run: pnpm install --frozen-lockfile
run: bun install --frozen-lockfile

- name: 🔬 Lint
run: pnpm lint
run: bun lint

typecheck:
name: ʦ TypeScript
runs-on: ubuntu-latest
steps:
- name: 🛑 Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.12.1

- name: ⬇️ Checkout repo
uses: actions/checkout@v4

- name: 📦 Setup pnpm
uses: pnpm/action-setup@v3
with:
version: latest
- name: 📦 Setup bun
uses: oven-sh/setup-bun@v2

- name: ⎔ Setup node
uses: actions/setup-node@v4
with:
node-version-file: '.node-version'
cache: 'pnpm'
cache-dependency-path: ./package.json

- name: 📥 Install deps
run: pnpm install --frozen-lockfile
run: bun install --frozen-lockfile

- name: 🔎 Type check
run: pnpm type-check
run: bun type-check

test:
name: 🎯 Tests
runs-on: ubuntu-latest
steps:
- name: 🛑 Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.12.1

- name: ⬇️ Checkout repo
uses: actions/checkout@v4

- name: 📦 Setup pnpm
uses: pnpm/action-setup@v3
with:
version: latest
- name: 📦 Setup bun
uses: oven-sh/setup-bun@v2

- name: ⎔ Setup node
uses: actions/setup-node@v4
with:
node-version-file: '.node-version'
cache: 'pnpm'
cache-dependency-path: ./package.json

- name: 📥 Install deps
run: pnpm install --frozen-lockfile
run: bun install --frozen-lockfile

- name: 🧪 Tests
run: pnpm test-ci
run: bun test-ci

- name: 💾 Uploading coverage artifact
uses: actions/upload-artifact@v4
Expand All @@ -110,9 +92,6 @@ jobs:
runs-on: ubuntu-latest
needs: [lint, typecheck, test]
steps:
- name: 🛑 Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.12.1

- name: ⬇️ Checkout repo
uses: actions/checkout@v4

Expand Down
7 changes: 4 additions & 3 deletions .github/workflows/updating-latest-branch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,15 @@ on:
release:
types: [published]

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
update-latest-branch:
name: 🛜 Update latest branch
runs-on: ubuntu-latest
steps:
- name: 🛑 Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.12.1

- name: 🔄 Checkout repo
uses: actions/checkout@v4
with:
Expand Down
3 changes: 0 additions & 3 deletions .prettierignore

This file was deleted.

4 changes: 0 additions & 4 deletions .prettierrc

This file was deleted.

5 changes: 0 additions & 5 deletions .vscode/effect.code-snippets
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,4 @@
"body": ["import { pipe, Effect } from 'effect'"],
"description": "Import effect and pipe",
},
"Scope effect with span": {
"prefix": "wsp",
"body": ["Effect.withSpan(__filename)("],
"description": "Create a span",
},
}
32 changes: 26 additions & 6 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,28 @@
{
"eslint.run": "onSave",
"editor.formatOnSave": true,
"editor.codeActionsOnSave": {
"source.fixAll": "explicit"
},
"editor.tabSize": 2
"biome.enabled": true,
"editor.formatOnSave": true,
"editor.codeActionsOnSave": {
"source.organizeImports.biome": "explicit"
},
"editor.tabSize": 2,
"editor.defaultFormatter": "biomejs.biome",
"[shellscript]": {
"editor.defaultFormatter": "foxundermoon.shell-format"
},
"[dotenv]": {
"editor.defaultFormatter": "foxundermoon.shell-format"
},
"[ignore]": {
"editor.defaultFormatter": "foxundermoon.shell-format"
},
"[properties]": {
"editor.defaultFormatter": "foxundermoon.shell-format"
},
"[markdown]": {
"editor.defaultFormatter": "esbenp.prettier-vscode",
"prettier.singleQuote": true,
"prettier.semi": true
},
"typescript.preferences.importModuleSpecifier": "relative",
"typescript.preferences.preferTypeOnlyAutoImports": true
}
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ A github action bumping the version of a package and pushing the version bump to

<!-- readme-package-icons start -->

<p align="left"><a href="https://docs.github.com/en/actions" target="_blank"><img height="50" src="https://raw.githubusercontent.com/jpb06/jpb06/master/icons/GithubActions-Dark.svg" /></a>&nbsp;<a href="https://www.typescriptlang.org/docs/" target="_blank"><img height="50" src="https://raw.githubusercontent.com/jpb06/jpb06/master/icons/TypeScript.svg" /></a>&nbsp;<a href="https://nodejs.org/en/docs/" target="_blank"><img height="50" src="https://raw.githubusercontent.com/jpb06/jpb06/master/icons/NodeJS-Dark.svg" /></a>&nbsp;<a href="https://pnpm.io/motivation" target="_blank"><img height="50" src="https://raw.githubusercontent.com/jpb06/jpb06/master/icons/Pnpm-Dark.svg" /></a>&nbsp;<a href="https://github.com/conventional-changelog" target="_blank"><img height="50" src="https://raw.githubusercontent.com/jpb06/jpb06/master/icons/CommitLint.Dark.svg" /></a>&nbsp;<a href="https://eslint.org/docs/latest/" target="_blank"><img height="50" src="https://raw.githubusercontent.com/jpb06/jpb06/master/icons/Eslint-Dark.svg" /></a>&nbsp;<a href="https://prettier.io/docs/en/index.html" target="_blank"><img height="50" src="https://raw.githubusercontent.com/jpb06/jpb06/master/icons/Prettier-Dark.svg" /></a>&nbsp;<a href="https://vitest.dev/guide/" target="_blank"><img height="50" src="https://raw.githubusercontent.com/jpb06/jpb06/master/icons/Vitest-Dark.svg" /></a>&nbsp;<a href="https://www.effect.website/docs/quickstart" target="_blank"><img height="50" src="https://raw.githubusercontent.com/jpb06/jpb06/master/icons/Effect-Dark.svg" /></a></p>
<p align="left"><a href="https://docs.github.com/en/actions" target="_blank"><img height="50" src="https://raw.githubusercontent.com/jpb06/jpb06/master/icons/GithubActions-Dark.svg" /></a>&nbsp;<a href="https://www.typescriptlang.org/docs/" target="_blank"><img height="50" src="https://raw.githubusercontent.com/jpb06/jpb06/master/icons/TypeScript.svg" /></a>&nbsp;<a href="https://nodejs.org/en/docs/" target="_blank"><img height="50" src="https://raw.githubusercontent.com/jpb06/jpb06/master/icons/NodeJS-Dark.svg" /></a>&nbsp;<a href="https://bun.sh/docs" target="_blank"><img height="50" src="https://raw.githubusercontent.com/jpb06/jpb06/master/icons/Bun-Dark.svg" /></a>&nbsp;<a href="https://biomejs.dev/guides/getting-started/" target="_blank"><img height="50" src="https://raw.githubusercontent.com/jpb06/jpb06/master/icons/Biome-Dark.svg" /></a>&nbsp;<a href="https://github.com/conventional-changelog" target="_blank"><img height="50" src="https://raw.githubusercontent.com/jpb06/jpb06/master/icons/CommitLint.Dark.svg" /></a>&nbsp;<a href="https://esbuild.github.io/getting-started/#install-esbuild" target="_blank"><img height="50" src="https://raw.githubusercontent.com/jpb06/jpb06/master/icons/Esbuild-Dark.svg" /></a>&nbsp;<a href="https://vitest.dev/guide/" target="_blank"><img height="50" src="https://raw.githubusercontent.com/jpb06/jpb06/master/icons/Vitest-Dark.svg" /></a>&nbsp;<a href="https://www.effect.website/docs/quickstart" target="_blank"><img height="50" src="https://raw.githubusercontent.com/jpb06/jpb06/master/icons/Effect-Dark.svg" /></a></p>

<!-- readme-package-icons end -->

Expand Down
Loading

0 comments on commit 5cc6925

Please sign in to comment.