mirror of
https://github.com/idanoo/autobrr
synced 2025-07-23 16:59:12 +00:00
feat(indexers): add HUNO (#533)
This commit is contained in:
parent
1b6fd01575
commit
14ecaa530e
3 changed files with 95 additions and 0 deletions
|
@ -488,6 +488,13 @@ func (r *Release) MapVars(def *IndexerDefinition, varMap map[string]string) erro
|
|||
}
|
||||
}
|
||||
|
||||
if internal, err := getStringMapValue(varMap, "internal"); err == nil {
|
||||
i := StringEqualFoldMulti(internal, "internal", "yes", "1")
|
||||
if i {
|
||||
r.Origin = "INTERNAL"
|
||||
}
|
||||
}
|
||||
|
||||
if yearVal, err := getStringMapValue(varMap, "year"); err == nil {
|
||||
year, err := strconv.Atoi(yearVal)
|
||||
if err != nil {
|
||||
|
|
|
@ -243,6 +243,25 @@ func TestRelease_Parse(t *testing.T) {
|
|||
Other: []string{"HYBRiD", "REMUX"},
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "parse_title_1",
|
||||
fields: Release{
|
||||
TorrentName: "The Peripheral (2022) S01 (2160p AMZN WEB-DL H265 HDR10+ DDP 5.1 English - GROUP1)",
|
||||
},
|
||||
want: Release{
|
||||
TorrentName: "The Peripheral (2022) S01 (2160p AMZN WEB-DL H265 HDR10+ DDP 5.1 English - GROUP1)",
|
||||
Title: "The Peripheral",
|
||||
Resolution: "2160p",
|
||||
Source: "WEB-DL",
|
||||
Codec: []string{"H.265"},
|
||||
HDR: []string{"HDR10+"},
|
||||
Audio: []string{"DDP"},
|
||||
AudioChannels: "5.1",
|
||||
Year: 2022,
|
||||
Group: "GROUP1",
|
||||
Season: 1,
|
||||
},
|
||||
},
|
||||
}
|
||||
for _, tt := range tests {
|
||||
t.Run(tt.name, func(t *testing.T) {
|
||||
|
|
69
internal/indexer/definitions/huno.yaml
Normal file
69
internal/indexer/definitions/huno.yaml
Normal file
|
@ -0,0 +1,69 @@
|
|||
---
|
||||
#id: huno
|
||||
name: Huno
|
||||
identifier: huno
|
||||
description: Hawke-Uno (HUNO) is a private torrent tracker for MOVIES / TV.
|
||||
language: en-us
|
||||
urls:
|
||||
- https://hawke.uno
|
||||
privacy: private
|
||||
protocol: torrent
|
||||
supports:
|
||||
- irc
|
||||
- rss
|
||||
source: UNIT3D
|
||||
settings:
|
||||
- name: rsskey
|
||||
type: secret
|
||||
required: true
|
||||
label: RSS key (RID)
|
||||
help: "Go to your profile, My Security / RSS Key (RID) and copy your Current RID"
|
||||
|
||||
irc:
|
||||
network: Hawke-Uno
|
||||
server: irc.hawke.uno
|
||||
port: 6697
|
||||
tls: true
|
||||
channels:
|
||||
- "#huno_announce"
|
||||
announcers:
|
||||
- Luwin
|
||||
settings:
|
||||
- name: nick
|
||||
type: text
|
||||
required: true
|
||||
label: Nick
|
||||
help: Bot nick. Eg. user_bot
|
||||
|
||||
- name: auth.account
|
||||
type: text
|
||||
required: true
|
||||
label: NickServ Account
|
||||
help: NickServ account. Make sure to group your user and bot.
|
||||
|
||||
- name: auth.password
|
||||
type: secret
|
||||
required: true
|
||||
label: NickServ Password
|
||||
help: NickServ password
|
||||
|
||||
parse:
|
||||
type: single
|
||||
lines:
|
||||
- test:
|
||||
- "New in [Movie]: Old Movie (1981) (1080p BluRay x265 SDR DD 2.0 English - group1) [4.5 GiB] [FL: No] [INTERNAL: Yes] [https://hawke.uno/torrents/0000] by: [anon]"
|
||||
- "New in [TV]: Popular show (2022) S01E09 (1080p DSNP WEB-DL x265 SDR DDP Atmos 5.1 English - GROUP)[REPACK] [955.97 MiB] [FL: Yes] [INTERNAL: Yes] [https://hawke.uno/torrents/0000] by: [uploader]"
|
||||
pattern: 'New in \[(.*)\]: ((.*) \(\d+\)(?: S\d+E\d+)? \((.*)\))(?:\[(?:REPACK2|REPACK|PROPER)\])? \[(.*)\] \[FL: (Yes|No)\] \[Internal: (Yes|No)\] \[(https://.+)/torrents/(\d+)\] by: \[(.*)\]'
|
||||
vars:
|
||||
- category
|
||||
- torrentName
|
||||
- title
|
||||
- torrentSize
|
||||
- freeleech
|
||||
- internal
|
||||
- baseUrl
|
||||
- torrentId
|
||||
- uploader
|
||||
|
||||
match:
|
||||
torrenturl: "{{ .baseUrl }}/torrent/download/{{ .torrentId }}.{{ .rsskey }}"
|
Loading…
Add table
Add a link
Reference in a new issue