| OLD | NEW |
| 1 #!/bin/bash | 1 #!/bin/bash |
| 2 | 2 |
| 3 # Copyright (c) 2009 The Chromium OS Authors. All rights reserved. | 3 # Copyright (c) 2009 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 # Load common constants. This should be the first executable line. | 7 # Load common constants. This should be the first executable line. |
| 8 # The path to common.sh should be relative to your script's location. | 8 # The path to common.sh should be relative to your script's location. |
| 9 . "$(dirname "$0")/common.sh" | 9 . "$(dirname "$0")/common.sh" |
| 10 | 10 |
| 11 # Script must be run outside the chroot | 11 # Script must be run outside the chroot and as a regular user. |
| 12 assert_outside_chroot | 12 assert_outside_chroot |
| 13 assert_not_root_user |
| 13 | 14 |
| 14 DEFAULT_DEST="$GCLIENT_ROOT/repo" | 15 DEFAULT_DEST="$GCLIENT_ROOT/repo" |
| 15 DEFAULT_DEV_PKGLIST="$SRC_ROOT/package_repo/repo_list_dev.txt" | 16 DEFAULT_DEV_PKGLIST="$SRC_ROOT/package_repo/repo_list_dev.txt" |
| 16 DEFAULT_IMG_PKGLIST="$SRC_ROOT/package_repo/repo_list_image.txt" | 17 DEFAULT_IMG_PKGLIST="$SRC_ROOT/package_repo/repo_list_image.txt" |
| 17 | 18 |
| 18 # Command line options | 19 # Command line options |
| 19 DEFINE_string suite "$DEFAULT_EXT_SUITE" "Ubuntu suite to pull packages from." | 20 DEFINE_string suite "$DEFAULT_EXT_SUITE" "Ubuntu suite to pull packages from." |
| 20 DEFINE_string mirror "$DEFAULT_EXT_MIRROR" "Ubuntu repository mirror to use." | 21 DEFINE_string mirror "$DEFAULT_EXT_MIRROR" "Ubuntu repository mirror to use." |
| 21 DEFINE_string dest "$DEFAULT_DEST" "Destination directory for repository." | 22 DEFINE_string dest "$DEFAULT_DEST" "Destination directory for repository." |
| 22 DEFINE_string devlist "$DEFAULT_DEV_PKGLIST" \ | 23 DEFINE_string devlist "$DEFAULT_DEV_PKGLIST" \ |
| (...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 216 | 217 |
| 217 if [ $FLAGS_upimg -eq $FLAGS_TRUE ] | 218 if [ $FLAGS_upimg -eq $FLAGS_TRUE ] |
| 218 then | 219 then |
| 219 update_suite $FLAGS_imgsuite $FLAGS_imglist | 220 update_suite $FLAGS_imgsuite $FLAGS_imglist |
| 220 fi | 221 fi |
| 221 | 222 |
| 222 # Clean up the chroot mounts | 223 # Clean up the chroot mounts |
| 223 cleanup_chroot_mounts | 224 cleanup_chroot_mounts |
| 224 | 225 |
| 225 echo "Done." | 226 echo "Done." |
| OLD | NEW |