Trying to fold content so the 'method definition' / 'explanatory' lines are all showing regardless of depth, and the content between them is folded.
Folding examples on the wikis and in tutorials all seem to fold by nested depth.
Example code:
# RSpec code example
# '...' represents many lines of content
...
context 'depth 0' do
...
context 'depth 1' do
...
it 'depth 2' do
...
end
end
...
end
Folding with syntax matching, foldlevel=1 will give:
# RSpec code example
# '...' represents many lines
...
context 'depth 0' do
...
+-- 66 lines: context 'depth 1' do {--------------------------
...
end
Trying to fold away the content ...
, how do I get:
# RSpec code example
# '...' represents many lines of content
+-- MANY lines: ... {--------------------------
context 'depth 0' do
+-- MANY lines: ... {--------------------------
context 'depth 1' do
+-- MANY lines: ... {--------------------------
it 'depth 2' do
+-- MANY lines: ... {--------------------------