AWS EC2 and VPC API support in standalone service for OpenStack.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

update-from-global-requirements.sh 1.2KB

1234567891011121314151617181920212223242526272829303132333435
  1. #!/bin/bash
  2. # Copyright (c) 2016 OpenStack Foundation
  3. # All Rights Reserved.
  4. #
  5. # Licensed under the Apache License, Version 2.0 (the "License"); you may
  6. # not use this file except in compliance with the License. You may obtain
  7. # a copy of the License at
  8. #
  9. # http://www.apache.org/licenses/LICENSE-2.0
  10. #
  11. # Unless required by applicable law or agreed to in writing, software
  12. # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
  13. # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
  14. # License for the specific language governing permissions and limitations
  15. # under the License.
  16. GLOBAL_REQS_PATH=${1:-$HOME/openstack/requirements/global-requirements.txt}
  17. function update() {
  18. rm -f temp-requirements.txt
  19. touch temp-requirements.txt
  20. while read line ; do
  21. local module=`echo $line | sed 's/\([.A-Za-z0-9\-]*\)[ ><!=\t]*.*/\1/'`
  22. local newm=`grep -e "^$module[ ><!=\t]" $GLOBAL_REQS_PATH`
  23. if ! grep "$newm" temp-requirements.txt >/dev/null ; then
  24. echo "$newm" >> temp-requirements.txt
  25. fi
  26. done < $1
  27. mv temp-requirements.txt $1
  28. }
  29. echo "Update requirements"
  30. update requirements.txt
  31. echo "Update test-requirements"
  32. update test-requirements.txt