File tree Expand file tree Collapse file tree 3 files changed +21
-7
lines changed Expand file tree Collapse file tree 3 files changed +21
-7
lines changed Original file line number Diff line number Diff line change 12
12
13
13
setup (
14
14
name = 'zxtools' ,
15
- version = '0.0.1 ' ,
16
- description = 'TR-DOS files utils ' ,
15
+ version = '0.0.2 ' ,
16
+ description = 'Tools to manipulate files from Z80 Spectrum diskettes ' ,
17
17
long_description = readme ,
18
18
author = 'Kirill V. Lyadvinsky' ,
19
19
20
- url = 'https://github.com/codeatcpp/zxtools' ,
20
+ download_url = 'https://github.com/codeatcpp/zxtools' ,
21
+ url = 'http://www.codeatcpp.com' ,
21
22
license = flicense ,
22
23
packages = find_packages (exclude = ('test' , 'docs' )),
23
- test_suite = "test"
24
+ test_suite = "test" ,
25
+ classifiers = [
26
+ 'Development Status :: 2 - Pre-Alpha' ,
27
+ 'Environment :: Console' ,
28
+ 'Intended Audience :: Developers' ,
29
+ 'Programming Language :: Python :: 3 :: Only' ,
30
+ 'Topic :: Software Development' ,
31
+ 'Topic :: Utilities'
32
+ ]
24
33
)
25
34
Original file line number Diff line number Diff line change @@ -129,6 +129,10 @@ def test_strip_header3(self):
129
129
temp_output_file .close ()
130
130
os .remove (temp_output_path )
131
131
132
+ def test_args_parser (self ):
133
+ parser = hobeta .parse_args (['hobeta-help' ])
134
+ self .assertTrue (parser .func )
135
+
132
136
133
137
if __name__ == '__main__' :
134
138
unittest .main ()
Original file line number Diff line number Diff line change 3
3
""" Hobeta file utils """
4
4
5
5
import os
6
+ import sys
6
7
import logging
7
8
import struct
8
9
from collections import namedtuple
@@ -109,7 +110,7 @@ def strip_header(parsed_args):
109
110
return bytes_to_copy - length
110
111
111
112
112
- def parse_args ():
113
+ def parse_args (args ):
113
114
""" Parse command line arguments """
114
115
parser = argparse .ArgumentParser (description = "Hobeta files converter" )
115
116
parser .add_argument (
@@ -143,12 +144,12 @@ def parse_args():
143
144
help = "Show Hobeta header format description" )
144
145
help_parser .set_defaults (func = hobeta_help )
145
146
146
- return parser .parse_args ()
147
+ return parser .parse_args (args )
147
148
148
149
149
150
def main ():
150
151
""" Entry point """
151
- args = parse_args ()
152
+ args = parse_args (sys . argv [ 1 :] )
152
153
if args .verbose :
153
154
logging .basicConfig (level = logging .DEBUG )
154
155
You can’t perform that action at this time.
0 commit comments