Timeline for how to loop through list of files?
Current License: CC BY-SA 4.0
16 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Dec 22, 2020 at 4:13 | history | rollback | alec |
Rollback to Revision 1
|
|
Dec 20, 2020 at 19:25 | comment | added | alec | @filbranden great thanks. I'll do as you suggest once I'm able to mentally process the comments! | |
Dec 20, 2020 at 19:05 | vote | accept | alec | ||
Dec 20, 2020 at 17:40 | comment | added | filbranden | You could also turn it around and make it about "Does Vimwiki support a feature to accomplish this thing I'm trying to do?" It's quite possible something like that already exists... Also, some Vimwiki authors/contributors/maintainers hang around here and might give you great advice on how to best accomplish what you want in Vimwiki... | |
Dec 20, 2020 at 17:38 | comment | added | filbranden |
It seems you have some basic misconceptions on how Vimscript works, for instance you can't really call a function such as substitute() just like that, Vim thinks you're trying to use the :substitute (commonly used as :%s/oldtext/newtext/ ) since that's how Vimscript works (it executes Ex commands.) If you feel like you should learn Vimscript better (to help you accomplish what you're trying to do here), I strongly suggest the excellent "Learn Vimscript the Hard Way".
|
|
Dec 20, 2020 at 17:35 | comment | added | filbranden |
Your question was originally about List required and I think @Matt's answer addressed that. Editing the question to make it about the next thing blocking you is not great (particularly once an answer addresses that)... Would you please edit it back to make about that (exclusively)? Then post a new question about the actual problem you're trying to solve. Thanks!
|
|
Dec 20, 2020 at 17:30 | comment | added | Christian Brabandt |
are you looking for :argdir in conjunction with :%s ? Perhaps it is easier to load all matching files into the quickfix window and then use :cfdo :%s etc.
|
|
Dec 20, 2020 at 16:58 | comment | added | B Layer |
Did you visually examine the generated list of paths? Sometimes it's not what you expect. Also, using ~ in vim may not work as expected for certain use cases. You may need to expand() it. (Or use $HOME or the full typed out path.)
|
|
Dec 20, 2020 at 16:16 | comment | added | alec | @filbranden I updated the question to clarify this. thanks for your time :) | |
Dec 20, 2020 at 15:56 | history | edited | alec | CC BY-SA 4.0 |
added 60 characters in body
|
Dec 20, 2020 at 14:45 | history | became hot network question | |||
Dec 20, 2020 at 14:13 | history | edited | alec | CC BY-SA 4.0 |
edited title
|
Dec 20, 2020 at 13:40 | history | edited | alec | CC BY-SA 4.0 |
added 1382 characters in body
|
Dec 20, 2020 at 5:43 | answer | added | Matt | timeline score: 4 | |
Dec 20, 2020 at 5:31 | comment | added | filbranden |
By substitute , do you mean a :%s/oldtext/newtext/ command? If that's the case, you need to open the files into buffers... Please edit the question to clarify exactly what you want to do with the files (or the file names.)
|
|
Dec 20, 2020 at 4:30 | history | asked | alec | CC BY-SA 4.0 |