Add a check command.
This commit is contained in:
parent
833a0c681c
commit
44285fbf59
2 changed files with 11 additions and 0 deletions
10
dcc/check.py
Normal file
10
dcc/check.py
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
import dcc.config
|
||||||
|
import dcc.doom_base
|
||||||
|
import wand.display
|
||||||
|
import wand.image
|
||||||
|
|
||||||
|
class Check(dcc.doom_base.WadMap):
|
||||||
|
def take_action(self, parsed_args):
|
||||||
|
with wand.image.Image(filename=dcc.config.BaseThumbPath(parsed_args.wad, parsed_args.map)) as img:
|
||||||
|
print("Image is {}x{}.".format(img.width, img.height))
|
||||||
|
wand.display.display(img)
|
1
setup.py
1
setup.py
|
@ -27,6 +27,7 @@ setup(
|
||||||
'put = dcc.put:Put',
|
'put = dcc.put:Put',
|
||||||
'pb = dcc.pb:PB',
|
'pb = dcc.pb:PB',
|
||||||
'ss = dcc.ss:SS',
|
'ss = dcc.ss:SS',
|
||||||
|
'check = dcc.check:Check',
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
zip_safe=False,
|
zip_safe=False,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue