Skip to content

Commit a82d691

Browse files
committed
ENH: auto-update on import
1 parent c1ee264 commit a82d691

1 file changed

Lines changed: 14 additions & 1 deletion

File tree

templateflow/__init__.py

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,21 @@
1414
del get_distribution
1515
del DistributionNotFound
1616

17+
import os
1718
from . import api
18-
from .conf import update
19+
from .conf import update, setup_home
20+
21+
22+
if os.getenv("TEMPLATEFLOW_AUTOUPDATE", "1") not in (
23+
"false",
24+
"off",
25+
"0",
26+
"no",
27+
"n",
28+
):
29+
# trigger skeleton autoupdate
30+
update(local=True, overwrite=False)
31+
1932

2033
__all__ = [
2134
'__copyright__',

0 commit comments

Comments
 (0)