Skip to content

Commit

Permalink
node: Add yarn2 support
Browse files Browse the repository at this point in the history
  • Loading branch information
catsout committed Jul 12, 2022
1 parent ed05266 commit d22a790
Show file tree
Hide file tree
Showing 2 changed files with 322 additions and 19 deletions.
9 changes: 7 additions & 2 deletions node/flatpak_node_generator/manifest.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,9 +162,14 @@ def add_data_source(self, data: Union[str, bytes], destination: Path) -> None:
self._add_source_with_destination(source, destination, is_dir=False)

def add_git_source(
self, url: str, commit: str, destination: Optional[Path] = None
self, url: str, commit: Optional[str] = None, destination: Optional[Path] = None, tag: Optional[str] = None
) -> None:
source = {'type': 'git', 'url': url, 'commit': commit}
source = {'type': 'git', 'url': url}
assert commit or tag
if commit:
source['commit'] = commit
if tag:
source['tag'] = tag
self._add_source_with_destination(source, destination, is_dir=True)

def add_script_source(self, commands: List[str], destination: Path) -> None:
Expand Down
Loading

0 comments on commit d22a790

Please sign in to comment.