Removes apps folder

This commit is contained in:
Sergi Delgado Segura
2020-03-18 12:09:58 +01:00
parent 3e1700f3de
commit 5e5ff0278a
19 changed files with 19 additions and 11 deletions

2
.gitignore vendored
View File

@@ -7,7 +7,7 @@ conf.py
bitcoin.conf*
*__pycache__
.pending*
apps/cli/*.json
cli/*.json
appointments/
test.py
*.pyc

View File

@@ -1,5 +1,5 @@
import os
import apps.cli.conf as conf
import cli.conf as conf
from common.tools import extend_paths, check_conf_fields, setup_logging, setup_data_folder
LOG_PREFIX = "cli"

View File

@@ -10,8 +10,8 @@ from coincurve import PublicKey
from getopt import getopt, GetoptError
from requests import ConnectTimeout, ConnectionError
from apps.cli import config, LOG_PREFIX
from apps.cli.help import help_add_appointment, help_get_appointment
from cli import config, LOG_PREFIX
from cli.help import help_add_appointment, help_get_appointment
from common.blob import Blob
import common.cryptographer

View File

@@ -7,8 +7,16 @@ from cryptography.hazmat.primitives import serialization
from cryptography.hazmat.primitives.asymmetric import ec
# Simple tool to generate an ECDSA private key using the secp256k1 curve and save private and public keys
# as 'teos_sk.der' 'and teos_pk.der', respectively.
"""
Simple too to generate an ECDSA key pair using the secp256k1 curve and store it on disk.
Default output dir = .
Default key naming = teos_sk.der and teos_pk.der
The output dir and naming can be changed using the -n and -d command line options, respectively.
DISCLAIMER: Use this for testing only, using keys generated from this file in production is highly unadvised.
"""
def save_sk(sk, filename):
@@ -30,7 +38,7 @@ def save_pk(pk, filename):
if __name__ == "__main__":
name = "teos"
output_dir = "."
output_dir = "apps"
opts, _ = getopt(argv[1:], "n:d:", ["name", "dir"])
for opt, arg in opts:

View File

@@ -11,8 +11,8 @@ from common.appointment import Appointment
from common.cryptographer import Cryptographer
from common.blob import Blob
import apps.cli.teos_cli as teos_cli
from test.apps.cli.unit.conftest import get_random_value_hex
import cli.teos_cli as teos_cli
from test.cli.unit.conftest import get_random_value_hex
common.cryptographer.logger = Logger(actor="Cryptographer", log_name_prefix=teos_cli.LOG_PREFIX)

View File

@@ -5,7 +5,7 @@ from riemann.tx import Tx
from teos import HOST, PORT
from apps.cli import teos_cli
from cli import teos_cli
from common.blob import Blob
import common.cryptographer
@@ -21,7 +21,7 @@ from test.teos.e2e.conftest import (
create_penalty_tx,
run_teosd,
)
from apps.cli import config as cli_conf
from cli import config as cli_conf
common.cryptographer.logger = Logger(actor="Cryptographer", log_name_prefix="")