Re: Custom AMC features (AniDB Maps, Sonarr, Couchpotato, et
Posted: 14 May 2016, 04:17
I set it up as a separate shell script then run
--def exec=/pathto/Sonarrrefresh.sh
--def exec=/pathto/Sonarrrefresh.sh
The ultimate TV and Movie Renamer
https://www.filebot.net/forums/
Welp I tried that had to change the shell script though to a bat since I'm on windows and honestly don't feel like going through and downloading more than I need to to get this stuff working and well it didn't even work... :/porkchop999 wrote:I set it up as a separate shell script then run
--def exec=/pathto/Sonarrrefresh.sh
Says it executed the bat file but when I go to sonarr nothing has changed and it still shows me missing the episode.Run script [fn:amc] at [Fri May 13 23:46:17 CDT 2016]
Parameter: ut_dir = C:\Users\timta\Desktop\QBT\The.100.S03E15.720p.HDTV.2CH.x265.HEVC-PSA.mkv
Parameter: ut_kind = multi
Parameter: ut_title = The.100.S03E15.720p.HDTV.2CH.x265.HEVC-PSA.mkv
Parameter: ut_label =
Parameter: seriesFormat = D:/Shows/TV Shows/{n}/season {s.pad(2)}/{n} - {s00e00} - {t}
Parameter: movieFormat = D:/Shows/Movies/{n} {[y, rating]}/{n}
Parameter: animeFormat = D:/Shows/Anime/{n}/season {s.pad(2)}/{n} - {s00e00} - {t}
Parameter: deleteAfterExtract = y
Parameter: clean = y
Parameter: exec = C:\Users\timta\Dropbox\Public\Folders\Filebot\Groovy\Sonarrrefresh.bat
Input: C:\Users\timta\Desktop\QBT\The.100.S03E15.720p.HDTV.2CH.x265.HEVC-PSA.mkv
Group: [tvs:the 100] => [The.100.S03E15.720p.HDTV.2CH.x265.HEVC-PSA.mkv]
Rename episodes using [TheTVDB]
Auto-detected query: [The 100]
Fetching episode data for [The 100]
Fetching episode data for [The 100 Scariest Movie Moments]
Fetching episode data for [The 100 Lives of Black Jack Savage]
Apply Filter: {age < 170}
Include [The 100 - 3x01 - Wanheda (1)]
Include [The 100 - 3x02 - Wanheda (2)]
Include [The 100 - 3x03 - Ye Who Enter Here]
Include [The 100 - 3x04 - Watch the Thrones]
Include [The 100 - 3x05 - Hakeldama]
Include [The 100 - 3x06 - Bitter Harvest]
Include [The 100 - 3x07 - Thirteen]
Include [The 100 - 3x08 - Terms and Conditions]
Include [The 100 - 3x09 - Stealing Fire]
Include [The 100 - 3x10 - Fallen]
Include [The 100 - 3x11 - Nevermore]
Include [The 100 - 3x12 - Demons]
Include [The 100 - 3x13 - Join or Die]
Include [The 100 - 3x14 - Red Sky at Morning]
Include [The 100 - 3x15 - Perverse Instantiation (1)]
[MOVE] Rename [C:\Users\timta\Desktop\QBT\The.100.S03E15.720p.HDTV.2CH.x265.HEVC-PSA.mkv] to [D:\Shows\TV Shows\The 100\season 03\The 100 - S03E15 - Perverse Instantiation (1).mkv]
Processed 1 files
Execute: C:\Users\timta\Dropbox\Public\Folders\Filebot\Groovy\Sonarrrefresh.bat
Done ヾ(@⌒ー⌒@)ノ
Code: Select all
curl http://localhost:8989/api/command -X POST -d "{'name':'refreshseries'}" --header "X-Api-Key:(api key)"
Code: Select all
filebot -script fn:amc --log-file amc.log --conflict override -non-strict --filter "age < 170" --def "ut_dir=%F" "ut_kind=multi" "ut_title=%N" "ut_label=%L" "seriesFormat=D:/Shows/TV Shows/{n}/season {s.pad(2)}/{n} - {s00e00} - {t}" "movieFormat=D:/Shows/Movies/{n} {[y, rating]}/{n}" "animeFormat=D:/Shows/Anime/{n}/season {s.pad(2)}/{n} - {s00e00} - {t}" deleteAfterExtract=y clean=y --def exec="curl http://localhost:8989/api/command -X POST -d "{'name':'refreshseries'}" --header "X-Api-Key:(api key)"
Code: Select all
Run script [fn:amc] at [Fri May 13 23:56:40 CDT 2016]
Parameter: ut_dir = C:\Users\timta\Desktop\QBT\The.100.S03E15.720p.HDTV.2CH.x265.HEVC-PSA.mkv
Parameter: ut_kind = multi
Parameter: ut_title = The.100.S03E15.720p.HDTV.2CH.x265.HEVC-PSA.mkv
Parameter: ut_label =
Parameter: seriesFormat = D:/Shows/TV Shows/{n}/season {s.pad(2)}/{n} - {s00e00} - {t}
Parameter: movieFormat = D:/Shows/Movies/{n} {[y, rating]}/{n}
Parameter: animeFormat = D:/Shows/Anime/{n}/season {s.pad(2)}/{n} - {s00e00} - {t}
Parameter: deleteAfterExtract = y
Parameter: clean = y
Parameter: exec = curl http://localhost:8989/api/command -X POST -d {'name':'refreshseries'} --header X-Api-Key:(api key)
Input: C:\Users\timta\Desktop\QBT\The.100.S03E15.720p.HDTV.2CH.x265.HEVC-PSA.mkv
Group: [tvs:the 100] => [The.100.S03E15.720p.HDTV.2CH.x265.HEVC-PSA.mkv]
Rename episodes using [TheTVDB]
Auto-detected query: [The 100]
Fetching episode data for [The 100]
Fetching episode data for [The 100 Scariest Movie Moments]
Fetching episode data for [The 100 Lives of Black Jack Savage]
Apply Filter: {age < 170}
Include [The 100 - 3x01 - Wanheda (1)]
Include [The 100 - 3x02 - Wanheda (2)]
Include [The 100 - 3x03 - Ye Who Enter Here]
Include [The 100 - 3x04 - Watch the Thrones]
Include [The 100 - 3x05 - Hakeldama]
Include [The 100 - 3x06 - Bitter Harvest]
Include [The 100 - 3x07 - Thirteen]
Include [The 100 - 3x08 - Terms and Conditions]
Include [The 100 - 3x09 - Stealing Fire]
Include [The 100 - 3x10 - Fallen]
Include [The 100 - 3x11 - Nevermore]
Include [The 100 - 3x12 - Demons]
Include [The 100 - 3x13 - Join or Die]
Include [The 100 - 3x14 - Red Sky at Morning]
Include [The 100 - 3x15 - Perverse Instantiation (1)]
[MOVE] Rename [C:\Users\timta\Desktop\QBT\The.100.S03E15.720p.HDTV.2CH.x265.HEVC-PSA.mkv] to [D:\Shows\TV Shows\The 100\season 03\The 100 - S03E15 - Perverse Instantiation (1).mkv]
Processed 1 files
ScriptException: SyntaxError: expecting EOF, found ':'
Execute: null
NullPointerException: java.lang.NullPointerException
java.lang.NullPointerException
at net.filebot.cli.ScriptShellBaseClass.execute(ScriptShellBaseClass.java:271)
at Script1$_run_closure74.doCall(Script1.groovy:455)
at Script1.run(Script1.groovy:453)
at net.filebot.cli.ScriptShell.evaluate(ScriptShell.java:61)
at net.filebot.cli.ScriptShell.runScript(ScriptShell.java:82)
at net.filebot.cli.ArgumentProcessor.process(ArgumentProcessor.java:116)
at net.filebot.Main.main(Main.java:169)
Failure (°_°)
Code: Select all
{'name':'refreshseries'}
Code: Select all
filebot -script fn:amc --log-file amc.log --conflict override -non-strict --filter "age < 170" --def "ut_dir=%F" "ut_kind=multi" "ut_title=%N" "ut_label=%L" "seriesFormat=D:/Shows/TV Shows/{n}/season {s.pad(2)}/{n.replaceTrailingBrackets()} - {s00e00} - {t.replaceAll(/[!?.]+$/).replaceAll(/[\`´‘’ʻ]/, /"'/") .lowerTrail().replacePart(', Part $1')}" "movieFormat=D:/Shows/Movies/{n} {[y]}/{n.replaceTrailingBrackets() replaceAll(/[!?.]+$/).replaceAll(/[\`´‘’ʻ]/, /"'/") lowerTrail()} [{y}]" "animeFormat=D:/Shows/Anime/{n}/season {s.pad(2)}/{n.replaceTrailingBrackets()} - {s00e00} - {t.replaceAll(/[!?.]+$/).replaceAll(/[\`´‘’ʻ]/, /"'/") .lowerTrail().replacePart(', Part $1')}" deleteAfterExtract=y clean=y --def exec="curl http://localhost:8989/api/command -X POST -d "{/'name':/'refreshseries'}" --header "X-Api-Key:(api key)"
Code: Select all
Run script [fn:amc] at [Sat May 14 12:16:15 CDT 2016]
Parameter: ut_dir = C:\Users\timta\Desktop\QBT\The.Flash.2014.S02E21.The.Runaway.Dinosaur.720p.WEB-DL.2CH.x265.HEVC-PSA.mkv
Parameter: ut_kind = multi
Parameter: ut_title = The.Flash.2014.S02E21.The.Runaway.Dinosaur.720p.WEB-DL.2CH.x265.HEVC-PSA.mkv
Parameter: ut_label =
Parameter: seriesFormat = D:/Shows/TV Shows/{n}/season {s.pad(2)}/{n.replaceTrailingBrackets()} - {s00e00} - {t.replaceAll(/[!?.]+$/).replaceAll(/[\`´‘’?]/, /'/) .lowerTrail().replacePart(', Part $1')}
Parameter: movieFormat = D:/Shows/Movies/{n} {[y]}/{n.replaceTrailingBrackets() replaceAll(/[!?.]+$/).replaceAll(/[\`´‘’?]/, /'/) lowerTrail()} [{y}]
Parameter: animeFormat = D:/Shows/Anime/{n}/season {s.pad(2)}/{n.replaceTrailingBrackets()} - {s00e00} - {t.replaceAll(/[!?.]+$/).replaceAll(/[\`´‘’?]/, /'/) .lowerTrail().replacePart(', Part $1')}
Parameter: deleteAfterExtract = y
Parameter: clean = y
Parameter: exec = curl http://localhost:8989/api/command/ -X POST -d {/'name':/'refreshseries'} --header X-Api-Key:(api key)
Input: C:\Users\timta\Desktop\QBT\The.Flash.2014.S02E21.The.Runaway.Dinosaur.720p.WEB-DL.2CH.x265.HEVC-PSA.mkv
Group: [tvs:the flash 2014] => [The.Flash.2014.S02E21.The.Runaway.Dinosaur.720p.WEB-DL.2CH.x265.HEVC-PSA.mkv]
Rename episodes using [TheTVDB]
Auto-detected query: [The Flash 2014]
Fetching episode data for [The Flash (2014)]
Apply Filter: {age < 170}
Include [The Flash (2014) - 2x08 - Legends of Today (1)]
Include [The Flash (2014) - 2x09 - Running to Stand Still]
Include [The Flash (2014) - 2x10 - Potential Energy]
Include [The Flash (2014) - 2x11 - The Reverse-Flash Returns]
Include [The Flash (2014) - 2x12 - Fast Lane]
Include [The Flash (2014) - 2x13 - Welcome to Earth-2]
Include [The Flash (2014) - 2x14 - Escape from Earth-2]
Include [The Flash (2014) - 2x15 - King Shark]
Include [The Flash (2014) - 2x16 - Trajectory]
Include [The Flash (2014) - 2x17 - Flash Back]
Include [The Flash (2014) - 2x18 - Versus Zoom]
Include [The Flash (2014) - 2x19 - Back to Normal]
Include [The Flash (2014) - 2x20 - Rupture]
Include [The Flash (2014) - 2x21 - The Runaway Dinosaur]
Include [The Flash (2014) - 0xSpecial 1 - The Chronicles Of Cisco: Entry 0419 - Part 1]
Include [The Flash (2014) - 0xSpecial 2 - The Chronicles Of Cisco: Entry 0419 - Part 2]
Include [The Flash (2014) - 0xSpecial 3 - The Chronicles Of Cisco: Entry 0419 - Part 3]
Include [The Flash (2014) - 0xSpecial 4 - The Chronicles Of Cisco: Entry 0419 - Part 4]
[MOVE] Rename [C:\Users\timta\Desktop\QBT\The.Flash.2014.S02E21.The.Runaway.Dinosaur.720p.WEB-DL.2CH.x265.HEVC-PSA.mkv] to [D:\Shows\TV Shows\The Flash (2014)\season 02\The Flash - S02E21 - The Runaway Dinosaur.mkv]
Processed 1 files
Execute: curl http://localhost:8989/api/command/ -X POST -d --header X-Api-Key:(api key)
Done ヾ(@⌒ー⌒@)ノ
rednoah wrote:You need to figure out how to update sonarr from CMD first. I doubt that curl works in CMD.
Code: Select all
$url = "http://localhost:8989/api/command"
$json = "{ ""name"": ""downloadedepisodesscan"" }"
Write-Host "Publishing update $version ($branch) to: $url"
Invoke-RestMethod -Uri $url -Method Post -Body $json -Headers @{"X-Api-Key"="YOUR_API_KEY_GOES_HERE"}
Code: Select all
powershell.exe -ExecutionPolicy Bypass -Command "C:\Users\timta\Dropbox\Public\Folders\Filebot\Groovy\Sonarrrefresh.ps1"
Code: Select all
filebot -script fn:amc --log-file amc.log --conflict override -non-strict --filter "age < 170" --def "ut_dir=%F" "ut_kind=multi" "ut_title=%N" "ut_label=%L" "seriesFormat=D:/Shows/TV Shows/{n}/season {s.pad(2)}/{n.replaceTrailingBrackets()} - {s00e00} - {t.replaceAll(/[!?.]+$/).replaceAll(/[\`´‘’ʻ]/, /"'/") .lowerTrail().replacePart(', Part $1')}" "movieFormat=D:/Shows/Movies/{n} {[y]}/{n.replaceTrailingBrackets() replaceAll(/[!?.]+$/).replaceAll(/[\`´‘’ʻ]/, /"'/") lowerTrail()} [{y}]" "animeFormat=D:/Shows/Anime/{n}/season {s.pad(2)}/{n.replaceTrailingBrackets()} - {s00e00} - {t.replaceAll(/[!?.]+$/).replaceAll(/[\`´‘’ʻ]/, /"'/") .lowerTrail().replacePart(', Part $1')}" deleteAfterExtract=y clean=y --def exec="C:\Users\timta\Dropbox\Public\Folders\Filebot\Groovy\callpowershell.bat"
Code: Select all
PS C:\Users\timta\Dropbox\Public\Folders\Filebot\Groovy> $url = "http://localhost:8989/api/command"
$json = "{ ""name"": ""downloadedepisodesscan"" }"
Write-Host "Publishing update $version ($branch) to: $url"
Invoke-RestMethod -Uri $url -Method Post -Body $json -Headers @{"X-Api-Key"="6e7bff2e25e24317924907b16e6b7eee"}
Publishing update () to: http://localhost:8989/api/command
name : DownloadedEpisodesScan
body : @{sendUpdatesToClient=False; sendUpdates=False; updateScheduledTask=True; completionMessage=Completed; name=DownloadedEpisodesScan; trigger=manual}
priority : normal
status : queued
queued : 0001-01-01T00:00:00Z
trigger : manual
state : queued
manual : True
startedOn : 0001-01-01T00:00:00Z
sendUpdatesToClient : False
updateScheduledTask : True
id : 58310
Code: Select all
Parameter: ut_dir = C:\Users\timta\Desktop\QBT\The.Flash.2014.S02E21.720p.WEB-DL.DD5.1.H.264-VietHD.mkv
Parameter: ut_kind = multi
Parameter: ut_title = The.Flash.2014.S02E21.720p.WEB-DL.DD5.1.H.264-VietHD.mkv
Parameter: ut_label = tv-sonarr
Parameter: seriesFormat = D:/Shows/TV Shows/{n}/season {s.pad(2)}/{n.replaceTrailingBrackets()} - {s00e00} - {t.replaceAll(/[!?.]+$/).replaceAll(/[\`´‘’?]/, /'/) .lowerTrail().replacePart(', Part $1')}
Parameter: movieFormat = D:/Shows/Movies/{n} {[y]}/{n.replaceTrailingBrackets() replaceAll(/[!?.]+$/).replaceAll(/[\`´‘’?]/, /'/) lowerTrail()} [{y}]
Parameter: animeFormat = D:/Shows/Anime/{n}/season {s.pad(2)}/{n.replaceTrailingBrackets()} - {s00e00} - {t.replaceAll(/[!?.]+$/).replaceAll(/[\`´‘’?]/, /'/) .lowerTrail().replacePart(', Part $1')}
Parameter: deleteAfterExtract = y
Parameter: clean = y
Parameter: exec = C:\Users\timta\Dropbox\Public\Folders\Filebot\Groovy\callpowershell.bat
Roots: [C:\Users\timta\Desktop\QBT\The.Flash.2014.S02E21.720p.WEB-DL.DD5.1.H.264-VietHD.mkv]
Input: C:\Users\timta\Desktop\QBT\The.Flash.2014.S02E21.720p.WEB-DL.DD5.1.H.264-VietHD.mkv
Group: [order:airdate, tvs:the flash 2014] => [The.Flash.2014.S02E21.720p.WEB-DL.DD5.1.H.264-VietHD.mkv]
Using TV Order: airdate
Rename episodes using [TheTVDB]
Auto-detected query: [The Flash 2014]
Fetching episode data for [The Flash (2014)]
Apply Filter: {age < 170}
Include [The Flash (2014) - 2x08 - Legends of Today (1)]
Include [The Flash (2014) - 2x09 - Running to Stand Still]
Include [The Flash (2014) - 2x10 - Potential Energy]
Include [The Flash (2014) - 2x11 - The Reverse-Flash Returns]
Include [The Flash (2014) - 2x12 - Fast Lane]
Include [The Flash (2014) - 2x13 - Welcome to Earth-2]
Include [The Flash (2014) - 2x14 - Escape from Earth-2]
Include [The Flash (2014) - 2x15 - King Shark]
Include [The Flash (2014) - 2x16 - Trajectory]
Include [The Flash (2014) - 2x17 - Flash Back]
Include [The Flash (2014) - 2x18 - Versus Zoom]
Include [The Flash (2014) - 2x19 - Back to Normal]
Include [The Flash (2014) - 2x20 - Rupture]
Include [The Flash (2014) - 2x21 - The Runaway Dinosaur]
Include [The Flash (2014) - 0xSpecial 1 - The Chronicles Of Cisco: Entry 0419 - Part 1]
Include [The Flash (2014) - 0xSpecial 2 - The Chronicles Of Cisco: Entry 0419 - Part 2]
Include [The Flash (2014) - 0xSpecial 3 - The Chronicles Of Cisco: Entry 0419 - Part 3]
Include [The Flash (2014) - 0xSpecial 4 - The Chronicles Of Cisco: Entry 0419 - Part 4]
[MOVE] Rename [C:\Users\timta\Desktop\QBT\The.Flash.2014.S02E21.720p.WEB-DL.DD5.1.H.264-VietHD.mkv] to [D:\Shows\TV Shows\The Flash (2014)\season 02\The Flash - S02E21 - The Runaway Dinosaur.mkv]
Processed 1 files
The Flash - S02E21 - The Runaway Dinosaur.mkv
Execute: C:\Users\timta\Dropbox\Public\Folders\Filebot\Groovy\callpowershell.bat
Done ヾ(@⌒ー⌒@)ノ
runningrednoah wrote:Try adding cmd /c before your bat script.
Code: Select all
filebot -script fn:amc --log-file amc.log --conflict override -non-strict --filter "age < 170" --def "ut_dir=%F" "ut_kind=multi" "ut_title=%N" "ut_label=%L" "seriesFormat=D:/Shows/TV Shows/{n}/season {s.pad(2)}/{n.replaceTrailingBrackets()} - {s00e00} - {t.replaceAll(/[!?.]+$/).replaceAll(/[\`´‘’ʻ]/, /"'/") .lowerTrail().replacePart(', Part $1')}" "movieFormat=D:/Shows/Movies/{n} {[y]}/{n.replaceTrailingBrackets() replaceAll(/[!?.]+$/).replaceAll(/[\`´‘’ʻ]/, /"'/") lowerTrail()} [{y}]" "animeFormat=D:/Shows/Anime/{n}/season {s.pad(2)}/{n.replaceTrailingBrackets()} - {s00e00} - {t.replaceAll(/[!?.]+$/).replaceAll(/[\`´‘’ʻ]/, /"'/") .lowerTrail().replacePart(', Part $1')}" deleteAfterExtract=y clean=y --def exec="cmd /c C:\Users\timta\Dropbox\Public\Folders\Filebot\Groovy\callpowershell.bat"
Code: Select all
Run script [fn:amc] at [Sun May 15 01:13:17 CDT 2016]
Parameter: ut_dir = C:\Users\timta\Desktop\QBT\The.Flash.2014.S02E21.720p.WEB-DL.DD5.1.H.264-VietHD.mkv
Parameter: ut_kind = multi
Parameter: ut_title = The.Flash.2014.S02E21.720p.WEB-DL.DD5.1.H.264-VietHD.mkv
Parameter: ut_label = tv-sonarr
Parameter: seriesFormat = D:/Shows/TV Shows/{n}/season {s.pad(2)}/{n.replaceTrailingBrackets()} - {s00e00} - {t.replaceAll(/[!?.]+$/).replaceAll(/[\`´‘’?]/, /'/) .lowerTrail().replacePart(', Part $1')}
Parameter: movieFormat = D:/Shows/Movies/{n} {[y]}/{n.replaceTrailingBrackets() replaceAll(/[!?.]+$/).replaceAll(/[\`´‘’?]/, /'/) lowerTrail()} [{y}]
Parameter: animeFormat = D:/Shows/Anime/{n}/season {s.pad(2)}/{n.replaceTrailingBrackets()} - {s00e00} - {t.replaceAll(/[!?.]+$/).replaceAll(/[\`´‘’?]/, /'/) .lowerTrail().replacePart(', Part $1')}
Parameter: deleteAfterExtract = y
Parameter: clean = y
Parameter: exec = cmd /c C:\Users\timta\Dropbox\Public\Folders\Filebot\Groovy\callpowershell.bat
Input: C:\Users\timta\Desktop\QBT\The.Flash.2014.S02E21.720p.WEB-DL.DD5.1.H.264-VietHD.mkv
Group: [tvs:the flash 2014] => [The.Flash.2014.S02E21.720p.WEB-DL.DD5.1.H.264-VietHD.mkv]
Rename episodes using [TheTVDB]
Auto-detected query: [The Flash 2014]
Fetching episode data for [The Flash (2014)]
Apply Filter: {age < 170}
Include [The Flash (2014) - 2x08 - Legends of Today (1)]
Include [The Flash (2014) - 2x09 - Running to Stand Still]
Include [The Flash (2014) - 2x10 - Potential Energy]
Include [The Flash (2014) - 2x11 - The Reverse-Flash Returns]
Include [The Flash (2014) - 2x12 - Fast Lane]
Include [The Flash (2014) - 2x13 - Welcome to Earth-2]
Include [The Flash (2014) - 2x14 - Escape from Earth-2]
Include [The Flash (2014) - 2x15 - King Shark]
Include [The Flash (2014) - 2x16 - Trajectory]
Include [The Flash (2014) - 2x17 - Flash Back]
Include [The Flash (2014) - 2x18 - Versus Zoom]
Include [The Flash (2014) - 2x19 - Back to Normal]
Include [The Flash (2014) - 2x20 - Rupture]
Include [The Flash (2014) - 2x21 - The Runaway Dinosaur]
Include [The Flash (2014) - 0xSpecial 1 - The Chronicles Of Cisco: Entry 0419 - Part 1]
Include [The Flash (2014) - 0xSpecial 2 - The Chronicles Of Cisco: Entry 0419 - Part 2]
Include [The Flash (2014) - 0xSpecial 3 - The Chronicles Of Cisco: Entry 0419 - Part 3]
Include [The Flash (2014) - 0xSpecial 4 - The Chronicles Of Cisco: Entry 0419 - Part 4]
[MOVE] Rename [C:\Users\timta\Desktop\QBT\The.Flash.2014.S02E21.720p.WEB-DL.DD5.1.H.264-VietHD.mkv] to [D:\Shows\TV Shows\The Flash (2014)\season 02\The Flash - S02E21 - The Runaway Dinosaur.mkv]
Processed 1 files
Execute: cmd /c C:\Users\timta\Dropbox\Public\Folders\Filebot\Groovy\callpowershell.bat
Done ヾ(@⌒ー⌒@)ノ
Code: Select all
$url = "http://localhost:8989/api/command"
$json = "{ ""name"": ""RescanSeries"" }"
Write-Host "Publishing update $version ($branch) to: $url"
Invoke-RestMethod -Uri $url -Method Post -Body $json -Headers @{"X-Api-Key"="6e7bff2e25e24317924907b16e6b7eee"}
Code: Select all
$url = "http://localhost:8989/api/command"
$json = "{ ""name"": ""RefreshSeries"" }"
Write-Host "Publishing update $version ($branch) to: $url"
Invoke-RestMethod -Uri $url -Method Post -Body $json -Headers @{"X-Api-Key"="6e7bff2e25e24317924907b16e6b7eee"}
Code: Select all
Parameters
Optional:
seriesId (int) - if not set all series will be refreshed and scanned
Code: Select all
--def exec=notepad
I already have it refreshing series/rescanning series now since I finally found out what the issue was, main thing now is getting it to only refresh/rescan the series that is downloaded instead of every single series I have on sonarr but I have to figure out how to getrednoah wrote:Try something simple and see if it works:This should start notepad.Code: Select all
--def exec=notepad
Code: Select all
seriesId (int)
Code: Select all
$url = "http://localhost:8989/api/command"
$json = "{ ""name"": ""RescanSeries"" }"
Write-Host "Publishing update $version ($branch) to: $url"
Invoke-RestMethod -Uri $url -Method Post -Body $json -Headers @{"X-Api-Key"="(api key)"}
Hey rednoah,rednoah wrote:The caching API has been rewritten. Scripts that use internal old API that doesn't exist anymore break of course.
I fixed a similar issue in update-mes this week. Look at the latest commit.
However, there will probably be few more issues once you fix that one. If you don't know what you're doing, you will not be able to fix this.
Code: Select all
def page = 'update.xml'
def text = Cache.getCache('my_text_store', CacheType.Persistent).text(page) {
new URL('http://app.filebot.net/'+it)
}.expire(Cache.ONE_MONTH).get()
println text
Code: Select all
def key = 'update.xml'
def dom = Cache.getCache('my_xml_store', CacheType.Persistent).xml(key) {
new URL('http://app.filebot.net/'+it)
}.expire(Cache.ONE_MONTH).get()
print dom.documentElement
Sadly the fix that you pushed didn't work at all.. it still throws up errors :ccowmix wrote:Pushed a fix to github, sorry for the delay.