blob: 68bd85dc615649ad520de3f757345634d658dd9f [file] [log] [blame]
Dan Smithedee6dc2021-01-12 14:04:38 -08001#!/bin/bash
2
3# This is a small helper to speed development and debug with devstack.
4# It is intended to help you run a single function in a project module
5# without having to re-stack.
6#
7# For example, to run the just start_glance function, do this:
8#
9# ./tools/debug_function.sh glance start_glance
10
11if [ ! -f "lib/$1" ]; then
12 echo "Usage: $0 [project] [function] [function...]"
13fi
14
15source stackrc
16source lib/$1
17shift
18set -x
19while [ "$1" ]; do
20 echo ==== Running $1 ====
21 $1
22 echo ==== Done with $1 ====
23 shift
24done