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

Side by Side Diff: mount_gpt_image.sh

Issue 4853001: Convert rootfs and stateful mountpts to absolute paths. (Closed) Base URL: http://git.chromium.org/git/crosutils.git@master
Patch Set: Created 10 years, 1 month 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 | « no previous file | no next file » | 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 2
3 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. 3 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be 4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file. 5 # found in the LICENSE file.
6 6
7 # Helper script that mounts chromium os image from a device or directory 7 # Helper script that mounts chromium os image from a device or directory
8 # and creates mount points for /var and /usr/local (if in dev_mode). 8 # and creates mount points for /var and /usr/local (if in dev_mode).
9 9
10 . "$(dirname "$0")/common.sh" 10 . "$(dirname "$0")/common.sh"
(...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after
132 fi 132 fi
133 echo "Image specified by ${FLAGS_from} mounted at"\ 133 echo "Image specified by ${FLAGS_from} mounted at"\
134 "${FLAGS_rootfs_mountpt} successfully." 134 "${FLAGS_rootfs_mountpt} successfully."
135 } 135 }
136 136
137 # Find the last image built on the board. 137 # Find the last image built on the board.
138 if [ ${FLAGS_most_recent} -eq ${FLAGS_TRUE} ] ; then 138 if [ ${FLAGS_most_recent} -eq ${FLAGS_TRUE} ] ; then
139 FLAGS_from="$(./get_latest_image.sh --board="${FLAGS_board}")" 139 FLAGS_from="$(./get_latest_image.sh --board="${FLAGS_board}")"
140 fi 140 fi
141 141
142 # Turn path into an absolute path. 142 # Turn paths into absolute paths.
143 FLAGS_from=`eval readlink -f ${FLAGS_from}` 143 FLAGS_from=`eval readlink -f ${FLAGS_from}`
144 FLAGS_rootfs_mountpt=`eval readlink -f ${FLAGS_rootfs_mountpt}`
145 FLAGS_stateful_mountpt=`eval readlink -f ${FLAGS_stateful_mountpt}`
144 146
145 # Perform desired operation. 147 # Perform desired operation.
146 if [ ${FLAGS_unmount} -eq ${FLAGS_TRUE} ] ; then 148 if [ ${FLAGS_unmount} -eq ${FLAGS_TRUE} ] ; then
147 unmount_image 149 unmount_image
148 else 150 else
149 mount_image 151 mount_image
150 fi 152 fi
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698