![](https://seccdn.libravatar.org/avatar/bcd65ca98f9d97839f15c54575c7edec.jpg?s=120&d=mm&r=g)
This patch adds a --ctags option which automatically invokes "make tags" in the build directory. Signed-off-by: Jeff Mahoney <jeffm@suse.com> --- scripts/sequence-patch.sh | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) --- a/scripts/sequence-patch.sh +++ b/scripts/sequence-patch.sh @@ -40,7 +40,7 @@ usage() { cat <<END SYNOPSIS: $0 [-qv] [--symbol=...] [--dir=...] [--combine] [--fast] [last-patch-name] [--vanilla] [--fuzz=NUM] - [--build-dir=PATH] [--config=ARCH-FLAVOR [--kabi]] + [--build-dir=PATH] [--config=ARCH-FLAVOR [--kabi]] [--ctags] The --build-dir option supports internal shell aliases, like ~, and variable expansion when the variables are properly escaped. Environment variables @@ -64,7 +64,7 @@ if $have_arch_patches; then else arch_opt="" fi -options=`getopt -o qvd:F: --long quilt,no-quilt,$arch_opt,symbol:,dir:,combine,fast,vanilla,fuzz,build-dir:,config:,kabi -- "$@"` +options=`getopt -o qvd:F: --long quilt,no-quilt,$arch_opt,symbol:,dir:,combine,fast,vanilla,fuzz,build-dir:,config:,kabi,ctags -- "$@"` if [ $? -ne 0 ] then @@ -84,6 +84,7 @@ CONFIG= CONFIG_ARCH= CONFIG_FLAVOR= KABI=false +CTAGS=false while true; do case "$1" in @@ -136,6 +137,9 @@ while true; do --kabi) KABI=true ;; + --ctags) + CTAGS=true + ;; --) shift break ;; @@ -518,6 +522,15 @@ if test -n "$CONFIG"; then fi fi +if $CTAGS; then + if ctags --version > /dev/null; then + echo "[ Generating ctags (this may take a while)]" + make -s --no-print-directory -C "$PATCH_DIR" O="$SP_BUILD_DIR" tags + else + echo "[ Could not generate ctags: ctags not found ]" + fi +fi + [ $# -gt 0 ] && exit $status if ! $have_defconfig_files || test ! -e config.conf; then -- To unsubscribe, e-mail: opensuse-kernel+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-kernel+help@opensuse.org