-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Move CI workflow to common script, simplify packaging script, remove …
…packing into a tarball since CI already packages artifacts into an archive Internal-tag: [#57771] Signed-off-by: Krzysztof Obłonczek <[email protected]>
- Loading branch information
1 parent
22ce47f
commit ccf0adc
Showing
10 changed files
with
110 additions
and
197 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,7 +9,6 @@ exclude = | |
.eggs, | ||
.git, | ||
.gitignore, | ||
.github, | ||
.nox, | ||
.pytest_cache, | ||
__pycache__, | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
# Copyright (c) 2024 Antmicro <www.antmicro.com> | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
||
from dataclasses import dataclass | ||
from pathlib import Path | ||
from typing import List | ||
|
||
from topwrap.repo.files import HttpGetFile | ||
from topwrap.repo.user_repo import UserRepo, VerilogFileHandler | ||
|
||
|
||
@dataclass | ||
class RemoteRepo: | ||
name: str | ||
root_url: str | ||
sources: List[str] | ||
|
||
|
||
repos = [ | ||
RemoteRepo( | ||
name="vexriscv", | ||
root_url="https://raw.githubusercontent.com/litex-hub/pythondata-cpu-vexriscv/1979a644dbe64d8d32dfbdd970dccee6add63723/pythondata_cpu_vexriscv/verilog", | ||
sources=[ | ||
"VexRiscv.v", | ||
], | ||
), | ||
] | ||
|
||
|
||
def package_cores(): | ||
"""Generates reusable cores package for usage in Topwrap project.""" | ||
core_repo = UserRepo() | ||
|
||
for repo in repos: | ||
core_files = [] | ||
for file in repo.sources: | ||
core_files.append(HttpGetFile(f"{repo.root_url}/{file}")) | ||
|
||
core_repo.add_files(VerilogFileHandler(core_files)) | ||
|
||
Path(repo.name).mkdir(exist_ok=True) | ||
core_repo.save(repo.name) | ||
|
||
|
||
if __name__ == "__main__": | ||
package_cores() |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.