#!/bin/bash ## usage: bash cleanup-Drupal.Commenting.FunctionComment.SeePunctuation.sh vi ## usage: bash cleanup-Drupal.Commenting.FunctionComment.SeePunctuation.sh joe [ -n "$1" ] && EDITOR="$1" if [ -z "$EDITOR" ]; then echo "Please provide parameter 1 (editor). Example: vi, joe" exit 1 fi function edit_at_line() { local f="$1" local l="$2" $EDITOR +$l "$f" } echo Process cleanup for 'Drupal.Commenting.FunctionComment.SeePunctuation' echo Number of lines: 7 echo Examples: 'Array ( [0] => Trailing punctuation for @see references is not allowed. ) ' echo Press ENTER to begin read edit_at_line 'CRM/Case/BAO/Case.php' 3406 edit_at_line 'CRM/Contact/BAO/Contact.php' 3315 edit_at_line 'CRM/Contact/BAO/GroupContact.php' 811 edit_at_line 'CRM/Contribute/BAO/Contribution.php' 3183 edit_at_line 'CRM/Core/BAO/Address.php' 1265 edit_at_line 'CRM/Core/BAO/EntityTag.php' 404 edit_at_line 'CRM/Event/BAO/Participant.php' 2195