Background
I'm using vi with a php/laravel code base.. I ran ctags and see what happens:
filename: app/Http/Controllers/RetailerApproveController.php
use App\Repositories\ApproveOrderRepo;
...
$repo = new ApproveOrderRepo();
when I do my tags shortcut (ctrl]) I jump straight to the use line above, rather than the actual file that contains the definition of ApproveOrderRepo.
notice that if i'm in the file RetailerApproveController
and I run :Tags
I get a list, and it autocompletes as I type ApproveOrderRepo
like so:
which begins like this:
namespace App\Repositories;
use App\Order;
...
class ApproveOrderRepo
{
use DispatchesJobs;
Question
How do I make the the key mapping automatically jump the class definition file, rather than the use statement or some other file?
for reference, this is what i have in my tags file:
ApproveOrderRepo app/Http/Controllers/EnRouteToClientController.php /^use App\\Repositories\\ApproveOrderRepo;$/;" a namespace:App\\Http\\Controllers typeref:unknown:App\\Repositories\\ApproveOrderRepo
ApproveOrderRepo app/Http/Controllers/RetailerApproveController.php /^use App\\Repositories\\ApproveOrderRepo;$/;" a namespace:App\\Http\\Controllers typeref:unknown:App\\Repositories\\ApproveOrderRepo
ApproveOrderRepo app/Repositories/ApproveOrderRepo.php /^class ApproveOrderRepo$/;" c namespace:App\\Repositories
ApproveOrderRepo tests/ApproveOrderTest.php /^use App\\Repositories\\ApproveOrderRepo;$/;" a typeref:unknown:App\\Repositories\\ApproveOrderRepo