ack.vim
ack.vim copied to clipboard
Some files are missing when using the_silver_searcher
Using grep as the back-end does not have this problem, but I need to use ag for its ability to auto-source .gitignore files.
LMK if you need a zip of the file structure for testing; can't post it here.
Command line output:
$ ag --vimgrep i18n
Gruntfile.js:6:3: i18nextract: {
Gruntfile.js:10:12: dest: 'i18nStrings'
Gruntfile.js:16:34: grunt.registerTask('extract', ['i18nextract']);
lib/index.js:22:54: $translateProvider.translations(lang, global.config.i18n.reporting);
lib/page/navbar/user-profile-menu/user-profile-menu-controller.js:26:27: name: global.config.i18n.general.tickets,
lib/page/navbar/user-profile-menu/user-profile-menu-controller.js:31:27: name: global.config.i18n.general.invite,
lib/page/navbar/user-profile-menu/user-profile-menu-controller.js:36:27: name: global.config.i18n.general.setup,
lib/page/navbar/user-profile-menu/user-profile-menu-controller.js:41:27: name: global.config.i18n.general.webIntercept,
lib/page/navbar/user-profile-menu/user-profile-menu-controller.js:54:25: label: global.config.i18n.general.userRole,
lib/page/navbar/user-profile-menu/user-profile-menu-controller.js:65:25: label: global.config.i18n.general.admin,
lib/page/navbar/user-profile-menu/user-profile-menu-controller.js:73:25: label: global.config.i18n.general.language,
lib/page/navbar/user-profile-menu/user-profile-menu-controller.js:94:25: label: global.config.i18n.general.tryMobileApp,
lib/page/navbar/user-profile-menu/user-profile-menu-controller.js:101:25: label: global.config.i18n.general.logout,
public/index.html:22:22: var nsObj = config.i18n[ns];
public/index.html:27:17: return config.i18n[ns][str] || str;
public/with-service-message.html:108:3: i18n: {
public/with-service-message.html:177:22: var nsObj = config.i18n[ns];
public/with-service-message.html:182:17: return config.i18n[ns][str] || str;
stubs/config.json:12:3: "i18n": {
stubs/userprofilemenu.json:39:3: "i18n": {
test/unit/page/navbar/user-profile-menu/user-profile-menu-controller.spec.js:33:35: var translated = global.config.i18n.reporting[value];
Plugin output:
Gruntfile.js|6 col 3| i18nextract: {
Gruntfile.js|10 col 12| dest: 'i18nStrings'
Gruntfile.js|16 col 34| grunt.registerTask('extract', ['i18nextract']);
|| .config.i18n.general.tickets,
lib/page/navbar/user-profile-menu/user-profile-menu-controller.js|31 col 27| name: global.config.i18n.general.invite,
lib/page/navbar/user-profile-menu/user-profile-menu-controller.js|36 col 27| name: global.config.i18n.general.setup,
lib/page/navbar/user-profile-menu/user-profile-menu-controller.js|41 col 27| name: global.config.i18n.general.webIntercept,
lib/page/navbar/user-profile-menu/user-profile-menu-controller.js|54 col 25| label: global.config.i18n.general.userRole,
lib/page/navbar/user-profile-menu/user-profile-menu-controller.js|65 col 25| label: global.config.i18n.general.admin,
lib/page/navbar/user-profile-menu/user-profile-menu-controller.js|73 col 25| label: global.config.i18n.general.language,
lib/page/navbar/user-profile-menu/user-profile-menu-controller.js|94 col 25| label: global.config.i18n.general.tryMobileApp,
lib/page/navbar/user-profile-menu/user-profile-menu-contr/index.html|27 col 17| return config.i18n[ns][str] || str;
|| ;
public/with-service-message.html|182 col 17| return config.i18n[ns][str] || str;
|| 18n": {
-profile-menu-controller.spec.js|33 col 35| var translated = global.config.i18n.reporting[value];
.vimrc config:
"Ack.vim settings
map <leader>a :ag
CommandCabbr ag Ack
let g:ack_use_dispatch = 1
let g:ack_use_cword_for_empty_search = 1
" Use ag
if executable('ag')
let g:ackprg = 'ag --vimgrep'
endif
Hi @djmadeira, sorry that I haven't been able to investigate this sooner. Did you work out any reason that might explain the discrepancy?
Missing results is no good indeed. If you do have a shareable reproduction, that would be great for trying to track down the cause.
I figured it out. It seems that smart case doesn't work when using ag as the ackprg. So when I search a string that has a capital letter in it, both ag --vimgrep
and Ack.vim display the same result, but when I use an all lowercase search, Ack.vim is case-sensitive while ag
is not.