mirror of
https://github.com/saymrwulf/xous-core.git
synced 2026-11-19 09:00:54 +00:00
Merge pull request #496 from betrusted-io/fix-publish
upgrade the publish script to maintain remote sha2 crate
This commit is contained in:
commit
c3ff9477bd
1 changed files with 19 additions and 12 deletions
31
publish.py
31
publish.py
|
|
@ -249,20 +249,23 @@ def main():
|
||||||
print("Can't simultaneously change to local and remote paths. Pick only one operation.")
|
print("Can't simultaneously change to local and remote paths. Pick only one operation.")
|
||||||
exit(1)
|
exit(1)
|
||||||
|
|
||||||
|
crate_roots = ['.', '../hashes/sha2']
|
||||||
|
|
||||||
if args.bump or args.local_paths or args.remote_paths:
|
if args.bump or args.local_paths or args.remote_paths:
|
||||||
cargo_toml_paths = []
|
cargo_toml_paths = []
|
||||||
for path in Path('.').rglob('Cargo.toml'):
|
for roots in crate_roots:
|
||||||
if 'target' not in str(path):
|
for path in Path(roots).rglob('Cargo.toml'):
|
||||||
not_core_path = True
|
if 'target' not in str(path):
|
||||||
for cratespec in cratelist:
|
not_core_path = True
|
||||||
editpath = cratespec[1]
|
for cratespec in cratelist:
|
||||||
normpath = str(Path(path)).replace('\\', '/').rpartition('/')[0] # fix windows paths
|
editpath = cratespec[1]
|
||||||
# print(editpath)
|
normpath = str(Path(path)).replace('\\', '/').rpartition('/')[0] # fix windows paths
|
||||||
# print(normpath)
|
# print(editpath)
|
||||||
if editpath == normpath:
|
# print(normpath)
|
||||||
not_core_path = False
|
if editpath == normpath:
|
||||||
if not_core_path:
|
not_core_path = False
|
||||||
cargo_toml_paths += [path]
|
if not_core_path:
|
||||||
|
cargo_toml_paths += [path]
|
||||||
|
|
||||||
# import pprint
|
# import pprint
|
||||||
# pp = pprint.PrettyPrinter(indent=2)
|
# pp = pprint.PrettyPrinter(indent=2)
|
||||||
|
|
@ -333,6 +336,10 @@ def main():
|
||||||
print("Retry failed, moving on anyways...")
|
print("Retry failed, moving on anyways...")
|
||||||
time.sleep(1)
|
time.sleep(1)
|
||||||
|
|
||||||
|
print("!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!")
|
||||||
|
print("Don't forget to manually push alternate crate roots to github: {}".format(crate_roots[1:]))
|
||||||
|
print("!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!")
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
main()
|
main()
|
||||||
exit(0)
|
exit(0)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue