If this is something that is only gonna be used for one kind of object, and not for all use in the repository, you could just make a new Repository, containing that query, but built on IRepository.
public interface IVehicleRepository : IRepository<Vehicle>{
IEnumerable<int> GetDistinctVehicle();
}
public VehicleRepository : EfRepository<Vehicle>, IVehicleRepository{
public VehicleRepository(DbContext context) : base(context)
{
}
public IEnumerable<int> GetDistinctVehicle(){
Context.Set<Vehicle>().Select(x=> x.ModelYear).Distinct();
}
}
In that way, you can still use all of the IRepositorystuff, but also your extra method. Just bind IVehicleRepository to VehicleRepository in your injector of your choice and inject it into the constructor like you do with the IRepositories.