-
Notifications
You must be signed in to change notification settings - Fork 59
Upgrade from v1 to v2
You can set the bot to omit some fields when generating image captions.
Usage:
Set CAPTION_IGNORE
in environment variables, e.g.: CAPTION_IGNORE=bookmarked
Default is none.
Set IS_PUBLIC=true
to share your bot with everyone, default to false.
Coming soon...
To support Pixiv ugoira gif preview (sent as mp4) in Telegram, you should have ffmpeg installed.
For more information, refer to https://ffmpeg.org/, make sure libx264 encoder is installed.
On heroku, add a buildpack to your application:
heroku buildpacks:add --index 1 https://github.com/jonathanong/heroku-buildpack-ffmpeg-latest.git
You can now deploy Nazurin with docker-compose using docker-compose up -d --build
.
-
Add
ALLOW_ID
to replaceADMIN_ID
Set IDs of users with whom you want to share, separated by commas.
e.g.:
ALLOW_ID=12345,23456,34567
Default is none.
-
Add
ADMIN_USERNAME
to replaceALLOW_USERNAME
Set usernames of users with whom you want to share, without
@
, separated by commas.e.g.:
ALLOW_USERNAME=user1,user2,user3
Default is none.
-
ALLOW_GROUP
is renamed toGROUP_ID
Set IDs of groups in which all members have access to this bot, separated by commas.
e.g.:
ALLOW_GROUP=-12345,-23456
-
ADMIN_ID
You still need
ADMIN_ID
in order to receive error reports and have access to some restricted commands. -
User IDs & usernames both works now
While v1 supports either user ID or username, you may use both in v2.
-
Configurable option
STORAGE
is now a string seperated by commas(,
).e.g.:
# v1 STORAGE = ['Mega', 'GoogleDrive'] # v2 STORAGE = Mega,GoogleDrive
-
Local storage is now an independent storage
To use local storage, append
Local
toSTORAGE
, e.g.:STORAGE=Local,Mega
Instead of using
TEMP_DIR
, local storage now shareSTORAGE_DIR
configuration with remote storage. -
Telegram album channel is now a type of storage
Besides setting
ALBUM_ID
, appendTelegram
toSTORAGE
, e.g.:ALBUM_ID=-100123456 STORAGE=Telegram,Mega
-
Local storage destination changed
Local data including collection (
STORAGE_DIR
) and temporary files (TEMP_DIR
) are moved todata
folder at application root.Please create a folder named
data
in the main folder, and moveSTORAGE_DIR
(Default isPicutres
),TEMP_DIR
(Default istemp
) into the folder.
-
Local storage destination changed
Local database files are moved to
data
folder at application root.Please create a folder named
data
in the main folder, and move database files likenazurin.json
andpixiv.json
into the folder.
- Enhanced folder structure
- Switch to asyncio for better performance
- Retry when hitting flooding limits
- Retry for more network requests