Skip to content

Commit

Permalink
pkg
Browse files Browse the repository at this point in the history
  • Loading branch information
Nurutomo committed May 6, 2022
1 parent c8fcb39 commit cfcfb9e
Show file tree
Hide file tree
Showing 4 changed files with 55 additions and 3 deletions.
16 changes: 16 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: Build
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: 16
- run: npm install
- run: npm run build
24 changes: 24 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Publish
on:
release:
types: [created]
jobs:
publish:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: 16
- run: npm install
- run: npm run build
- run: |
echo @lexacode:https://npm.pkg.github.com/ > build/.npmrc
echo '//npm.pkg.github.com/:_authToken=${NPM_TOKEN}' >> build/.npmrc
- run: npm publish
working-directory: ./build
env:
NPM_TOKEN: ${{ secrets.GITHUB_TOKEN }}
1 change: 1 addition & 0 deletions .npmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
package-lock=false
17 changes: 14 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,17 +1,22 @@
{
"name": "mahbod",
"name": "@nurutomo/mahbod",
"version": "1.0.0",
"description": "Typescript WhatsApp Bot",
"homepage": "https://github.com/Nurutomo/mahbod",
"main": "./lib/index.js",
"types": "./lib/index.d.ts",
"scripts": {
"start": "node ./lib/index.js",
"test": "echo \"Error: no test specified\" && exit 1",
"prepare": "tsc",
"build": "tsc"
},
"keywords": [],
"keywords": ["whatsapp", "bot"],
"author": "Nurutomo",
"license": "ISC",
"repository": {
"url": "git@github.com:nurutomo/mahbod.git"
},
"dependencies": {
"@adiwajshing/baileys": "github:adiwajshing/Baileys",
"@adiwajshing/keyed-db": "^0.2.4",
Expand All @@ -25,5 +30,11 @@
"@types/ws": "^8.5.3",
"ts-node": "^10.7.0",
"typescript": "^4.6.4"
}
},
"files": [
"database/*",
"lib/*",
"lang/*",
"sessions/*"
]
}

0 comments on commit cfcfb9e

Please sign in to comment.