mirror of
https://github.com/josegonzalez/python-github-backup.git
synced 2025-12-05 16:18:02 +01:00
Compare commits
6 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
63441ebfbc | ||
|
|
7ad324225e | ||
|
|
885e94a102 | ||
|
|
9e1800f56e | ||
|
|
d057ee0d04 | ||
|
|
64562f2460 |
@@ -1 +1 @@
|
|||||||
__version__ = '0.40.1'
|
__version__ = '0.41.0'
|
||||||
|
|||||||
@@ -11,7 +11,6 @@ import datetime
|
|||||||
import errno
|
import errno
|
||||||
import getpass
|
import getpass
|
||||||
import json
|
import json
|
||||||
import logging
|
|
||||||
import os
|
import os
|
||||||
import re
|
import re
|
||||||
import select
|
import select
|
||||||
@@ -42,6 +41,7 @@ FNULL = open(os.devnull, 'w')
|
|||||||
def _get_log_date():
|
def _get_log_date():
|
||||||
return datetime.datetime.isoformat(datetime.datetime.now())
|
return datetime.datetime.isoformat(datetime.datetime.now())
|
||||||
|
|
||||||
|
|
||||||
def log_info(message):
|
def log_info(message):
|
||||||
"""
|
"""
|
||||||
Log message (str) or messages (List[str]) to stdout
|
Log message (str) or messages (List[str]) to stdout
|
||||||
@@ -1106,10 +1106,11 @@ def fetch_repository(name,
|
|||||||
masked_remote_url,
|
masked_remote_url,
|
||||||
local_dir))
|
local_dir))
|
||||||
if bare_clone:
|
if bare_clone:
|
||||||
if lfs_clone:
|
|
||||||
git_command = ['git', 'lfs', 'clone', '--mirror', remote_url, local_dir]
|
|
||||||
else:
|
|
||||||
git_command = ['git', 'clone', '--mirror', remote_url, local_dir]
|
git_command = ['git', 'clone', '--mirror', remote_url, local_dir]
|
||||||
|
logging_subprocess(git_command, None)
|
||||||
|
if lfs_clone:
|
||||||
|
git_command = ['git', 'lfs', 'fetch', '--all', '--prune']
|
||||||
|
logging_subprocess(git_command, None, cwd=local_dir)
|
||||||
else:
|
else:
|
||||||
if lfs_clone:
|
if lfs_clone:
|
||||||
git_command = ['git', 'lfs', 'clone', remote_url, local_dir]
|
git_command = ['git', 'lfs', 'clone', remote_url, local_dir]
|
||||||
|
|||||||
Reference in New Issue
Block a user