Skip to content

Commit d19609f

Browse files
committed
chore(git): Move types up
1 parent f82b3d2 commit d19609f

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

libvcs/projects/git.py

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,18 @@ class GitRemote(NamedTuple):
3737
push_url: str
3838

3939

40+
class GitRemoteDict(TypedDict):
41+
"""For use when hydrating GitProject via dict."""
42+
43+
fetch_url: str
44+
push_url: str
45+
46+
47+
GitProjectRemoteDict = Dict[str, GitRemote]
48+
GitFullRemoteDict = Dict[str, GitRemoteDict]
49+
GitRemotesArgs = Union[None, GitFullRemoteDict, Dict[str, str]]
50+
51+
4052
class GitStatus(NamedTuple):
4153
branch_oid: Optional[str]
4254
branch_head: Optional[str]
@@ -125,18 +137,6 @@ def convert_pip_url(pip_url: str) -> VCSLocation:
125137
return VCSLocation(url=url, rev=rev)
126138

127139

128-
class GitRemoteDict(TypedDict):
129-
"""For use when hydrating GitProject via dict."""
130-
131-
fetch_url: str
132-
push_url: str
133-
134-
135-
GitProjectRemoteDict = Dict[str, GitRemote]
136-
GitFullRemoteDict = Dict[str, GitRemoteDict]
137-
GitRemotesArgs = Union[None, GitFullRemoteDict, Dict[str, str]]
138-
139-
140140
class GitProject(BaseProject):
141141
bin_name = "git"
142142
schemes = ("git", "git+http", "git+https", "git+ssh", "git+git", "git+file")

0 commit comments

Comments
 (0)