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

Tracer accepts argument for program_name #100

Merged
merged 1 commit into from
Nov 29, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions tracer/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,14 +1,20 @@
extern crate tracer;

use std::{env, path::PathBuf};
use std::env;

use tracer::{trace, decode};
use common::serializable::Serializable;
use common::path::JoltPaths;

pub fn main() {
// Note: assumes program is already compiled
let program_name = "hash";
let args: Vec<String> = env::args().collect();
if args.len() != 2 {
eprintln!("Usage: {} <program_name>", args[0]);
std::process::exit(1);
}
let program_name = &args[1];

let elf_location = JoltPaths::elf_path(program_name);
let trace_destination = JoltPaths::trace_path(program_name);
let bytecode_destination = JoltPaths::bytecode_path(program_name);
Expand Down
Loading