Skip to content

Commit f08be38

Browse files
committed
fix docs
1 parent 4bc9d87 commit f08be38

File tree

2 files changed

+58
-18
lines changed

2 files changed

+58
-18
lines changed

README.md

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,64 @@ Hikkabot requires a JSON configuration file. The path must be provided as the fi
6161

6262
You can use [this skeleton](https://github.com/jfk9w/hikkabot/blob/master/config.json) to build the configuration upon.
6363

64+
#### Description
65+
66+
```json5
67+
{
68+
// Your telegram user ID
69+
"AdminID": 12345678,
70+
"Storage": {
71+
// SQL driver to be used
72+
"Driver": "postgres",
73+
// Datasource connection string
74+
"Datasource": "postgres://postgres:postgres@postgres/postgres"
75+
},
76+
// How often should subscription update check occur
77+
"UpdateInterval": "10s",
78+
// Aliases allow to map certain CHAT_REFs to telegram chat IDs
79+
// May be useful for managing private channels and aliasing long channel usernames
80+
"Aliases": {
81+
"my_ref": -10000000000000000
82+
},
83+
"Telegram": {
84+
// Telegram Bot API token
85+
"Token": "2352626236:AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA"
86+
},
87+
"Media": {
88+
"Aconvert": {
89+
// Maximum queue size fot aconvert.com client
90+
"QueueSize": 100,
91+
// Times a failed request will be retried
92+
"MaxRetries": 3,
93+
// Test file is used for aconvert.com client initialization
94+
// Should be a path to any media file supported by aconvert.com
95+
"TestFile": "test_media.webm",
96+
// Test format is used for aconvert.com client initialization
97+
// This is a target format for a media file specified above
98+
"TestFormat": "mp4"
99+
},
100+
// Number of maximum simultaneous media downloads
101+
"Workers": 13,
102+
// Temporary directory for media files
103+
"TempDir": "/tmp/hikkabot"
104+
},
105+
"Dvach": {
106+
// 2ch.hk client is updated with a cookie with this usercode
107+
// This may allow to access /e/, /hc/, etc.
108+
"Usercode": "fcdebafcde8642143"
109+
},
110+
"Reddit": {
111+
"ClientID": "iuYGY&b328fd",
112+
"ClientSecret": "a088HUUIHEAFjn9hesg",
113+
"Username": "username",
114+
"Password": "password",
115+
"UserAgent": "Your user agent 5.0",
116+
// Times a failed request will be retried
117+
"MaxRetries": 3
118+
}
119+
}
120+
```
121+
64122
### Installation and execution
65123

66124
Install using Go package manager:

config.json

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,44 +1,27 @@
11
{
2-
// Your telegram user ID
32
"AdminID": 12345678,
43
"Storage": {
5-
// SQL driver to be used
64
"Driver": "postgres",
7-
// Datasource connection string
85
"Datasource": "postgres://postgres:postgres@postgres/postgres"
96
},
10-
// How often should subscription update check occur
117
"UpdateInterval": "10s",
12-
// Aliases allow to map certain CHAT_REFs to telegram chat IDs
13-
// May be useful for managing private channels and aliasing long channel usernames
148
"Aliases": {
159
"my_ref": -10000000000000000
1610
},
1711
"Telegram": {
18-
// Telegram Bot API token
1912
"Token": "2352626236:AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA"
2013
},
2114
"Media": {
2215
"Aconvert": {
23-
// Maximum queue size fot aconvert.com client
2416
"QueueSize": 100,
25-
// Times a failed request will be retried
2617
"MaxRetries": 3,
27-
// Test file is used for aconvert.com client initialization
28-
// Should be a path to any media file supported by aconvert.com
2918
"TestFile": "test_media.webm",
30-
// Test format is used for aconvert.com client initialization
31-
// This is a target format for a media file specified above
3219
"TestFormat": "mp4"
3320
},
34-
// Number of maximum simultaneous media downloads
3521
"Workers": 13,
36-
// Temporary directory for media files
3722
"TempDir": "/tmp/hikkabot"
3823
},
3924
"Dvach": {
40-
// 2ch.hk client is updated with a cookie with this usercode
41-
// This may allow to access /e/, /hc/, etc.
4225
"Usercode": "fcdebafcde8642143"
4326
},
4427
"Reddit": {
@@ -47,7 +30,6 @@
4730
"Username": "username",
4831
"Password": "password",
4932
"UserAgent": "Your user agent 5.0",
50-
// Times a failed request will be retried
5133
"MaxRetries": 3
5234
}
5335
}

0 commit comments

Comments
 (0)