Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/automated-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ jobs:
uses: pypa/gh-action-pypi-publish@release/v1

# update 'doc' branch also
- run: git fetch --all
- run: git checkout doc
- run: git merge origin/master --ff-only
- run: git push origin doc
6 changes: 6 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@
===========


Version 0.23.3 - 3 May 2026
---------------------------

* Internal refactorings; no user-facing changes.


Version 0.23.2 - 3 May 2026
---------------------------

Expand Down
2 changes: 1 addition & 1 deletion homely/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
version = "0.23.2"
version = "0.23.3"
2 changes: 1 addition & 1 deletion homely/_ui.py
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,7 @@ def addfromremote(repo, dest_path):
note("HOME: %s" % os.environ["HOME"])
note("tmp: %s" % tmp)
note("Cloning %s to tmp:%s" % (repo.repo_path, tmp))
repo.clonetopath(tmp)
repo.clonetopath(tmp, submodules=True)

# find out the first commit id
localrepo = repo.frompath(tmp)
Expand Down
2 changes: 1 addition & 1 deletion homely/_vcs/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ def getrepoid(self) -> str:
"%s.%s needs to implement .getrepoid()" % (
self.__class__.__module__, self.__class__.__name__))

def clonetopath(self, dest: str) -> None:
def clonetopath(self, dest: str, submodules: bool) -> None:
"""
Clone the repo at <self.pushablepath> into <dest>
Note that if self.pushablepath is None, then self.path will be used
Expand Down
7 changes: 5 additions & 2 deletions homely/_vcs/git.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,9 +81,12 @@ def pullchanges(self) -> None:

raise SystemError(f"Unexpected output from 'git pull': {err!r}")

def clonetopath(self, dest: str) -> None:
def clonetopath(self, dest: str, submodules: bool) -> None:
origin = self.repo_path
execute(['git', 'clone', '--recurse-submodules', origin, dest])
cmd = ['git', 'clone']
if submodules:
cmd.append('--recurse-submodules')
execute(cmd + [origin, dest])

def getrepoid(self) -> str:
assert not self.isremote
Expand Down
2 changes: 1 addition & 1 deletion homely/_vcs/testhandler.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ def frompath(class_, repo_path: str) -> "Optional[homely._vcs.Repo]":
iscanonical=False,
suggestedlocal=None)

def clonetopath(self, dest_path: str) -> None:
def clonetopath(self, dest_path: str, submodules: bool) -> None:
assert not os.path.exists(dest_path)
os.mkdir(dest_path)
with open(os.path.join(dest_path, ORIGINFILE), 'w') as f:
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ classifiers=[
requires-python = ">=3.10"
# this also needs to be updated in homely/__init__.py
# and uv.lock by running "uv lock"
version = "0.23.2"
version = "0.23.3"

dependencies = [
"python-daemon>=2.3.0",
Expand Down
4 changes: 2 additions & 2 deletions test/system/test_homely_add_repolist.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ def test_homely_add_repolist(tmpdir, HOME):
localrepo3 = os.path.join(HOME, 'repo3')
# use a Repo instance to clone it into our home dir manually
from homely._vcs.testhandler import Repo
Repo.frompath(repo3.url).clonetopath(localrepo3)
Repo.frompath(repo3.url).clonetopath(localrepo3, submodules=False)

# test adding a repo from the local dir
assert not os.path.exists(HOME + '/r3.txt')
Expand All @@ -133,6 +133,6 @@ def test_homely_add_repolist(tmpdir, HOME):
localrepo4 = os.path.join(HOME, 'repo4')
# use a Repo instance to clone it into our home dir manually
from homely._vcs.testhandler import Repo
Repo.frompath(repo4.url).clonetopath(localrepo4)
Repo.frompath(repo4.url).clonetopath(localrepo4, submodules=False)
system(HOMELY('add') + ['.'], cwd=localrepo4)
checkrepolist(HOME, system, [repo1, repo2, repo3, repo4])
4 changes: 2 additions & 2 deletions test/unit/homely/_vcs/test_git.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ def test_git(tmpdir):
assert fake1repo.isdirty()

clone1path = os.path.join(tmpdir, 'clone1')
fake1repo.clonetopath(clone1path)
fake1repo.clonetopath(clone1path, submodules=False)
clone1repo = Repo.frompath(clone1path)
assert clone1repo.getrepoid() == fake1repo.getrepoid()

Expand Down Expand Up @@ -92,7 +92,7 @@ def test_clonetopath_recurses_submodules(tmpdir, monkeypatch):
# clone via Repo.clonetopath()
parentrepo = Repo.frompath(parentpath)
clonepath = os.path.join(tmpdir, 'clone')
parentrepo.clonetopath(clonepath)
parentrepo.clonetopath(clonepath, submodules=True)

# the submodule should already be initialised and checked out
sub_readme = Path(clonepath) / 'libs/the_submodule' / 'README.md'
Expand Down
2 changes: 1 addition & 1 deletion uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading