Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(135)

Side by Side Diff: bin/cros_update_image.sh

Issue 6240018: This starts to fix the scripts so that they load from /usr/lib/crosutils (Closed) Base URL: http://git.chromium.org/git/crosutils.git@master
Patch Set: fixing bad merge Created 9 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « bin/cros_stop_vm ('k') | bin/cros_workon_make » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/bin/bash 1 #!/bin/bash
2 # Copyright (c) 2011 The Chromium OS Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file.
2 5
3 # Usage: 6 # Usage:
4 # update_image.sh [image_to_update] [packages...] 7 # update_image.sh [image_to_update] [packages...]
5 usage() 8 usage()
6 { 9 {
7 cat <<EOF 10 cat <<EOF
8 11
9 usage: 12 usage:
10 update_image.sh [image_to_update] [packages...] 13 update_image.sh [image_to_update] [packages...]
11 EOF 14 EOF
12 } 15 }
13 16
14 if [[ $# < 2 ]]; then 17 if [[ $# < 2 ]]; then
15 echo "Not enough arguments supplied." 18 echo "Not enough arguments supplied."
16 usage 19 usage
17 exit 1 20 exit 1
18 fi 21 fi
19 22
20 if [[ -f /home/${USER}/trunk/src/scripts/.default_board ]]; then 23 if [[ -f /home/${USER}/trunk/src/scripts/.default_board ]]; then
21 BOARD=$( cat /home/${USER}/trunk/src/scripts/.default_board ) 24 BOARD=$( cat /home/${USER}/trunk/src/scripts/.default_board )
22 else 25 else
23 BOARD=st1q 26 BOARD=st1q
24 fi 27 fi
25 28
26 IMAGE=$( readlink -f ${1} ) 29 IMAGE=$( readlink -f ${1} )
27 IMAGE_DIR=$( dirname ${IMAGE} ) 30 IMAGE_DIR=$( dirname "${IMAGE}" )
28 shift 31 shift
29 PKGS=$@ 32 PKGS=$@
30 33
31 if [[ -z "${IMAGE}" || ! -f ${IMAGE} ]]; then 34 if [[ -z "${IMAGE}" || ! -f ${IMAGE} ]]; then
32 echo "Missing required argument 'image_to_update'" 35 echo "Missing required argument 'image_to_update'"
33 usage 36 usage
34 exit 1 37 exit 1
35 fi 38 fi
36 39
37 cd ${IMAGE_DIR} 40 cd ${IMAGE_DIR}
(...skipping 25 matching lines...) Expand all
63 sudo dd if="./rootfs/boot/vmlinuz" of=part_2 bs=512 count=8192 conv=notrunc 66 sudo dd if="./rootfs/boot/vmlinuz" of=part_2 bs=512 count=8192 conv=notrunc
64 fi 67 fi
65 68
66 sudo umount rootfs/usr/local 69 sudo umount rootfs/usr/local
67 sudo umount rootfs/var 70 sudo umount rootfs/var
68 sudo umount rootfs 71 sudo umount rootfs
69 sudo umount stateful_part 72 sudo umount stateful_part
70 ./pack_partitions.sh ${IMAGE} 73 ./pack_partitions.sh ${IMAGE}
71 74
72 cd - 75 cd -
OLDNEW
« no previous file with comments | « bin/cros_stop_vm ('k') | bin/cros_workon_make » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698