Skip to content
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

Fix boot-pack help. #191

Merged
merged 1 commit into from
Feb 8, 2024
Merged

Fix boot-pack help. #191

merged 1 commit into from
Feb 8, 2024

Conversation

jsirois
Copy link
Collaborator

@jsirois jsirois commented Feb 8, 2024

The reference to --path was in error, it should have been
-sj|--jump|--scie-jump.

The reference to `--path` was in error, it should have been
`-sj|--jump|--scie-jump`.
@jsirois jsirois requested review from benjyw and sureshjoshi February 8, 2024 22:23
the lift manifest is appended to the tail of the scie as a single
line JSON document, but can be made a multi-line pretty-printed JSON
document by passing --no-single-lift-line.
alternate scie-jump binary can be specified using --scie-jump. By
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The option processing for boot-pack is here:

jump/src/boot/pack.rs

Lines 259 to 283 in 1bd89d3

pub(crate) fn set(mut jump: Jump, mut scie_jump_path: PathBuf) -> ExitResult {
let mut lifts = vec![];
let mut single_line = true;
let mut args = env::args().skip(1);
while let Some(arg) = args.next() {
match arg.as_str() {
"-1" | "--single-lift-line" => single_line = true,
"--no-single-lift-line" => single_line = false,
"-sj" | "--jump" | "--scie-jump" => {
scie_jump_path = PathBuf::from(args.next().ok_or_else(|| {
Code::FAILURE.with_message(format!(
"The {arg} flag requires an argument pointing to an alternate \
scie-jump binary to pack in the scie tip."
))
})?);
jump.size = scie_jump_path
.metadata()
.map_err(|e| {
Code::FAILURE.with_message(format!(
"Failed to determine size of alternate scie-jump {path}: {e}",
path = scie_jump_path.display()
))
})?
.len() as usize;
}

@jsirois jsirois merged commit 60ce878 into a-scie:main Feb 8, 2024
9 checks passed
@jsirois jsirois deleted the help/fix branch February 8, 2024 23:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants