Kodi Community Forum
XBMC.MyLibrary - Scan any source to the library (Hulu/Netflix/Plugins) - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Supplementary Tools for Kodi (https://forum.kodi.tv/forumdisplay.php?fid=116)
+--- Thread: XBMC.MyLibrary - Scan any source to the library (Hulu/Netflix/Plugins) (/showthread.php?tid=98210)



RE: XBMC.MyLibrary - Scan any source to the library (Hulu/Netflix/Plugins) - n4tur3502 - 2014-01-09

ok i am without a doubt a noob for this, i'm not finding any info so if i'm just missing it in search please let me know. i'm attempting to add shows from the freecable addon,when i run the bat file it doesnt see anything from freecable and deletes the folders i created in my dropbox folder. any help would be awesome


RE: XBMC.MyLibrary - Scan any source to the library (Hulu/Netflix/Plugins) - spanktastic2120 - 2014-01-09

(2014-01-09, 19:48)n4tur3502 Wrote: ok i am without a doubt a noob for this, i'm not finding any info so if i'm just missing it in search please let me know. i'm attempting to add shows from the freecable addon,when i run the bat file it doesnt see anything from freecable and deletes the folders i created in my dropbox folder. any help would be awesome

http://forum.xbmc.org/showthread.php?tid=98210&pid=1545989#pid1545989


RE: XBMC.MyLibrary - Scan any source to the library (Hulu/Netflix/Plugins) - denz13 - 2014-01-12

Hi guys,
Pretty embarrassed to have to post here, as I'm sure I'm missing something blindingly obvious from my config.xml which is causing it not to work.

Firstly, I'm running XBMC on a standalone PC, so really confused as to where this is going wrong, here's my config.xml file: http://pastebin.com/StHXDmft

This is the error I'm getting when attempting to run the run-x64.bat file:

01/12/2014 12:23:51 AM NOTICE Init... Start XBMC.MyLibrary, v1.4.3, compatible with XBMC Frodo
01/12/2014 12:23:51 AM NOTICE Init... Base program directory = M:\XBMC Stuff\XBMCMyLibrary
01/12/2014 12:23:51 AM ERROR Init... Could not find valid xml document at: M:\XBMC Stuff\XBMCMyLibrary\Config.xml. Cannot continue... Please check config.xml with an XML validator.
01/12/2014 12:23:51 AM ERROR Init... Failed while loading Configuration and testing connections... cannot continue. Please check your settings in Config.xml

I can confirm that webserver is active on XBMC, using port 80, with no username or password.

The Dropbox directory (and subfolders within it) are in the same directory as the mylibrary files,

Any help would be highly appreciated.


RE: XBMC.MyLibrary - Scan any source to the library (Hulu/Netflix/Plugins) - spanktastic2120 - 2014-01-12

(2014-01-12, 02:48)denz13 Wrote: Hi guys,
Pretty embarrassed to have to post here, as I'm sure I'm missing something blindingly obvious from my config.xml which is causing it not to work.

Firstly, I'm running XBMC on a standalone PC, so really confused as to where this is going wrong, here's my config.xml file: http://pastebin.com/StHXDmft

This is the error I'm getting when attempting to run the run-x64.bat file:

01/12/2014 12:23:51 AM NOTICE Init... Start XBMC.MyLibrary, v1.4.3, compatible with XBMC Frodo
01/12/2014 12:23:51 AM NOTICE Init... Base program directory = M:\XBMC Stuff\XBMCMyLibrary
01/12/2014 12:23:51 AM ERROR Init... Could not find valid xml document at: M:\XBMC Stuff\XBMCMyLibrary\Config.xml. Cannot continue... Please check config.xml with an XML validator.
01/12/2014 12:23:51 AM ERROR Init... Failed while loading Configuration and testing connections... cannot continue. Please check your settings in Config.xml

I can confirm that webserver is active on XBMC, using port 80, with no username or password.

The Dropbox directory (and subfolders within it) are in the same directory as the mylibrary files,

Any help would be highly appreciated.

it tells you what to do, check your config.xml with an xml validator. you probably forgot to close a tag or something. give this a try and see if you cant sort out the issue, http://www.w3schools.com/xml/xml_validator.asp


RE: XBMC.MyLibrary - Scan any source to the library (Hulu/Netflix/Plugins) - denz13 - 2014-01-12

Thanks for the quick reply, I'm getting "Error on line 5 column 1: Document is empty


Line 5 of the xml is:
-<root>

I've not edited the original xml other than the <xbmcwebserver> & <streaming> lines, so not sure why it's reporting an error on line 5??


RE: XBMC.MyLibrary - Scan any source to the library (Hulu/Netflix/Plugins) - bradvido88 - 2014-01-12

You seem to have hyphens before your xml tags
-<root> should be <root>

The Config.xml that ships with it does not have that. Not sure how they got there, but definitely not valid XML


RE: XBMC.MyLibrary - Scan any source to the library (Hulu/Netflix/Plugins) - denz13 - 2014-01-12

I'll check that out, I've been using notepad++ to edit so I'm not sure if that's automatically inserted something for what ever reason.

Thanks for the above though!


RE: XBMC.MyLibrary - Scan any source to the library (Hulu/Netflix/Plugins) - bradvido88 - 2014-01-12

(2014-01-12, 03:50)denz13 Wrote: I'll check that out, I've been using notepad++ to edit so I'm not sure if that's automatically inserted something for what ever reason.

Thanks for the above though!

If you viewed the XML in IE then copy and pasted the text to notepad++, that could be your problem.


RE: XBMC.MyLibrary - Scan any source to the library (Hulu/Netflix/Plugins) - denz13 - 2014-01-12

(2014-01-12, 03:51)bradvido88 Wrote:
(2014-01-12, 03:50)denz13 Wrote: I'll check that out, I've been using notepad++ to edit so I'm not sure if that's automatically inserted something for what ever reason.

Thanks for the above though!

If you viewed the XML in IE then copy and pasted the text to notepad++, that could be your problem.

That was it! Thanks man!

I'm trying to gather Vevo videos within the following subfolder: Videos/Rap/Hip-hop/Most Viewed/Most Viewed This Month

Problem is that the CMD file appears to be skipping/missing the Rap/Hip-Hop folder due to the '/' inbetween the Rap and Hip-hop. What would I need to do to get that to work?

THanks again!


RE: XBMC.MyLibrary - Scan any source to the library (Hulu/Netflix/Plugins) - bradvido88 - 2014-01-12

Don't include the slash in your search filter, instead just do RapHip-hop. Or use a regular expression such as: Videos/Rap.*Hip-hop/Most Viewed/Most Viewed This Month


RE: XBMC.MyLibrary - Scan any source to the library (Hulu/Netflix/Plugins) - tim1986 - 2014-01-14

Hello bradvido88. I really like the idea of this program, but I'm having a lot of trouble with it. I have been programming for several years, but never in java. I think I could modify some things to make this work for the Youtube addon by TheCollective, but Mainly the Project Free TV addon by Eldarado(XBMChub stuff) But I can't compile your program. I think I need a makefile and "Logger.java"

The Project Free TV addon uses additional info for the folder structure, "PFT/TV Shows/Favourites/American Pickers/Season 1 (12 Episodes, 67 Links)/1. Big Bear", and some times "PFT/TV Shows/Favourites/American Pickers/Season Special (1 Episodes, 11 Links)/Season Special Episode 1"

For the Project Free TV addon I think that in Archiver.java:
Code:
public static boolean getSeriesFromParentFolder(MyLibraryFile video)
    {
        //the series title comess before this as a folder name
        List<String> skipFolders = new ArrayList<String>();//the must match the folder name COMPLETELY. Partial matches wont be skipped
        
        final String optionalYear ="(\\([0-9]+\\)|\\[[0-9]+\\])?";//matches (nnnn) or [nnnn]
        skipFolders.add("(Full Episodes|Episodes|Clips|Seasons)");//literal skips
        skipFolders.add("((Season|Series|Set|Episodes|Collection) (\\([0-9]+\\)|[0-9]+))"+" ?"+optionalYear);//name + number + optional_space + optional_year        
        skipFolders.add("S[0-9]+E[0-9]+ - .+");//to skip "S04E01 - Orientation" in this: Netflix/Instant Queue/H/Heroes/Heroes: Season 4/S04E01 - Orientation/S04E11 - Thanksgiving
        skipFolders.add(".+: Season [0-9]+");//to skip "Heroes: Season 4" this: Netflix/Instant Queue/H/Heroes/Heroes: Season 4/S04E01 - Orientation/S04E11 - Thanksgiving
        skipFolders.add("[0-9]+");//new format used by playon specified season number as single integer folder
        skipFolders.add("(Next|Previous) (Page|Section) \\(.+\\)");//HuluBlueCop/Subscriptions/The Office (HD)/Episodes (174)/Next Page (101-174 of 174)/6x12 - Secret Santa (HD)
        String series = getParentFolderWithSkips(video.getFullPath().split(com.bradvido.xbmc.util.Constants.DELIM),skipFolders);
        if(valid(series))
        {
            video.setSeries(series);
            return true;
        }        
        return false;
    }

The regex:

Code:
skipFolders.add("((Season|Series|Set|Episodes|Collection) (\\([0-9]+\\)|[0-9]+))"+" ?"+optionalYear);//name + number + optional_space + optional_year

Could be changed to:

Code:
skipFolders.add("((Season|Series|Set|Episodes|Collection) ([a-zA-Z_\s])*(\\([0-9]+\\)|[0-9]+))"+" ?"+optionalYear+"(\\(.*\\))*");//name + optional_extra_words + number + optional_space + optional_year + optional_parenthese_section

To cover these types of Season folders, "Show/Season 1 (12 Episodes, 67 Links)/Episode"

As for the Youtube addon I don't know if a Parser->Regex is looking at the whole JSON reponse or just one Tag and which one?

The only way I can get the Youtube addon to archive anything is to force_series="[Y]" because there are no "series" names in the JSON other than what can be pulled from the "file" tag for the directory(&channel=adafruit)

Code:
                "file" : "plugin://plugin.video.youtube/?path=/root/subscriptions&user_feed=uploads&view_mode=subscriptions_favorites&login=true&channel=adafruit&page=1&",
                "filetype" : "directory",

Here's more of the JSON data, for context, with some of the sections removed to keep it short:

Code:
{
    "id" : "1",
    "jsonrpc" : "2.0",
    "result" : {
        "files" : [{
                "fanart" : "",
                "file" : "plugin://plugin.video.youtube/?path=/root/subscriptions&user_feed=uploads&view_mode=subscriptions_favorites&login=true&channel=adafruit&page=1&",
                "filetype" : "directory",
                "label" : "More results",
                "thumbnail" : "image://C%3a%5cUsers%5cTim%5cAppData%5cRoaming%5cXBMC%5caddons%5cplugin.video.youtube%5cthumbnails%5cnext.png/",
                "title" : "",
                "type" : "unknown"
            }, {
                "fanart" : "",
                "file" : "plugin://plugin.video.youtube/?path=/root/video&action=play_video&videoid=S9UJF6ui7AE",
                "filetype" : "file",
                "label" : "Motion-Activated LED Wristband",
                "runtime" : 120,
                "thumbnail" : "image://http%3a%2f%2fi.ytimg.com%2fvi%2fS9UJF6ui7AE%2f0.jpg/",
                "title" : "Motion-Activated LED Wristband",
                "type" : "unknown"
            }, {
                "fanart" : "",
                "file" : "plugin://plugin.video.youtube/?path=/root/video&action=play_video&videoid=CguREqXZA-o",
                "filetype" : "file",
                "label" : "Shine Activity Monitor Teardown",
                "runtime" : 240,
                "thumbnail" : "image://http%3a%2f%2fi.ytimg.com%2fvi%2fCguREqXZA-o%2f0.jpg/",
                "title" : "Shine Activity Monitor Teardown",
                "type" : "unknown"
            }, {
                "fanart" : "",
                "file" : "plugin://plugin.video.youtube/?path=/root/video&action=play_video&videoid=TkorLkilMKk",
                "filetype" : "file",
                "label" : "New Products 01/04/2014",
                "runtime" : 480,
                "thumbnail" : "image://http%3a%2f%2fi.ytimg.com%2fvi%2fTkorLkilMKk%2f0.jpg/",
                "title" : "New Products 01/04/2014",
                "type" : "unknown"
            }
Etc.........................
        ],
        "limits" : {
            "end" : 51,
            "start" : 0,
            "total" : 51
        }
    }
}


Please help me fix this.
Thank you!


RE: XBMC.MyLibrary - Scan any source to the library (Hulu/Netflix/Plugins) - bradvido88 - 2014-01-14

I've though for a while that the skipFolders should be pulled out into a config section of the XML, then users can customize to fit their needs. I may look at doing that.. or you could submit a patch.
For youtube, forcing the series makes sense... that's what i would do.

As far as compiling, you need all of the jars in the /res folder here, then it will work: https://code.google.com/p/xbmc-mylibrary/source/browse/#svn%2Ftrunk%2Fres


RE: XBMC.MyLibrary - Scan any source to the library (Hulu/Netflix/Plugins) - tim1986 - 2014-01-15

What is the best way to compile this? I tried "javac importer.java" but get at least 100 errors. As I said before I have done a lot of programming, but none in java.


RE: XBMC.MyLibrary - Scan any source to the library (Hulu/Netflix/Plugins) - bradvido88 - 2014-01-15

If you've not done java before, i'd recommend importing the project into an IDE such as Netbeans or Eclipse.


RE: XBMC.MyLibrary - Scan any source to the library (Hulu/Netflix/Plugins) - pcgirl - 2014-01-15

I know this is a dumb question but I am trying to setup a Task scheduler to run the cmd file every 2 hours. It doesn't seem to want to do that though. I seem to have all the settings right but it doesn't run. It only runs when I click on the cmd file manually. I tried to use batch2exe to convert the cmd file to and exe but it doesn't see the cmd file. Can anybody help me with this? Also, is there anywhere that there are some config.xml files to look at for various plugins?