nanozuki / dantalian Goto Github PK
View Code? Open in Web Editor NEWA nfo file generator for your anime. Source from Bangumi.
License: GNU General Public License v3.0
A nfo file generator for your anime. Source from Bangumi.
License: GNU General Public License v3.0
Regular expression is too hard to write, use and debugging, even to exprienced developers!
So I want to use template string to configure episode to replace reguar expression.
episode = ひぐらしのなく頃に 業 EP{ep}.mp4
for more complex example:
episode = [dantalian字幕组][化物語][{ep}][1080p].mp4
for sp:
odd taxi SP{sp}.mkv
For some animations, the ep in Bangumi is different from the ep in file name.
Example:
Bangumi: ep 25, https://bangumi.tv/ep/1227512
File name: Jujutsu.Kaisen.S02E01.2023.1080p.CR.WEB-DL.x264.AAC-ADWeb.mkv
We can fix this by adding an episode_offset
in config.
Support user to add custom tags in anime folder as below:
化物语 [2009][BDRip]
the content in these tags will be ignored.
dantalia -s ./anime_movies --movie
Search the tv anime "小魔女学园" in 2017 will match the movie "小魔女学园 魔法游行"; Search "リトルウィッチアカデミア" will match the OVA "小魔女学园" in 2013.
So,
Format output in the command line, make it easy to use.
Add toggle switch to display debug info.
dantalian bgm get 331535
will failed because of
1: missing field `eps` at line 1 column 16567
Crate: hyper
Version: 0.14.7
Title: Lenient `hyper` header parsing of `Content-Length` could allow request smuggling
Date: 2021-07-07
ID: RUSTSEC-2021-0078
URL: https://rustsec.org/advisories/RUSTSEC-2021-0078
Solution: Upgrade to >=0.14.10
Dependency tree:
hyper 0.14.7
├── hyper-tls 0.5.0
│ └── dantalian 0.3.3
└── dantalian 0.3.3
Crate: hyper
Version: 0.14.7
Title: Integer overflow in `hyper`'s parsing of the `Transfer-Encoding` header leads to data loss
Date: 2021-07-07
ID: RUSTSEC-2021-0079
URL: https://rustsec.org/advisories/RUSTSEC-2021-0079
Solution: Upgrade to >=0.14.10
Crate: tokio
Version: 1.5.0
Title: Task dropped in wrong thread when aborting `LocalSet` task
Date: 2021-07-07
ID: RUSTSEC-2021-0072
URL: https://rustsec.org/advisories/RUSTSEC-2021-0072
Solution: Upgrade to >=1.5.1, <1.6.0 OR >=1.6.3, <1.7.0 OR >=1.7.2, <1.8.0 OR >=1.8.1
Dependency tree:
tokio 1.5.0
├── tokio-util 0.6.6
│ └── h2 0.3.3
│ └── hyper 0.14.7
│ ├── hyper-tls 0.5.0
│ │ └── dantalian 0.3.3
│ └── dantalian 0.3.3
├── tokio-native-tls 0.3.0
│ └── hyper-tls 0.5.0
├── hyper-tls 0.5.0
├── hyper 0.14.7
├── h2 0.3.3
└── dantalian 0.3.3
error: 3 vulnerabilities found!
Example: Mushoku.Tensei.Isekai.Ittara.Honki.Dasu.S02E00.2023.1080p.CR.WEB-DL.x264.AAC-ADWeb.mkv
https://bgm.tv/ep/1212094
Result:
Check ./Mushoku.Tensei.Isekai.Ittara.Honki.Dasu.S02.2023.1080p.CR.WEB-DL.x264.AAC-ADWeb ...
Parse config file
Fetch anime data for: [373247] 無職転生Ⅱ ~異世界行ったら本気だす~ / 无职转生Ⅱ ~到了异世界就拿出真本事~
Generate ./Mushoku.Tensei.Isekai.Ittara.Honki.Dasu.S02.2023.1080p.CR.WEB-DL.x264.AAC-ADWeb/Mushoku.Tensei.Isekai.Ittara.Honki.Dasu.S02E00.2023.1080p.CR.WEB-DL.x264.AAC-ADWeb.nfo ...
Failed: Can't find ep , is_sp false
Can't find ep , is_sp false
After I read the code, I found that in job.rs
:
let ep: String = match caps.as_ref().and_then(|c| c.name("ep")) {
Some(ep_match) => {
String::from(ep_match.as_str().parse::<String>()?.trim_start_matches('0'))
}
None => return Ok(None),
};
trim_start_matches('0')
trims all 0, then ep is "".
It would be great if a windows release can be added :)
Add action to auto-release dantalian.
Once tagged commit, add release includes Linux, BSD, and OSX versions, and publish to crates.io.
In some cases, getting some subjects will return 404 response if using non-authorized user. We can add access token in header to get correct subjects and episodes info.
Example:
dantalian --access_token <access_token> --source <SOURCE>
Access token can be generated in https://next.bgm.tv/demo/access-token.
/lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.32' not found
<rating>9<rating>
I tried the new release bin to generate nfo files with access token but still not working.
Just found getting subject api url in https://bangumi.github.io/api/#/%E6%9D%A1%E7%9B%AE/getSubjectById is https://api.bgm.tv/v0/subjects/{subject_id} but dantalian is using https://api.bgm.tv/subject/{subject_id}.
Trying curl -X 'GET' 'https://api.bgm.tv/subject/354246' -H 'accept: application/json' -H 'Authorization: Bearer <token>'
will return 404 response, curl -X 'GET' 'https://api.bgm.tv/v0/subjects/354246' -H 'accept: application/json' -H 'Authorization: Bearer <token>'
will get the correct response, and the same as getting episode data.
By the way, can dantalian bgm
also add access token parameter?
Relay to #51
Thanks.
I cannot find any code about proxy, and it seems hyper
does not do this without configuration. (FYI reqwest
has that function)
My server cannot reach bgm.tv without a proxy. orz
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.