add arguments to take a version
This commit is contained in:
parent
58a7e70860
commit
51c9bb05c6
Binary file not shown.
@ -1,6 +1,4 @@
|
||||
from zipfile import ZipFile
|
||||
# from bs4 import BeautifulSoup
|
||||
# from lxml import etree
|
||||
|
||||
|
||||
def reader(path_to_file):
|
||||
|
11
src/main.py
11
src/main.py
@ -1,4 +1,11 @@
|
||||
from fb3_reader import fb3
|
||||
from sys import argv
|
||||
from fb3_reader import fb3, __version__
|
||||
|
||||
if __name__ == '__main__':
|
||||
fb3.reader(input("Enter path to file: "))
|
||||
try:
|
||||
if argv[1] == "--version" or argv[1] == "-v":
|
||||
print(__version__)
|
||||
else:
|
||||
fb3.reader(input("Enter path to file: "))
|
||||
except IndexError:
|
||||
fb3.reader(input("Enter path to file: "))
|
||||
|
Loading…
Reference in New Issue
Block a user