New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

csv_autocmnd_arrange file size threshold #39

Closed
justmytwospence opened this Issue Nov 16, 2014 · 3 comments

Comments

Projects
None yet
2 participants
@justmytwospence

justmytwospence commented Nov 16, 2014

It would be cool if instead of a binary setting:

let g:csv_autocmd_arrange=1

one could specify a maximum file size beneath which the Arrange command will autoexecute.

@chrisbra

This comment has been minimized.

Show comment
Hide comment
@chrisbra

chrisbra Nov 16, 2014

Owner

Good idea. Can you check, if current head works for you? Besides enabling g:csv_autocmd_arrange=1 you also need to set the g:csv_autocmd_arrange_size to your maximum file size.

Owner

chrisbra commented Nov 16, 2014

Good idea. Can you check, if current head works for you? Besides enabling g:csv_autocmd_arrange=1 you also need to set the g:csv_autocmd_arrange_size to your maximum file size.

@justmytwospence

This comment has been minimized.

Show comment
Hide comment
@justmytwospence

justmytwospence Nov 16, 2014

At first I thought it wasn't working, but then I changed

Plug 'chrisbra/csv.vim', {'for': 'csv'}

(which limits the plugin to just csv filetypes in the vim-plug manager, to a plain

Plug 'christbra/csv.vim'

and now it seems to work just fine. Thanks! Great plugin.

justmytwospence commented Nov 16, 2014

At first I thought it wasn't working, but then I changed

Plug 'chrisbra/csv.vim', {'for': 'csv'}

(which limits the plugin to just csv filetypes in the vim-plug manager, to a plain

Plug 'christbra/csv.vim'

and now it seems to work just fine. Thanks! Great plugin.

@chrisbra

This comment has been minimized.

Show comment
Hide comment
@chrisbra

chrisbra Nov 18, 2014

Owner

Am 2014-11-17 00:07, schrieb Spencer Boucher:

At first I thought it wasn't working, but then I changed

Plug 'chrisbra/csv.vim', {'for': 'csv'}

(which limits the plugin to just csv filetypes in the vim-plug
manager, to a plain

Plug 'christbra/csv.vim'

and now it seems to work just fine. Thanks! Great plugin.

Yes, it doesn't actually make sense to restrict this plugin to certain
filetypes,
since be default it will only be loaded for csv plugins.

That small additional amount in the plugin dir isn't worth the effort.

Best,
Christian

Owner

chrisbra commented Nov 18, 2014

Am 2014-11-17 00:07, schrieb Spencer Boucher:

At first I thought it wasn't working, but then I changed

Plug 'chrisbra/csv.vim', {'for': 'csv'}

(which limits the plugin to just csv filetypes in the vim-plug
manager, to a plain

Plug 'christbra/csv.vim'

and now it seems to work just fine. Thanks! Great plugin.

Yes, it doesn't actually make sense to restrict this plugin to certain
filetypes,
since be default it will only be loaded for csv plugins.

That small additional amount in the plugin dir isn't worth the effort.

Best,
Christian

@chrisbra chrisbra closed this Dec 31, 2014

vim-scripts added a commit to vim-scripts/csv.vim that referenced this issue Jan 16, 2015

Version 31
- fix that H on the very first cell, results in an endless loop (chrisbra/csv.vim#31, reported by lahvak, thanks!)- fix that count for |AddColumn| did not work (according to the documentation) (chrisbra/csv.vim#32, reported by lahvak, thanks!)- invalid reference to a WarningMsg() function- WhatColumn! error, if the first line did not contain as many fields as the line to check.- Rename |:Table| command to |:CSVTable| ( chrisbra/csv.vim#33, reported by Peter Jaros, thanks!)- Mention to escape special characters when manually specifying the delimiter. chrisbra/csv.vim#35), also detect '^' as delimiter.- Csv fixed with columns better use '\%v' to match columns, otherwise, one could get problems with multibyte chars- Sorting should work better with csv fixed with patterns (could generate an inavlide pattern before)- Refactor GetSID() (provided by Ingo Karkat chrisbra/csv.vim#37, thanks!)- New public function |CSVSum()|- Restrict |csv-arrange-autocmd| to specific file sizes (suggested by Spencer Boucher in chrisbra/csv.vim#39, thanks!)- Make |:CSVSearchInColumn| wrap pattern in '%\(..\)' pairs, so it works correctly with '\|' atoms- Small improvements on |:CSVTable| and |:NewDelimiter| command- <Up> and <Down> should skip folds (like in normal Vi mode, suggested by  Kamaraju Kusuma, thanks!)(automatically uploaded)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment