mirror of
https://github.com/JimmXinu/FanFicFare.git
synced 2026-05-09 05:21:13 +02:00
New Site: scifistories.com (extends finestories.com).
This commit is contained in:
parent
020cef0b99
commit
e9f82c3343
4 changed files with 204 additions and 20 deletions
|
|
@ -1606,6 +1606,16 @@ extracategories:Harry Potter
|
|||
|
||||
website_encodings:Windows-1252,utf8
|
||||
|
||||
[fanfic.tenhawkpresents.ink]
|
||||
## Some sites require login (or login for some rated stories) The
|
||||
## program can prompt you, or you can save it in config. In
|
||||
## commandline version, this should go in your personal.ini, not
|
||||
## defaults.ini.
|
||||
#username:YourName
|
||||
#password:yourpassword
|
||||
|
||||
website_encodings:Windows-1252,utf8
|
||||
|
||||
[fanficauthors.net]
|
||||
## Some sites require login (or login for some rated stories) The
|
||||
## program can prompt you, or you can save it in config. In
|
||||
|
|
@ -1644,16 +1654,6 @@ include_in_category:fandoms
|
|||
[fanfiction-junkies.de]
|
||||
website_encodings:Windows-1252,utf8
|
||||
|
||||
[fanfic.tenhawkpresents.ink]
|
||||
## Some sites require login (or login for some rated stories) The
|
||||
## program can prompt you, or you can save it in config. In
|
||||
## commandline version, this should go in your personal.ini, not
|
||||
## defaults.ini.
|
||||
#username:YourName
|
||||
#password:yourpassword
|
||||
|
||||
website_encodings:Windows-1252,utf8
|
||||
|
||||
[fictionhunt.com]
|
||||
## Some sites require login (or login for some rated stories) The
|
||||
## program can prompt you, or you can save it in config. In
|
||||
|
|
@ -2101,6 +2101,77 @@ extraships:Sam/Jack
|
|||
|
||||
website_encodings:Windows-1252,utf8
|
||||
|
||||
[scifistories.com:epub]
|
||||
## This is a workaround to replace truncated chapter titles present in
|
||||
## chapter list. Uncomment this to remove the usual, shorter chapter
|
||||
## title in the chapter files only. See inject_chapter_title below.
|
||||
#chapter_start:<?xml version="1.0" encoding="UTF-8"?>
|
||||
# <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
|
||||
# <html xmlns="http://www.w3.org/1999/xhtml">
|
||||
# <head>
|
||||
# <title>${chapter}</title>
|
||||
# <link href="stylesheet.css" type="text/css" charset="UTF-8" rel="stylesheet"/>
|
||||
# <meta name="chapterurl" content="${url}"></meta>
|
||||
# <meta name="chapterorigtitle" content="${origchapter}"></meta>
|
||||
# <meta name="chaptertoctitle" content="${tocchapter}"></meta>
|
||||
# <meta name="chaptertitle" content="${chapter}"></meta>
|
||||
# </head>
|
||||
# <body>
|
||||
|
||||
[scifistories.com]
|
||||
## Some sites require login (or login for some rated stories) The
|
||||
## program can prompt you, or you can save it in config. In
|
||||
## commandline version, this should go in your personal.ini, not
|
||||
## defaults.ini.
|
||||
## scifistories.com has started requiring login by email rather than
|
||||
## pen name.
|
||||
#username:youremail@yourdomain.dom
|
||||
#password:yourpassword
|
||||
|
||||
## dateUpdated/datePublished don't usually have time, but they do on this site.
|
||||
## http://docs.python.org/library/datetime.html#strftime-strptime-behavior
|
||||
## Note that ini format requires % to be escaped as %%.
|
||||
dateUpdated_format:%%Y-%%m-%%d %%H:%%M:%%S
|
||||
datePublished_format:%%Y-%%m-%%d %%H:%%M:%%S
|
||||
|
||||
## Clear FanFiction from defaults, site is original fiction.
|
||||
extratags:
|
||||
|
||||
extra_valid_entries:size,universe,universeUrl,universeHTML,sitetags,notice,codes,score
|
||||
#extra_titlepage_entries:size,universeHTML,sitetags,notice,score
|
||||
include_in_codes:sitetags
|
||||
|
||||
## adds to include_subject_tags instead of replacing it.
|
||||
#extra_subject_tags:sitetags
|
||||
|
||||
size_label:Size
|
||||
universe_label:Universe
|
||||
universeUrl_label:Universe URL
|
||||
universeHTML_label:Universe
|
||||
sitetags_label:Site Tags
|
||||
notice_label:Notice
|
||||
score_label:Score
|
||||
|
||||
## Assume entryUrl, apply to "<a class='%slink' href='%s'>%s</a>" to
|
||||
## make entryHTML.
|
||||
make_linkhtml_entries:universe
|
||||
|
||||
## scifistories.com stories can be in a series and/or a universe. By
|
||||
## default, series will be populated with the universe if there is
|
||||
## universe but not series.
|
||||
universe_as_series: true
|
||||
|
||||
## some sites include images that we don't ever want becoming the
|
||||
## cover image. This lets you exclude them.
|
||||
cover_exclusion_regexp:/css/bir.png
|
||||
|
||||
## This site uses shortened title chapters in chapter lists. When set
|
||||
## true, this will inject the site's full length chapter title into
|
||||
## the chapter text. Typically will be used with chapter_start to
|
||||
## remove the standard chapter title, as shown above in
|
||||
## [scifistories.com:epub].
|
||||
#inject_chapter_title:false
|
||||
|
||||
[sheppardweir.com]
|
||||
## Some sites require login (or login for some rated stories) The
|
||||
## program can prompt you, or you can save it in config. In
|
||||
|
|
|
|||
|
|
@ -167,6 +167,7 @@ from . import adapter_mugglenetfanfictioncom
|
|||
from . import adapter_swiorgru
|
||||
from . import adapter_fanficsme
|
||||
from . import adapter_archivehpfanfictalkcom
|
||||
from . import adapter_scifistoriescom
|
||||
|
||||
## This bit of complexity allows adapters to be added by just adding
|
||||
## importing. It eliminates the long if/else clauses we used to need
|
||||
|
|
|
|||
41
fanficfare/adapters/adapter_scifistoriescom.py
Normal file
41
fanficfare/adapters/adapter_scifistoriescom.py
Normal file
|
|
@ -0,0 +1,41 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
|
||||
# Copyright 2013 Fanficdownloader team, 2020 FanFicFare team
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
|
||||
from __future__ import absolute_import
|
||||
import logging
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
# py2 vs py3 transition
|
||||
from ..six import text_type as unicode
|
||||
|
||||
from .adapter_finestoriescom import FineStoriesComAdapter
|
||||
|
||||
def getClass():
|
||||
return SciFiStoriesComAdapter
|
||||
|
||||
# Class name has to be unique. Our convention is camel case the
|
||||
# sitename with Adapter at the end. www is skipped.
|
||||
class SciFiStoriesComAdapter(FineStoriesComAdapter):
|
||||
|
||||
@classmethod
|
||||
def getSiteAbbrev(cls):
|
||||
return 'sfst'
|
||||
|
||||
@staticmethod # must be @staticmethod, don't remove it.
|
||||
def getSiteDomain():
|
||||
# The site domain. Does have www here, if it uses it.
|
||||
return 'scifistories.com'
|
||||
|
|
@ -1639,6 +1639,16 @@ extracategories:Harry Potter
|
|||
|
||||
website_encodings:Windows-1252,utf8
|
||||
|
||||
[fanfic.tenhawkpresents.ink]
|
||||
## Some sites require login (or login for some rated stories) The
|
||||
## program can prompt you, or you can save it in config. In
|
||||
## commandline version, this should go in your personal.ini, not
|
||||
## defaults.ini.
|
||||
#username:YourName
|
||||
#password:yourpassword
|
||||
|
||||
website_encodings:Windows-1252,utf8
|
||||
|
||||
[fanficauthors.net]
|
||||
## Some sites require login (or login for some rated stories) The
|
||||
## program can prompt you, or you can save it in config. In
|
||||
|
|
@ -1677,16 +1687,6 @@ include_in_category:fandoms
|
|||
[fanfiction-junkies.de]
|
||||
website_encodings:Windows-1252,utf8
|
||||
|
||||
[fanfic.tenhawkpresents.ink]
|
||||
## Some sites require login (or login for some rated stories) The
|
||||
## program can prompt you, or you can save it in config. In
|
||||
## commandline version, this should go in your personal.ini, not
|
||||
## defaults.ini.
|
||||
#username:YourName
|
||||
#password:yourpassword
|
||||
|
||||
website_encodings:Windows-1252,utf8
|
||||
|
||||
[fictionhunt.com]
|
||||
## Some sites require login (or login for some rated stories) The
|
||||
## program can prompt you, or you can save it in config. In
|
||||
|
|
@ -2134,6 +2134,77 @@ extraships:Sam/Jack
|
|||
|
||||
website_encodings:Windows-1252,utf8
|
||||
|
||||
[scifistories.com:epub]
|
||||
## This is a workaround to replace truncated chapter titles present in
|
||||
## chapter list. Uncomment this to remove the usual, shorter chapter
|
||||
## title in the chapter files only. See inject_chapter_title below.
|
||||
#chapter_start:<?xml version="1.0" encoding="UTF-8"?>
|
||||
# <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
|
||||
# <html xmlns="http://www.w3.org/1999/xhtml">
|
||||
# <head>
|
||||
# <title>${chapter}</title>
|
||||
# <link href="stylesheet.css" type="text/css" charset="UTF-8" rel="stylesheet"/>
|
||||
# <meta name="chapterurl" content="${url}"></meta>
|
||||
# <meta name="chapterorigtitle" content="${origchapter}"></meta>
|
||||
# <meta name="chaptertoctitle" content="${tocchapter}"></meta>
|
||||
# <meta name="chaptertitle" content="${chapter}"></meta>
|
||||
# </head>
|
||||
# <body>
|
||||
|
||||
[scifistories.com]
|
||||
## Some sites require login (or login for some rated stories) The
|
||||
## program can prompt you, or you can save it in config. In
|
||||
## commandline version, this should go in your personal.ini, not
|
||||
## defaults.ini.
|
||||
## scifistories.com has started requiring login by email rather than
|
||||
## pen name.
|
||||
#username:youremail@yourdomain.dom
|
||||
#password:yourpassword
|
||||
|
||||
## dateUpdated/datePublished don't usually have time, but they do on this site.
|
||||
## http://docs.python.org/library/datetime.html#strftime-strptime-behavior
|
||||
## Note that ini format requires % to be escaped as %%.
|
||||
dateUpdated_format:%%Y-%%m-%%d %%H:%%M:%%S
|
||||
datePublished_format:%%Y-%%m-%%d %%H:%%M:%%S
|
||||
|
||||
## Clear FanFiction from defaults, site is original fiction.
|
||||
extratags:
|
||||
|
||||
extra_valid_entries:size,universe,universeUrl,universeHTML,sitetags,notice,codes,score
|
||||
#extra_titlepage_entries:size,universeHTML,sitetags,notice,score
|
||||
include_in_codes:sitetags
|
||||
|
||||
## adds to include_subject_tags instead of replacing it.
|
||||
#extra_subject_tags:sitetags
|
||||
|
||||
size_label:Size
|
||||
universe_label:Universe
|
||||
universeUrl_label:Universe URL
|
||||
universeHTML_label:Universe
|
||||
sitetags_label:Site Tags
|
||||
notice_label:Notice
|
||||
score_label:Score
|
||||
|
||||
## Assume entryUrl, apply to "<a class='%slink' href='%s'>%s</a>" to
|
||||
## make entryHTML.
|
||||
make_linkhtml_entries:universe
|
||||
|
||||
## scifistories.com stories can be in a series and/or a universe. By
|
||||
## default, series will be populated with the universe if there is
|
||||
## universe but not series.
|
||||
universe_as_series: true
|
||||
|
||||
## some sites include images that we don't ever want becoming the
|
||||
## cover image. This lets you exclude them.
|
||||
cover_exclusion_regexp:/css/bir.png
|
||||
|
||||
## This site uses shortened title chapters in chapter lists. When set
|
||||
## true, this will inject the site's full length chapter title into
|
||||
## the chapter text. Typically will be used with chapter_start to
|
||||
## remove the standard chapter title, as shown above in
|
||||
## [scifistories.com:epub].
|
||||
#inject_chapter_title:false
|
||||
|
||||
[sheppardweir.com]
|
||||
## Some sites require login (or login for some rated stories) The
|
||||
## program can prompt you, or you can save it in config. In
|
||||
|
|
|
|||
Loading…
Reference in a new issue