2
0
mirror of https://expo.survex.com/repositories/troggle/.git synced 2025-12-17 12:37:07 +00:00

nearly done cave edit commit thing with cookie

This commit is contained in:
2024-12-28 19:47:28 +00:00
parent 09a16fed3b
commit ecd187e88e
3 changed files with 164 additions and 110 deletions

View File

@@ -19,7 +19,7 @@ from troggle.core.models.caves import Cave, GetCaveLookup
from troggle.core.models.logbooks import LogbookEntry
from troggle.core.models.survex import SurvexBlock, SurvexFile #, SurvexDirectory
from troggle.core.models.wallets import Wallet
from troggle.core.utils import COOKIE_MAX_AGE, current_expo, git_string, only_commit
from troggle.core.utils import COOKIE_MAX_AGE, current_expo, git_string, add_commit
from troggle.parsers.survex import parse_one_file
"""Everything that views survexfiles
@@ -234,7 +234,7 @@ class SvxForm(forms.Form):
else:
comment = f"Online survex edit: {self.data['filename']}.svx on dev machine '{socket.gethostname()}' "
print(f"Committing file which has been saved {editor=}")
only_commit(fname, comment, editor)
add_commit(fname, comment, editor)
msg = f"SAVED and committed to git (if there were differences)\nEdited by:{editor}"
# should only call this is something changed