@@ -1708,16 +1708,17 @@ def add_to_datalad(topdir, studydir, msg=None, bids=False):
1708
1708
shared_access = 'all' )
1709
1709
# Since .heudiconv could contain sensitive information
1710
1710
# we place all files under annex and then add
1711
- create_file_if_missing (
1711
+ if create_file_if_missing (
1712
1712
opj (dsh .path , '.gitattributes' ),
1713
1713
"""* annex.largefiles=anything
1714
- """ )
1715
- dsh .add ('.gitattributes' , message = "Added gitattributes to place all content under annex" )
1714
+ """ ):
1715
+ dsh .add ('.gitattributes' , message = "Added gitattributes to place all content under annex" )
1716
1716
ds .add ('.' , recursive = True , save = False ,
1717
1717
# not in effect! ?
1718
1718
#annex_add_opts=['--include-dotfiles']
1719
1719
)
1720
1720
1721
+ # TODO: filter for only changed files?
1721
1722
# Provide metadata for sensitive information
1722
1723
mark_sensitive (ds , 'sourcedata' )
1723
1724
mark_sensitive (ds , '*_scans.tsv' ) # top level
@@ -1738,7 +1739,6 @@ def add_to_datalad(topdir, studydir, msg=None, bids=False):
1738
1739
- unlock (thin will be in effect)
1739
1740
- save/commit (does modechange 120000 => 100644
1740
1741
1741
- - we should mark dicoms and anatomicals as distribution-restricted
1742
1742
- could potentially somehow automate that all:
1743
1743
http://git-annex.branchable.com/tips/automatically_adding_metadata/
1744
1744
- possibly even make separate sub-datasets for originaldata, derivatives ?
0 commit comments