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

Side by Side Diff: mod_for_factory_scripts/500populateQualDbs

Issue 3290021: Reflect the change of QualDbs location moved. (Closed) Base URL: http://git.chromium.org/git/crosutils.git
Patch Set: fix typo Created 10 years, 3 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 | « 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 TEST_DIR="${ROOT_FS_DIR}/usr/local/autotest/site_tests/hardware_Components" 7 TEST_DIR="${ROOT_FS_DIR}/usr/local/autotest/site_tests/hardware_Components"
8 8
9 pushd ${TEST_DIR} 1> /dev/null 9 pushd ${TEST_DIR} 1> /dev/null
10 10
11 if [ -z ${QUALDB} ]; then 11 # Remove the DB directories belonging to other boards.
12 # If QUALDB not specified, check the existence of the qualified components 12 KEEPDB="data_${BOARD}"
13 # belonging to the board. 13 ls -d data_* 2> /dev/null | grep -v ${KEEPDB} | xargs rm -fr
14 QUALDB="qualified_components_${BOARD}*" 14
15 FIRST_QUALDB=$(ls $QUALDB 2> /dev/null | head -1) 15 # Ensure there is DB directory in x86-agz and x86-mario.
16 if [ ! -z ${FIRST_QUALDB} ]; then 16 if [ ! -d ${KEEPDB} -a \
17 # Remove qualified components belonging to other boards 17 \( "${BOARD}" = "x86-agz" -o "${BOARD}" = "x86-mario" \) ]; then
18 ls qualified_components* 2> /dev/null | grep -v \ 18 echo "No component DB directory found at: ${KEEPDB}"
19 qualified_components_${BOARD} | xargs rm -f
20 else
21 echo "No qualified component file found at: ${QUALDB}"
22 fi
23 else
24 rm -f qualified_components*
25 echo "Copying ${QUALDB} to the image."
26 cp -f ${QUALDB} ${TEST_DIR}/
27 fi 19 fi
28 20
29 popd 1> /dev/null 21 popd 1> /dev/null
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