Compare commits
No commits in common. "b0ef8c3fc0b84670b0ab3d5ed8e80fe063b231ad" and "59519eae3be2d1a3dcbb6304d32bf474d6479be1" have entirely different histories.
b0ef8c3fc0
...
59519eae3b
2 changed files with 3 additions and 3 deletions
|
|
@ -1,5 +1,6 @@
|
||||||
from configparser import ConfigParser
|
from configparser import ConfigParser
|
||||||
import sqlite3
|
import sqlite3
|
||||||
|
import datalad.api as dl
|
||||||
import os
|
import os
|
||||||
from .tracker import save, init
|
from .tracker import save, init
|
||||||
|
|
||||||
|
|
@ -62,7 +63,7 @@ def create(path: str) -> None:
|
||||||
Create folder of backlogs.
|
Create folder of backlogs.
|
||||||
|
|
||||||
"""
|
"""
|
||||||
init(path)
|
create(path)
|
||||||
_create_db(os.path.join(path, 'backlogger.db'))
|
_create_db(os.path.join(path, 'backlogger.db'))
|
||||||
os.chmod(os.path.join(path, 'backlogger.db'), 0o666) # why does this not work?
|
os.chmod(os.path.join(path, 'backlogger.db'), 0o666) # why does this not work?
|
||||||
_create_config(path)
|
_create_config(path)
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,6 @@
|
||||||
import os
|
import os
|
||||||
from configparser import ConfigParser
|
from configparser import ConfigParser
|
||||||
from .trackers import datalad as dl
|
from .trackers import datalad as dl
|
||||||
from typing import Optional
|
|
||||||
|
|
||||||
|
|
||||||
def get_tracker(path: str) -> str:
|
def get_tracker(path: str) -> str:
|
||||||
|
|
@ -22,7 +21,7 @@ def get(path: str, file: str) -> None:
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|
||||||
def save(path: str, message: str, files: Optional[list[str]]=None) -> None:
|
def save(path: str, message: str, files: list[str]) -> None:
|
||||||
tracker = get_tracker(path)
|
tracker = get_tracker(path)
|
||||||
if tracker == 'datalad':
|
if tracker == 'datalad':
|
||||||
dl.save(path, message, files)
|
dl.save(path, message, files)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue