mirror of
https://github.com/DarkFlippers/unleashed-firmware.git
synced 2024-11-23 19:00:43 +03:00
scripts: sconsdist: added stub file artifact for older ufbt (#2568)
* scripts: sconsdist: added stub file artifact for older ufbt * scripts: sconsdist: not creating dummy SDK archive
This commit is contained in:
parent
0d8518d31d
commit
89161a7a1e
@ -84,21 +84,16 @@ class Main(App):
|
||||
if exists(sdk_folder := join(obj_directory, foldertype)):
|
||||
self.note_dist_component(foldertype, "dir", sdk_folder)
|
||||
|
||||
def package_zip(self, foldertype, sdk_folder):
|
||||
# TODO: remove this after everyone migrates to new uFBT
|
||||
self.create_zip_stub("lib")
|
||||
|
||||
def create_zip_stub(self, foldertype):
|
||||
with zipfile.ZipFile(
|
||||
self.get_dist_path(self.get_dist_file_name(foldertype, "zip")),
|
||||
"w",
|
||||
zipfile.ZIP_DEFLATED,
|
||||
) as zf:
|
||||
for root, _, files in walk(sdk_folder):
|
||||
for file in files:
|
||||
zf.write(
|
||||
join(root, file),
|
||||
relpath(
|
||||
join(root, file),
|
||||
sdk_folder,
|
||||
),
|
||||
)
|
||||
) as _:
|
||||
pass
|
||||
|
||||
def copy(self) -> int:
|
||||
self._dist_components: dict[str, str] = dict()
|
||||
|
Loading…
Reference in New Issue
Block a user