-
Notifications
You must be signed in to change notification settings - Fork 54
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: uploading to prefix.dev #432
Conversation
src/upload.rs
Outdated
println!("Upload successful!"); | ||
} else { | ||
println!("Upload failed!"); | ||
if response.status() == 401 { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@0xbe7a I refactored the code a little bit and added progress bars to each of the methods. Do you think you can test this for quetz & artifactory? This also allows to put more than a single package for uploading, e.g.
|
src/upload.rs
Outdated
let index_json = IndexJson::from_package_directory(package_dir.path()).into_diagnostic()?; | ||
let subdir = index_json | ||
.subdir | ||
.ok_or_else(|| miette::miette!("index.json of the package has no subdirectory. Cannot determine which directory to upload to"))?; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should include the package name in the error message
Looks good, i will test the Quetz and Artifactory upload later today |
OK, let me know how it goes and then I'll merge :) |
Works as advertised, ready to merge! 🤠 |
No description provided.