Lazy commit on fry.
This commit is contained in:
parent
7b2ec93611
commit
5a95555672
@ -119,6 +119,7 @@ def isFossil(cfg):
|
||||
|
||||
def perform_action(action, key, item, silent = False):
|
||||
output = None
|
||||
hn = hostname()
|
||||
lbl = "{0}ing".format(action).title()
|
||||
if os.path.exists(os.path.expanduser(item["path"])):
|
||||
if action in list([ "pull", "push", "fetch" ]):
|
||||
@ -157,7 +158,7 @@ def perform_action(action, key, item, silent = False):
|
||||
cwd = Path(os.path.expanduser(item["path"]))
|
||||
cmd = f"fossil add ."
|
||||
output = execute_command(cmd, cwd=cwd)
|
||||
cmd = f"fossil commit -m \"Lazy commit on {hostname}\""
|
||||
cmd = f"fossil commit -m \"Lazy commit on {hn}\""
|
||||
output = execute_command(cmd, cwd=cwd)
|
||||
else:
|
||||
cmd = "git -C \"{0}\" status --porcelain".format(os.path.expanduser(item["path"]))
|
||||
@ -166,7 +167,7 @@ def perform_action(action, key, item, silent = False):
|
||||
print("Lazy committing {0}...".format(key))
|
||||
cmd = "git -C \"{0}\" add .".format(os.path.expanduser(item["path"]))
|
||||
output = execute_command(cmd)
|
||||
cmd = "git -C \"{0}\" commit -m \"Lazy commit on {1}.\"".format(os.path.expanduser(item["path"]), hostname)
|
||||
cmd = "git -C \"{0}\" commit -m \"Lazy commit on {1}.\"".format(os.path.expanduser(item["path"]), hn)
|
||||
output = execute_command(cmd)
|
||||
rm(filepath("status"))
|
||||
return output
|
||||
|
Loading…
x
Reference in New Issue
Block a user