rafashacodeid 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.npmrc.example +2 -0
- package/PUBLISH.md +43 -0
- package/README.md +11 -0
- package/index.js +17 -0
- package/package.json +12 -0
package/.npmrc.example
ADDED
package/PUBLISH.md
ADDED
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
# Publish ke NPM
|
|
2
|
+
|
|
3
|
+
Folder package: `packages/rafashacodeid`
|
|
4
|
+
|
|
5
|
+
## Opsi A (paling gampang): login interaktif
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
cd packages/rafashacodeid
|
|
9
|
+
npm adduser
|
|
10
|
+
npm publish --access public
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## Opsi B: pakai token (non-interaktif)
|
|
14
|
+
|
|
15
|
+
1) Buat token di NPM: **Access Tokens** (Automation/Publish)
|
|
16
|
+
2) Export token:
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
export NPM_TOKEN="xxxxx"
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
3) Set auth (sekali saja untuk mesin ini), lalu publish:
|
|
23
|
+
|
|
24
|
+
```bash
|
|
25
|
+
cd packages/rafashacodeid
|
|
26
|
+
npm config set //registry.npmjs.org/:_authToken "$NPM_TOKEN"
|
|
27
|
+
npm publish --access public
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
## Setelah publish: switch bot ke alias `npm:rafashacodeid`
|
|
31
|
+
|
|
32
|
+
Di root bot `package.json`, ubah:
|
|
33
|
+
|
|
34
|
+
```json
|
|
35
|
+
"@whiskeysockets/baileys": "npm:rafashacodeid@1.0.0"
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
Lalu jalankan:
|
|
39
|
+
|
|
40
|
+
```bash
|
|
41
|
+
npm install
|
|
42
|
+
```
|
|
43
|
+
|
package/README.md
ADDED
package/index.js
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
const chalk = require('chalk');
|
|
2
|
+
|
|
3
|
+
if (!global.__RAFASHACODEID_BANNER_PRINTED__ && process.env.RAFASHACODEID_BANNER !== '0') {
|
|
4
|
+
global.__RAFASHACODEID_BANNER_PRINTED__ = true;
|
|
5
|
+
console.log(
|
|
6
|
+
chalk.blueBright(
|
|
7
|
+
`╔═╗╔══╗╔═╗╔═╗\n` +
|
|
8
|
+
`║╬║╚║║╝║║║║║║\n` +
|
|
9
|
+
`╚╗║╔║║╗║║║║║║\n` +
|
|
10
|
+
`─╚╝╚══╝╚═╝╚═╝\n` +
|
|
11
|
+
`t.me/rafashacodeid\n`
|
|
12
|
+
)
|
|
13
|
+
);
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
module.exports = require('baileys-upstream');
|
|
17
|
+
|
package/package.json
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "rafashacodeid",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "RafaShaCodeID wrapper for Baileys (prints banner + re-exports upstream)",
|
|
5
|
+
"main": "index.js",
|
|
6
|
+
"license": "MIT",
|
|
7
|
+
"dependencies": {
|
|
8
|
+
"baileys-upstream": "npm:@whiskeysockets/baileys@^6.7.21",
|
|
9
|
+
"chalk": "^4.1.2"
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
|