-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: switch from got to ofetch (#103)
BREAKING CHANGE: `addTorrent` functions can no longer be passed a file path. You must handle reading the file. BREAKING CHANGE: no longer uses got - uses [ofetch](https://github.com/unjs/ofetch) which can work in environments like cloudflare workers and bun due to using fetch BREAKING CHANGE: requires node 18
- Loading branch information
Showing
12 changed files
with
2,792 additions
and
4,547 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
name: CI | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
services: | ||
transmission: | ||
image: lscr.io/linuxserver/transmission:latest | ||
env: | ||
PUID: 1000 | ||
PGID: 1000 | ||
TZ: Etc/UTC | ||
ports: | ||
- "9091:9091" | ||
- "51413:51413" | ||
- "51413:51413/udp" | ||
steps: | ||
- name: checkout | ||
uses: actions/checkout@v3 | ||
- name: setup node | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: 20 | ||
cache: 'npm' | ||
- name: install dependencies | ||
run: npm ci | ||
- name: lint | ||
run: npm run lint | ||
- name: test | ||
run: npm run test:ci | ||
- name: coverage | ||
uses: codecov/codecov-action@v3 | ||
with: | ||
token: ${{ secrets.CODECOV_TOKEN }} | ||
publish: | ||
needs: build | ||
runs-on: ubuntu-latest | ||
if: github.ref_name == 'master' | ||
permissions: | ||
contents: write # to be able to publish a GitHub release | ||
issues: write # to be able to comment on released issues | ||
pull-requests: write # to be able to comment on released pull requests | ||
id-token: write # to enable use of OIDC for npm provenance | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version: 20 | ||
cache: 'npm' | ||
- run: npm ci | ||
- name: release | ||
run: npx semantic-release | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
16 | ||
20 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.