Add network module
This commit is contained in:
@@ -1,15 +0,0 @@
|
||||
# local imports
|
||||
from cic.attachment import Attachment
|
||||
|
||||
def process_args(argparser):
|
||||
argparser.add_argument('-f', '--file', type=str, help='add file')
|
||||
argparser.add_argument('-d', '--directory', type=str, dest='directory', default='.', help='directory')
|
||||
|
||||
|
||||
def validate_args(args):
|
||||
pass
|
||||
|
||||
|
||||
def execute(config, eargs):
|
||||
ca = Attachment(eargs.directory)
|
||||
ca.load()
|
||||
@@ -6,6 +6,7 @@ import os
|
||||
from cic import Proof
|
||||
from cic.meta import Meta
|
||||
from cic.attachment import Attachment
|
||||
from cic.network import Network
|
||||
|
||||
logg = logging.getLogger(__name__)
|
||||
|
||||
@@ -24,7 +25,9 @@ def execute(config, eargs):
|
||||
cp = Proof(eargs.directory)
|
||||
cm = Meta(eargs.directory)
|
||||
ca = Attachment(eargs.directory)
|
||||
cn = Network(eargs.directory)
|
||||
|
||||
cp.start()
|
||||
cm.start()
|
||||
ca.start()
|
||||
cn.start()
|
||||
|
||||
32
cic/cmd/show.py
Normal file
32
cic/cmd/show.py
Normal file
@@ -0,0 +1,32 @@
|
||||
# local imports
|
||||
from cic import Proof
|
||||
from cic.meta import Meta
|
||||
from cic.attachment import Attachment
|
||||
from cic.network import Network
|
||||
|
||||
|
||||
def process_args(argparser):
|
||||
argparser.add_argument('-f', '--file', type=str, help='add file')
|
||||
argparser.add_argument('-d', '--directory', type=str, dest='directory', default='.', help='directory')
|
||||
|
||||
|
||||
def validate_args(args):
|
||||
pass
|
||||
|
||||
|
||||
def execute(config, eargs):
|
||||
cp = Proof(path=eargs.directory)
|
||||
cm = Meta(path=eargs.directory)
|
||||
ca = Attachment(path=eargs.directory)
|
||||
cn = Network(eargs.directory)
|
||||
|
||||
cp.load()
|
||||
cm.load()
|
||||
ca.load()
|
||||
cn.load()
|
||||
|
||||
print("Version: {}\n".format(cp.version()))
|
||||
print("Proof:\n{}".format(cp))
|
||||
print("Meta:\n{}".format(cm))
|
||||
print("Attachments:\n{}".format(ca))
|
||||
print("Network:\n{}".format(cn))
|
||||
Reference in New Issue
Block a user