Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
ShadowLp174 committed Feb 14, 2025
2 parents 489d3b0 + 6654977 commit 6e50aa2
Show file tree
Hide file tree
Showing 4 changed files with 95 additions and 7 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Build TypeScript definitions

on: [push]

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'
- run: npm ci
- run: npm run build
- name: commit
uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: 'chore: update type definitions [skip ci]'
commit_author: GitHub Actions <actions@github.com>
11 changes: 11 additions & 0 deletions Uploader.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
export = Uploader;
declare class Uploader {
constructor(client: any, forceReady?: boolean);
client: any;
ready: boolean;
url: any;
uploadFile(filePath: any, name?: any, tag?: string): Promise<any>;
uploadUrl(url: any, fileName: any, tag?: string): Promise<any>;
upload(file: any, fileName: any, tag?: string): Promise<any>;
#private;
}
60 changes: 56 additions & 4 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 8 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
{
"name": "revolt-uploader",
"version": "1.1.4",
"version": "1.1.5",
"description": "A utility script to allow easy uploads of files to revolt.",
"main": "Uploader.js",
"types": "Uploader.d.ts",
"scripts": {
"build": "tsc --emitDeclarationOnly --allowJs --declaration Uploader.js",
"test": "echo \"Error: no test specified\" && exit 1"
},
"keywords": [
Expand All @@ -16,12 +18,15 @@
"revolt.chat"
],
"author": "ShadowLp174",
"license": "ISC",
"license": "MIT",
"dependencies": {
"form-data": "^4.0.0",
"node-fetch": "^2.6.7"
},
"devDependencies": {},
"devDependencies": {
"@types/node": "^20.12.12",
"typescript": "^5.4.5"
},
"repository": {
"type": "git",
"url": "git+https://github.com/ShadowLp174/revolt-uploader.git"
Expand Down

0 comments on commit 6e50aa2

Please sign in to comment.