added config class to validate config entries
This commit is contained in:
@@ -1,12 +1,22 @@
|
||||
# functions for commands needed
|
||||
# src/commands.py
|
||||
import os
|
||||
from ctf.utils import state
|
||||
from pathlib import path
|
||||
|
||||
def test():
|
||||
print("hello from test")
|
||||
def Set_Challenge(comp: str, chal: str, setDirectory: bool):
|
||||
# set the current challenge and competition from input
|
||||
if state.current_comp != comp:
|
||||
state.current_comp=comp
|
||||
state.comp_dir=pathlib
|
||||
# TODO archive the old competitions
|
||||
|
||||
if state.current_chal != chal:
|
||||
state.current_chal=chal
|
||||
print("challenge already set")
|
||||
# TODO archive the old challenges
|
||||
# TODO set the directory to challenge directory, with ignore option
|
||||
|
||||
# Read variables
|
||||
|
||||
# Initialize a challenge
|
||||
## Copy files into directory
|
||||
## add section to log
|
||||
|
||||
Reference in New Issue
Block a user