txt2ebook 0.1.125__py3-none-any.whl → 0.1.126__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
txt2ebook/__init__.py CHANGED
@@ -24,7 +24,7 @@ import langdetect
24
24
 
25
25
  logger = logging.getLogger(__name__)
26
26
 
27
- __version__ = "0.1.125"
27
+ __version__ = "0.1.126"
28
28
 
29
29
 
30
30
  def setup_logger(config: argparse.Namespace) -> None:
@@ -51,29 +51,6 @@ PAGE_SIZES = [
51
51
  "letter",
52
52
  ]
53
53
 
54
-
55
- def create_format(
56
- book: txt2ebook.models.book.Book,
57
- ebook_format: str,
58
- config: argparse.Namespace,
59
- ) -> Union[TxtWriter, EpubWriter]:
60
- """Create ebook formatter by format using factory function.
61
-
62
- Args:
63
- book(txt2ebook.models.book.Book): The book model which contains
64
- metadata and table of contents of volumes and chapters.
65
- ebook_format(str): The ebook format.
66
- config(argparse.Namespace): The configs from the command-line.
67
-
68
- Returns:
69
- TxtWriter | EpubWriter
70
- """
71
- class_name = to_classname(ebook_format, "Writer")
72
- klass = load_class("txt2ebook.formats", class_name)
73
- formatter = klass(book, config)
74
- return formatter
75
-
76
-
77
54
  __all__ = [
78
55
  "Book",
79
56
  "EBOOK_FORMATS",
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: txt2ebook
3
- Version: 0.1.125
3
+ Version: 0.1.126
4
4
  Summary: CLI tool to convert txt file to ebook format
5
5
  Home-page: https://github.com/kianmeng/txt2ebook
6
6
  License: AGPL-3.0-or-later
@@ -1,8 +1,8 @@
1
- txt2ebook/__init__.py,sha256=G_p-8TBwpVBfi-gEVDNwuhkFMbIM9p1g5bTUr8DXTvQ,2706
1
+ txt2ebook/__init__.py,sha256=pYny7KkuC0o1Sgd_O1DW8qkfwhaa9H9zEOvYBVE00wI,2706
2
2
  txt2ebook/__main__.py,sha256=L29rlfPSx9XMnVaHBYP2dyYgDmutJvONR3yUejjYwRY,855
3
3
  txt2ebook/cli.py,sha256=D0jseJLlFDjLfX-yiGCC0e98a5IJ1IbRFx_mVGyYIxc,4241
4
4
  txt2ebook/exceptions.py,sha256=oVtVMCqrxWq-CZ5GQYOBioil9i2kJ2mqD08IQ9A636Q,847
5
- txt2ebook/formats/__init__.py,sha256=uNbNvSrXyfil7uIeFgYjttYB_1GkwTSPYfiDew9V4bs,2468
5
+ txt2ebook/formats/__init__.py,sha256=lHgmNN84LrC9yswTeUMQ9oqJ9kQ48iKo8xTe7LUddaI,1771
6
6
  txt2ebook/formats/base.py,sha256=ODguJ7OBPXfRQLLeoL-G66NZihroXb4kG5-56ZrlygI,5819
7
7
  txt2ebook/formats/epub.py,sha256=IVz-FmYQlcChOw38YqfKy46bPVSIrHyxA_94iz06N3Y,6941
8
8
  txt2ebook/formats/gmi.py,sha256=qwNCcHh2LN4pEn0rDLpQFhLOPjLBgMU-E_dxWxewWbw,6788
@@ -45,8 +45,8 @@ txt2ebook/subcommands/tex.py,sha256=X6ZBfuAs_mcJe8PNjzoW339ecPynZduVbcCq0henjiA,
45
45
  txt2ebook/subcommands/typ.py,sha256=r4Xf7xSINbYfaIKkVzdyQDlUMWPvOIcbvOwC71spu6w,3682
46
46
  txt2ebook/tokenizer.py,sha256=H9AaZVmNP43L3ONvj58u_5weZAjFG9SzQSeS9upGN1U,9642
47
47
  txt2ebook/zh_utils.py,sha256=0Yq9r-JL4HntW68vFR6TBP9yQim1a07mfsh_sp-XmaE,4887
48
- txt2ebook-0.1.125.dist-info/LICENSE.md,sha256=tGtFDwxWTjuR9syrJoSv1Hiffd2u8Tu8cYClfrXS_YU,31956
49
- txt2ebook-0.1.125.dist-info/METADATA,sha256=E8RlY3BV0QFaeYdHbBOlbjA9ebxT_w3RlhIc8KIFgtI,4969
50
- txt2ebook-0.1.125.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
51
- txt2ebook-0.1.125.dist-info/entry_points.txt,sha256=q4krNWsYNu4Rcf72nFc66JeR0J9BiFA6-NVEJKBZ_F4,71
52
- txt2ebook-0.1.125.dist-info/RECORD,,
48
+ txt2ebook-0.1.126.dist-info/LICENSE.md,sha256=tGtFDwxWTjuR9syrJoSv1Hiffd2u8Tu8cYClfrXS_YU,31956
49
+ txt2ebook-0.1.126.dist-info/METADATA,sha256=z8f4sSXjzliRVXlL_BXDnkmGEYO6Or4qiTEZC5Rwo4Y,4969
50
+ txt2ebook-0.1.126.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
51
+ txt2ebook-0.1.126.dist-info/entry_points.txt,sha256=q4krNWsYNu4Rcf72nFc66JeR0J9BiFA6-NVEJKBZ_F4,71
52
+ txt2ebook-0.1.126.dist-info/RECORD,,