New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 674385 link

Starred by 1 user

Issue metadata

Status: Available
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 2
Type: Feature



Sign in to add a comment

Suggested Improvement: image_to_vm.sh should perform sanity check on arguments

Project Member Reported by h...@chromium.org, Dec 15 2016

Issue description

Email thread as background:

I'm encountering an issue that seems to be caused by the env $GPT not defined. Has anyone seem this before? Thanks

~/trunk/src/scripts $ sh image_to_vm.sh  --from ../build/images/samus/R57-9083.0.2016_12_13_1211-a1/ --board=samus
/mnt/host/source/src/scripts/build_library/disk_layout_util.sh: line 310: syntax error near unexpected token `<'

Where the line 310 of disk_layout_util.sh is:

307    for x in "${unpack}" "${pack}" "${mount}" "${umount}"; do
308      echo "esac" >> "${x}"
309    done
310  done < <(${GPT} show -q "${image}")

...... (10 minutes later) ......

Never mind. I forgot to add an "=" in my command line

 sh image_to_vm.sh  --from=../build/images/samus/R57-9083.0.2016_12_13_1211-a1/ --board=samus

Per vapier@:  bad command line options should get rejected early rather than leading to weird errors like this.
 
Components: Infra

Comment 2 by mmoss@chromium.org, Jan 2 2018

Components: -Infra Infra>Client>ChromeOS
[It appears that a bunch of old cros issues bulk-added the "Infra" component recently, but they should probably be "Infra>Client>ChromeOS".]
Components: -Infra>Client>ChromeOS Infra>Client>ChromeOS>Build
Status: Available (was: Untriaged)

Sign in to add a comment