Skip to content

Commit

Permalink
git subrepo pull uno
Browse files Browse the repository at this point in the history
subrepo:
  subdir:   "uno"
  merged:   "422ff83"
upstream:
  origin:   "https://github.com/prrvchr/uno.git"
  branch:   "main"
  commit:   "422ff83"
git-subrepo:
  version:  "0.4.3"
  origin:   "https://github.com/ingydotnet/git-subrepo.git"
  commit:   "2f68596"
  • Loading branch information
prrvchr committed Apr 16, 2024
1 parent 91cb8cc commit 836afb7
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
4 changes: 2 additions & 2 deletions uno/.gitrepo
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
[subrepo]
remote = https://github.com/prrvchr/uno.git
branch = main
commit = 0322c8b67a80923af08794d2df4241011e021577
parent = e89721142aa70e6e0566d7158aa1814d6ea876e5
commit = 422ff83478fdfab3785a998566fa5465f13dfadc
parent = 91cb8ccbddc1962bf37b645793722bb351ec8400
method = merge
cmdver = 0.4.3
11 changes: 8 additions & 3 deletions uno/lib/uno/embedded/documenthandler.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ def __init__(self, ctx, lock, logger, url, index):
self._lock = lock
self._logger = logger
self._listening = False
self._created = False
self._path, self._folder = self._getDataBaseInfo(url)
self._url = url
self._index = index
Expand Down Expand Up @@ -130,16 +131,20 @@ def setListener(self, document):
document.addCloseListener(self)

def removeFolder(self):
sf = getSimpleFile(self._ctx)
if sf.isFolder(self._path):
sf.kill(self._path)
# XXX: The database folder will be deleted only if it was created
if self._created:
sf = getSimpleFile(self._ctx)
if sf.isFolder(self._path):
sf.kill(self._path)

# DocumentHandler getter methods
def getConnectionUrl(self, storage):
with self._lock:
exist = storage.hasElements()
sf = getSimpleFile(self._ctx)
if not sf.exists(self._path):
# XXX: The database folder will be deleted only if it was created
self._created = True
sf.createFolder(self._path)
if exist:
count = self._extractStorage(sf, storage, self._path)
Expand Down

0 comments on commit 836afb7

Please sign in to comment.