From f4571ce18e9d7db7303dfff9847c783331a5be67 Mon Sep 17 00:00:00 2001 From: jbranchaud Date: Sun, 3 Apr 2016 22:12:24 -0500 Subject: [PATCH] Add Load A Directory Of Files Into The Buffer List as a vim til --- README.md | 3 ++- ...directory-of-files-into-the-buffer-list.md | 19 +++++++++++++++++++ 2 files changed, 21 insertions(+), 1 deletion(-) create mode 100644 vim/load-a-directory-of-files-into-the-buffer-list.md diff --git a/README.md b/README.md index b29ea9b..bca8815 100644 --- a/README.md +++ b/README.md @@ -7,7 +7,7 @@ variety of languages and technologies. These are things that don't really warrant a full blog post. These are mostly things I learn by pairing with smart people at [Hashrocket](http://hashrocket.com/). -_382 TILs and counting..._ +_383 TILs and counting..._ --- @@ -414,6 +414,7 @@ _382 TILs and counting..._ - [Jump To The Next Misspelling](vim/jump-to-the-next-misspelling.md) - [List All Buffers](vim/list-all-buffers.md) - [List Of Plugins](vim/list-of-plugins.md) +- [Load A Directory Of Files Into The Buffer List](vim/load-a-directory-of-files-into-the-buffer-list.md) - [Match The Beginning And End Of Words](vim/match-the-beginning-and-end-of-words.md) - [Marks Across Vim Sessions](vim/marks-across-vim-sessions.md) - [Moving To A Specific Line](vim/moving-to-a-specific-line.md) diff --git a/vim/load-a-directory-of-files-into-the-buffer-list.md b/vim/load-a-directory-of-files-into-the-buffer-list.md new file mode 100644 index 0000000..1b63e05 --- /dev/null +++ b/vim/load-a-directory-of-files-into-the-buffer-list.md @@ -0,0 +1,19 @@ +# Load A Directory Of Files Into The Buffer List + +Consider the scenario where I want to go through all files in a directory to +make a series of minor, related changes. After editing each file, I can type +something like `:e path/to/next/file.md` to bring up the next file. That can +get a bit tedious though. Instead, I can load up all the files in the +directory with the `args` command: + +``` +:args path/to/files/*.md +``` + +From there, I can use `:bnext` (or `:bn) and `:bprev` to more quickly jump +through those files I want to edit. + +I can also run `:ls` to see all the files loaded in to the buffer list at +that point. + +[source](http://superuser.com/questions/396481/how-to-load-multiple-files-in-multiple-subdirectories-into-vim-buffers)