<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
<channel>
<title>Vifm Q&amp;A - Recent questions and answers</title>
<link>https://q2a.vifm.info/qa</link>
<description>Powered by Question2Answer</description>
<item>
<title>Answered: vifm --remote example with if then statement</title>
<link>https://q2a.vifm.info/2457/vifm-remote-example-with-if-then-statement?show=2458#a2458</link>
<description>&lt;p&gt;You can change the outer quotes to double quotes:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;vifm --remote +&quot;:if filetype('.') == 'dir' | echo 'Directory' | else | echo 'File' | endif&quot;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;If you're going to nest quotes, they need to be of a different kind or some kind of escaping is necessary.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2457/vifm-remote-example-with-if-then-statement?show=2458#a2458</guid>
<pubDate>Wed, 06 May 2026 13:11:24 +0000</pubDate>
</item>
<item>
<title>Answered: Integrating zoxide with vifm</title>
<link>https://q2a.vifm.info/2455/integrating-zoxide-with-vifm?show=2456#a2456</link>
<description>&lt;blockquote&gt;&lt;p&gt;This is more of an answer rather than a question.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Then I'll do a bit of a review and ask a question :)&lt;/p&gt;
&lt;blockquote&gt;&lt;pre&gt;&lt;code class=&quot;vim&quot;&gt;let $dir_name = fnameescape($Z_PICK)
cd $dir_name
&lt;/code&gt;&lt;/pre&gt;
&lt;/blockquote&gt;
&lt;p&gt;This breaks entering into directories that require escaping.  Either do &lt;code&gt;cd $Z_PICK&lt;/code&gt; or &lt;code&gt;execute 'cd' fnameescape($Z_PICK)&lt;/code&gt; (this variant can use a global variable like &lt;code&gt;g:z_pick&lt;/code&gt; instead to not affect environment).  Unlike in a shell, environment variables are expanded after parameter splitting.&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;I use zoxide to quickly jump to most recent directories which matches a substring.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;What if it guessed the directory incorrectly, just do another try?  Doesn't this mess up history so that &lt;code&gt;cd -&lt;/code&gt; and &lt;code&gt;$OLDPWD&lt;/code&gt; point to the path opened by mistake?&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2455/integrating-zoxide-with-vifm?show=2456#a2456</guid>
<pubDate>Sun, 03 May 2026 09:38:17 +0000</pubDate>
</item>
<item>
<title>Answered: copy transfer speed</title>
<link>https://q2a.vifm.info/2450/copy-transfer-speed?show=2451#a2451</link>
<description>&lt;p&gt;You can try disabling data synchronization in &lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/#vifm-%27iooptions%27&quot;&gt;&lt;code&gt;'iooptions'&lt;/code&gt;&lt;/a&gt;:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;set iooptions-=datasync
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Mind that unless keeping more data in RAM permits effective parallelisation of writes, Vifm's speed is closer to the real one (i.e., how fast data lands at the destination) and &lt;code&gt;dd&lt;/code&gt; shows how fast you can load things into RAM buffers (possibly at the cost of pushing useful data out of it).  There are &lt;code&gt;sync&lt;/code&gt; and &lt;code&gt;nocache&lt;/code&gt; parameters/options for &lt;code&gt;dd&lt;/code&gt; as well in case you want to perform more comparisons.&lt;/p&gt;
&lt;p&gt;&lt;code&gt;dd&lt;/code&gt; may also keep all data in the kernel without copying to/from application, Vifm doesn't do that, making it somewhat slower.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2450/copy-transfer-speed?show=2451#a2451</guid>
<pubDate>Wed, 22 Apr 2026 16:39:17 +0000</pubDate>
</item>
<item>
<title>Answered: Passing v:servername to script</title>
<link>https://q2a.vifm.info/2436/passing-v-servername-to-script?show=2437#a2437</link>
<description>&lt;p&gt;The &lt;code&gt;%{expression}&lt;/code&gt; syntax is specific to the &lt;code&gt;'statusline'&lt;/code&gt; option.  A mapping could insert it via expression register (&lt;code&gt;&amp;lt;c-r&amp;gt;=fnameescape(v:servername)&amp;lt;cr&amp;gt;&lt;/code&gt; in place of &lt;code&gt;&quot;%{v:servername}&quot;&lt;/code&gt;) or you could do&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;let $VIFM_SERVER_NAME = v:servername
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;in your &lt;code&gt;vifmrc&lt;/code&gt; and then just use &lt;code&gt;&quot;$VIFM_SERVER_NAME&quot;&lt;/code&gt;.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2436/passing-v-servername-to-script?show=2437#a2437</guid>
<pubDate>Sun, 29 Mar 2026 16:29:19 +0000</pubDate>
</item>
<item>
<title>Answered: all menus available</title>
<link>https://q2a.vifm.info/2434/all-menus-available?show=2435#a2435</link>
<description>&lt;ul&gt;
&lt;li&gt;&lt;code&gt;:apropos&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;:fileviewer&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;:filetype&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;:vifm&lt;/code&gt; (same as &lt;code&gt;:version&lt;/code&gt;).&lt;/li&gt;
&lt;/ul&gt;
&lt;blockquote&gt;&lt;p&gt;cnoreabbrev...........display noremap cmdline abbrevs&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Nope, the menu is the same as for &lt;code&gt;:cabbrev&lt;/code&gt;.&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;his[tory]..................display a menu with list of visited directories&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;The command displays various histories depending on its parameter.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2434/all-menus-available?show=2435#a2435</guid>
<pubDate>Thu, 26 Mar 2026 17:54:54 +0000</pubDate>
</item>
<item>
<title>Answered: Howto compare files ?</title>
<link>https://q2a.vifm.info/2432/howto-compare-files?show=2433#a2433</link>
<description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;Assuming that you want to compare files via Vim, the following can be used:&lt;/p&gt;
&lt;pre&gt;&lt;code class=&quot;vim&quot;&gt;&quot; use Vim to diff files
&quot; uses selection of the current pane when it contains more than one file
&quot; otherwise uses left pane file and right pane file keeping order inside Vim
command! diff : if selected() &amp;lt; 2
            \ |     if paneisat('right') &amp;amp;&amp;amp; paneisat('bottom')
            \ |         execute '!vim -d %%C %%c'
            \ |     else
            \ |         execute '!vim -d %%c %%C'
            \ |     endif
            \ | else
            \ |     execute '!vim -d %%f'
            \ | endif
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;I should actually add this to sample &lt;code&gt;vifmrc&lt;/code&gt;.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2432/howto-compare-files?show=2433#a2433</guid>
<pubDate>Tue, 24 Mar 2026 09:31:31 +0000</pubDate>
</item>
<item>
<title>Answered: Automatic switch between light and dark themes</title>
<link>https://q2a.vifm.info/2416/automatic-switch-between-light-and-dark-themes?show=2430#a2430</link>
<description>&lt;p&gt;I’m not sure how you switch between light and dark themes, but if you are able to set an environment variable while doing so, you could add the following to your Vifm config:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;if $IS_DARK_THEME == '1'
  colorscheme Default
else
  colorscheme dwmlight
endif
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2416/automatic-switch-between-light-and-dark-themes?show=2430#a2430</guid>
<pubDate>Mon, 16 Mar 2026 22:54:13 +0000</pubDate>
</item>
<item>
<title>Answered: Folder name with dot</title>
<link>https://q2a.vifm.info/2423/folder-name-with-dot?show=2424#a2424</link>
<description>&lt;p&gt;Sounds like you're using &lt;code&gt;{ext}&lt;/code&gt; in &lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/vifm-app.txt#vifm-%27viewcolumns%27&quot;&gt;&lt;code&gt;'viewcolumns'&lt;/code&gt;&lt;/a&gt;, while you want to use &lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/vifm-app.txt#vifm-%27sort%27&quot;&gt;&lt;code&gt;{fileext}&lt;/code&gt;&lt;/a&gt;.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2423/folder-name-with-dot?show=2424#a2424</guid>
<pubDate>Thu, 12 Mar 2026 10:29:35 +0000</pubDate>
</item>
<item>
<title>Answered: recall last selection</title>
<link>https://q2a.vifm.info/2419/recall-last-selection?show=2420#a2420</link>
<description>&lt;p&gt;3rd method: use a command-line range (mostly useful for searching in a single file/directory with &lt;code&gt;:.grep ...&lt;/code&gt;).&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;How to recall the lost selection (a bit like copen) after the grep command?&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Use &lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/#vifm-gs&quot;&gt;&lt;kbd&gt;gs&lt;/kbd&gt; key&lt;/a&gt; for this.  There is a similar &lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/vifm-app.txt#vifm-gv&quot;&gt;&lt;kbd&gt;gv&lt;/kbd&gt; key&lt;/a&gt;, but it restores only the last visually selected range, so not suitable for complex cases.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2419/recall-last-selection?show=2420#a2420</guid>
<pubDate>Mon, 09 Mar 2026 09:03:18 +0000</pubDate>
</item>
<item>
<title>Answered: Three Letter Marker for filter</title>
<link>https://q2a.vifm.info/2411/three-letter-marker-for-filter?show=2412#a2412</link>
<description>&lt;p&gt;The total number of filtered out files is the only statistics explicitly collected by the code.  Number of files excluded by a local filter can be derived in the code.  Even this information is not exposed other than via the &lt;code&gt;%x&lt;/code&gt; macro, so at the moment there is no way to display flags that you describe.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2411/three-letter-marker-for-filter?show=2412#a2412</guid>
<pubDate>Tue, 17 Feb 2026 10:02:02 +0000</pubDate>
</item>
<item>
<title>Answered: File/folder count on the bottom right corner</title>
<link>https://q2a.vifm.info/2402/file-folder-count-on-the-bottom-right-corner?show=2403#a2403</link>
<description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Macros in &lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/#vifm-%27rulerformat%27&quot;&gt;&lt;code&gt;'rulerformat'&lt;/code&gt;&lt;/a&gt; reflect number of entries in the current list, hence &lt;code&gt;..&lt;/code&gt; (not sure why it's &lt;code&gt;.&lt;/code&gt; on the screenshot) is counted when present.&lt;/p&gt;
&lt;p&gt;You can hide &lt;code&gt;..&lt;/code&gt; by changing &lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/vifm-app.txt#vifm-%27dotdirs%27&quot;&gt;&lt;code&gt;'dotdirs'&lt;/code&gt;&lt;/a&gt; which will affect number of entries.&lt;/p&gt;
&lt;p&gt;Affecting the count while keeping the entry will take adding new macros (although not really sure what to do about tree-views with multiple &lt;code&gt;..&lt;/code&gt; entries) or allowing formatting &lt;code&gt;'rulerformat'&lt;/code&gt; in Lua.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2402/file-folder-count-on-the-bottom-right-corner?show=2403#a2403</guid>
<pubDate>Wed, 11 Feb 2026 22:35:53 +0000</pubDate>
</item>
<item>
<title>Answered: synchronize vifm with Xviewer</title>
<link>https://q2a.vifm.info/2395/synchronize-vifm-with-xviewer?show=2396#a2396</link>
<description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;&lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/linuxmint/xviewer&quot;&gt;This&lt;/a&gt; Xviewer?  I don't see it's documentation, but &lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/linuxmint/xviewer/blob/03f76f23cd8a55a302a9114582d8832523566b71/src/main.c#L61-L71&quot;&gt;this list of options&lt;/a&gt; doesn't look promising.  It apparently supports plugins, so maybe that interface could be used (by way of writing a plugin).&lt;/p&gt;
&lt;p&gt;In general for this to work you need to somehow communicate cursor position back to Vifm.  A viewer needs to expose this information and then it should be sent/returned to Vifm.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2395/synchronize-vifm-with-xviewer?show=2396#a2396</guid>
<pubDate>Tue, 10 Feb 2026 23:00:15 +0000</pubDate>
</item>
<item>
<title>Answered: behavior Enter Key</title>
<link>https://q2a.vifm.info/2392/behavior-enter-key?show=2393#a2393</link>
<description>&lt;p&gt;Seems like you're just closing the active window (terminal) in both cases.  You can map &lt;code&gt;&amp;lt;cr&amp;gt;&lt;/code&gt; similarly:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;nnoremap &amp;lt;cr&amp;gt; : if filetype('.', 1) == 'dir'
            \ |     open
            \ | else
            \ |     execute '!'.$VIFM_TERMINAL 'vim %c &amp;amp;'
            \ | endif&amp;lt;cr&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;An alternative is changing &lt;code&gt;'vicmd'&lt;/code&gt; option, but there a script may be necessary to keep everything working as expected.&lt;/p&gt;
&lt;p&gt;Edit: added &lt;code&gt;1&lt;/code&gt; parameter to resolve symbolic links.&lt;/p&gt;
&lt;p&gt;Edit 2: &lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/vifm/vifm/commit/9cf8260accd8250c822e2edaa5e9795da3735e3b&quot;&gt;this change&lt;/a&gt; fixes &lt;code&gt;:open&lt;/code&gt; for symbolic links to directories when &lt;code&gt;vifm&lt;/code&gt; is not present in &lt;code&gt;$PATH&lt;/code&gt;.  Until then, use &lt;code&gt;cd %c&lt;/code&gt; as a functionally-equivalent workaround.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2392/behavior-enter-key?show=2393#a2393</guid>
<pubDate>Thu, 22 Jan 2026 13:46:55 +0000</pubDate>
</item>
<item>
<title>Answered: open file with the second filetype command from :file</title>
<link>https://q2a.vifm.info/2385/open-file-with-the-second-filetype-command-from-file?show=2386#a2386</link>
<description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;There is a &lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/#vifm-%3Afile&quot;&gt;form of :file&lt;/a&gt; which accepts prefix of a command  to run.  Not the same as position from the top, but the purpose is similar: to pick non-default handler.  As an example, &lt;code&gt;:file so&lt;/code&gt; opens &lt;code&gt;soffice %c&lt;/code&gt; for a PDF file in case of the following configuration:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;filextype *.pdf zathura %f %i &amp;amp;, apvlv %c, xpdf %c, soffice %c
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2385/open-file-with-the-second-filetype-command-from-file?show=2386#a2386</guid>
<pubDate>Sun, 04 Jan 2026 13:31:43 +0000</pubDate>
</item>
<item>
<title>Answered: Zoom preview window</title>
<link>https://q2a.vifm.info/2382/zoom-preview-window?show=2383#a2383</link>
<description>&lt;p&gt;The reason is that quickview is tied to the other pane, so that pane is kept visible.  This behaviour dates back when one couldn't focus a quickview and enter view mode, so maybe &lt;kbd&gt;Ctrl+W o&lt;/kbd&gt; could be permitted in this case with the other pane being shown automatically on exiting view mode.&lt;/p&gt;
&lt;p&gt;By the way, there is also &lt;kbd&gt;Ctrl+W |&lt;/kbd&gt; to maximize a window.  &quot;explore&quot; view (after &lt;kbd&gt;e&lt;/kbd&gt;) can also be used in the only mode.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2382/zoom-preview-window?show=2383#a2383</guid>
<pubDate>Sat, 03 Jan 2026 11:36:00 +0000</pubDate>
</item>
<item>
<title>Answered: Locked (permanent) tabs</title>
<link>https://q2a.vifm.info/2372/locked-permanent-tabs?show=2380#a2380</link>
<description>&lt;blockquote&gt;&lt;p&gt;Navigating from a &quot;locked&quot; tab automatically creates a new one.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Seems like this feature is meant for pane-level tabs and wouldn't fit global tabs.  I might have even used it in some file manager, but it didn't really suit my workflow.  It sounds kinda simple to do, but I'm sure there are various corner cases.&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;Admittedly, the functionality is &lt;em&gt;somewhat&lt;/em&gt; similar to marks, but feels less rigid as it does not require editing the config.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Marks also don't require editing the config and can survive a restart.  Just add &lt;code&gt;bmarks&lt;/code&gt; to the value of &lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/vifm-app.txt#vifm-%27vifminfo%27&quot;&gt;'vifminfo' option&lt;/a&gt;.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2372/locked-permanent-tabs?show=2380#a2380</guid>
<pubDate>Thu, 01 Jan 2026 23:31:23 +0000</pubDate>
</item>
<item>
<title>Answered: Show only symlinks</title>
<link>https://q2a.vifm.info/2373/show-only-symlinks?show=2377#a2377</link>
<description>&lt;p&gt;This should do it:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;command! LnOnly find . -t l -H --max-depth=1 %u
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;You can also press &lt;kbd&gt;b&lt;/kbd&gt; key in a menu to turn it into a list of files (limited to menus that present such lists).&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2373/show-only-symlinks?show=2377#a2377</guid>
<pubDate>Thu, 01 Jan 2026 18:31:03 +0000</pubDate>
</item>
<item>
<title>Answered: Hide progress dialogue</title>
<link>https://q2a.vifm.info/2371/hide-progress-dialogue?show=2375#a2375</link>
<description>&lt;p&gt;There is no way to hide the dialog after it's open.  This isn't related to &lt;code&gt;'uioptions'&lt;/code&gt;, showing it by pressing &lt;kbd&gt;i&lt;/kbd&gt; works the same.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2371/hide-progress-dialogue?show=2375#a2375</guid>
<pubDate>Thu, 01 Jan 2026 11:42:29 +0000</pubDate>
</item>
<item>
<title>Answered: show UID only</title>
<link>https://q2a.vifm.info/2354/show-uid-only?show=2360#a2360</link>
<description>&lt;p&gt;That's not how &lt;code&gt;uid&lt;/code&gt; is supposed to work, the behaviour you see is a bug.  Thanks for bringing this up.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2354/show-uid-only?show=2360#a2360</guid>
<pubDate>Sun, 28 Dec 2025 17:15:48 +0000</pubDate>
</item>
<item>
<title>Answered: Image preview issue in vifm after upgrading kitty</title>
<link>https://q2a.vifm.info/2349/image-preview-issue-in-vifm-after-upgrading-kitty?show=2357#a2357</link>
<description>&lt;p&gt;The &lt;a rel=&quot;nofollow&quot; href=&quot;https://sw.kovidgoyal.net/kitty/changelog/#detailed-list-of-changes&quot;&gt;list of changes&lt;/a&gt; for v0.43 mentions:&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;A new protocol for multiple cursors in the terminal (#8927)&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;I would think it may be related, but there are a few other things that look suspicious.  This may need bisecting differences between v0.42.2 and v0.43.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2349/image-preview-issue-in-vifm-after-upgrading-kitty?show=2357#a2357</guid>
<pubDate>Sun, 28 Dec 2025 17:00:19 +0000</pubDate>
</item>
<item>
<title>Answered: prompt sudo password</title>
<link>https://q2a.vifm.info/2347/prompt-sudo-password?show=2351#a2351</link>
<description>&lt;p&gt;I worked around that with this custom configuration&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;nnoremap &amp;lt;c-s&amp;gt; :!sudo -E vifm %c&amp;lt;cr&amp;gt;
if system('whoami') == &quot;root&quot;
  hi StatusLine guifg=#fb4934
endif
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2347/prompt-sudo-password?show=2351#a2351</guid>
<pubDate>Mon, 22 Dec 2025 14:21:38 +0000</pubDate>
</item>
<item>
<title>Answered: Different font for text and icons</title>
<link>https://q2a.vifm.info/2326/different-font-for-text-and-icons?show=2327#a2327</link>
<description>&lt;p&gt;Fonts are configured in a terminal emulator.  I don't remember seeing a way to specify a font from an application and if there is one, it's unlikely to be possible to use more than one font at a time (their metrics would have to match or be adjusted on the fly in order for this to have a chance to work).&lt;/p&gt;
&lt;p&gt;If JetBrains Mono has some icons, JetBrainsMono Nerd Font may use different (potentially bigger) glyphs for them.  Otherwise you would probably have to combine fonts or edit one with FontForge or a similar application to scale/replace glyphs.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2326/different-font-for-text-and-icons?show=2327#a2327</guid>
<pubDate>Mon, 08 Dec 2025 17:41:57 +0000</pubDate>
</item>
<item>
<title>Answered: fileviewer: catchall for readable and non-readable files</title>
<link>https://q2a.vifm.info/2323/fileviewer-catchall-for-readable-and-non-readable-files?show=2324#a2324</link>
<description>&lt;p&gt;You could use mimetypes for that, but they won't always give an expected result.  For example, you list &lt;code&gt;.py&lt;/code&gt;-files as unreadable, but their mimetype is &lt;code&gt;text/x-script.python&lt;/code&gt;.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&quot; non-directory with a mimetype starting with &quot;text/&quot;
fileviewer {*[^/]}&amp;lt;text/*&amp;gt; text-file-handler

&quot; non-directory with a mimetype not starting with &quot;text/&quot;
fileviewer {*[^/]}!&amp;lt;text/*&amp;gt; non-text-file-handler
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2323/fileviewer-catchall-for-readable-and-non-readable-files?show=2324#a2324</guid>
<pubDate>Thu, 04 Dec 2025 17:50:08 +0000</pubDate>
</item>
<item>
<title>Answered: selects files/folders matching a pattern</title>
<link>https://q2a.vifm.info/2313/selects-files-folders-matching-a-pattern?show=2315#a2315</link>
<description>&lt;p&gt;Use &lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/#vifm-%3Aselect&quot;&gt;:select command&lt;/a&gt;:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;select *.jpg
select *part* &quot; or select /part/
&quot; jpg or png files that don't contain &quot;to&quot; substring
select {*.jpg,*.png}!/to/
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The patterns are like in &lt;code&gt;:filetype&lt;/code&gt;.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2313/selects-files-folders-matching-a-pattern?show=2315#a2315</guid>
<pubDate>Wed, 26 Nov 2025 18:36:15 +0000</pubDate>
</item>
<item>
<title>Answered: add automatic increasing numbering to a list of files/folders</title>
<link>https://q2a.vifm.info/2312/add-automatic-increasing-numbering-to-list-of-files-folders?show=2314#a2314</link>
<description>&lt;p&gt;I can't think of a way to do that without using Vim via &lt;code&gt;:rename&lt;/code&gt;.  There you can add numbers (e.g., &lt;code&gt;:%s/^/1/&lt;/code&gt;), select a column of numbers visually with &lt;kbd&gt;Ctrl-V&lt;/kbd&gt; and do &lt;kbd&gt;g&lt;/kbd&gt;&lt;kbd&gt;Ctrl-A&lt;/kbd&gt;.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2312/add-automatic-increasing-numbering-to-list-of-files-folders?show=2314#a2314</guid>
<pubDate>Wed, 26 Nov 2025 18:32:27 +0000</pubDate>
</item>
<item>
<title>Answered: flat view - files starting with dot</title>
<link>https://q2a.vifm.info/2309/flat-view-files-starting-with-dot?show=2310#a2310</link>
<description>&lt;p&gt;&lt;code&gt;%u&lt;/code&gt; doesn't filter out anything.  From &lt;a rel=&quot;nofollow&quot; href=&quot;https://man.archlinux.org/man/fd.1&quot;&gt;man fd&lt;/a&gt;:&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;By default fd will exclude hidden files and directories, as well as any files that match gitignore rules or ignore rules in .ignore or .fdignore files.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;So you want to add &lt;code&gt;-u&lt;/code&gt; or &lt;code&gt;-H&lt;/code&gt; flag to your command.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2309/flat-view-files-starting-with-dot?show=2310#a2310</guid>
<pubDate>Wed, 26 Nov 2025 13:10:41 +0000</pubDate>
</item>
<item>
<title>Answered: macro for custom view</title>
<link>https://q2a.vifm.info/2302/macro-for-custom-view?show=2303#a2303</link>
<description>&lt;p&gt;When inside of a custom view, &lt;code&gt;%d&lt;/code&gt; is expanded to the root of the view which may not correspond to the directory where a file is located.  Which directory path do you want to get in the end?  If it's where the file is, &lt;code&gt;%c:p:h&lt;/code&gt; should do, but the way you describe it is as if you want &lt;code&gt;%d&lt;/code&gt; exactly how it's expanded.  Please clarify.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2302/macro-for-custom-view?show=2303#a2303</guid>
<pubDate>Sun, 23 Nov 2025 14:07:59 +0000</pubDate>
</item>
<item>
<title>Answered: shortcut for relativenumber</title>
<link>https://q2a.vifm.info/2289/shortcut-for-relativenumber?show=2290#a2290</link>
<description>&lt;p&gt;That's possible.  Key's count is available in &lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/#vifm-v%3Acount&quot;&gt;v:count&lt;/a&gt; and &lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/#vifm-v%3Acount1&quot;&gt;v:count1&lt;/a&gt;, which together with &lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/vifm-app.txt#vifm-%3Aexecute&quot;&gt;:execute&lt;/a&gt; and &lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/vifm-app.txt#vifm-%3Aopen&quot;&gt;:open&lt;/a&gt; can do what you want using a relative position to go to a specific line (&lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/vifm-app.txt#vifm-%3Arange&quot;&gt;see&lt;/a&gt;):&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;nnoremap &amp;lt;silent&amp;gt; u :&amp;lt;c-u&amp;gt;execute '.-'.v:count '| open'&amp;lt;cr&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;kbd&gt;Ctrl-U&lt;/kbd&gt; is there to get rid of the range inserted if doing something like &lt;kbd&gt;10:&lt;br&gt;
&lt;/kbd&gt;.  Change &lt;code&gt;-&lt;/code&gt; to &lt;code&gt;+&lt;/code&gt; to move down:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;nnoremap &amp;lt;silent&amp;gt; U :&amp;lt;c-u&amp;gt;execute '.+'.v:count '| open'&amp;lt;cr&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2289/shortcut-for-relativenumber?show=2290#a2290</guid>
<pubDate>Thu, 06 Nov 2025 12:18:50 +0000</pubDate>
</item>
<item>
<title>Answered: Blink cursor</title>
<link>https://q2a.vifm.info/2285/blink-cursor?show=2288#a2288</link>
<description>&lt;p&gt;You could try a different colorscheme: &lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/vifm/vifm-colors&quot;&gt;https://github.com/vifm/vifm-colors&lt;/a&gt;&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2285/blink-cursor?show=2288#a2288</guid>
<pubDate>Mon, 03 Nov 2025 14:35:17 +0000</pubDate>
</item>
<item>
<title>Answered: proposition for improving message : 1 file inserted</title>
<link>https://q2a.vifm.info/2278/proposition-for-improving-message-1-file-inserted?show=2287#a2287</link>
<description>&lt;p&gt;I have noticed the same issue. When I yank a file and then later use the &lt;code&gt;p&lt;/code&gt; or the &lt;code&gt;P&lt;/code&gt; key (see &lt;code&gt;:help vifm-p&lt;/code&gt;), I am often a bit unsure if I hit the correct key, because the same message is displayed: &lt;code&gt;1 file inserted&lt;/code&gt;.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2278/proposition-for-improving-message-1-file-inserted?show=2287#a2287</guid>
<pubDate>Mon, 03 Nov 2025 14:23:56 +0000</pubDate>
</item>
<item>
<title>Open vifm with multiple tabs</title>
<link>https://q2a.vifm.info/2284/open-vifm-with-multiple-tabs</link>
<description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;In case anyone wants to open a specified set of tabs when opening vifm but doesn't want to duplicate them when reloading&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&quot; Open vifm with three tabs per pane. The first tab of each pane is in current
&quot; directory. Remaining are home directory.
&quot;-------------------------------------------------------------------------------
if tabpagenr(&quot;$&quot;) == 1
    windo tabnew
    cd ~ ~
    windo tabnew
    cd ~ ~
    tabnext 1
    winc w
    tabnext 1
    winc w
endif
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2284/open-vifm-with-multiple-tabs</guid>
<pubDate>Tue, 28 Oct 2025 14:59:51 +0000</pubDate>
</item>
<item>
<title>Sync tabs (like :sync for panes)</title>
<link>https://q2a.vifm.info/2283/sync-tabs-like-sync-for-panes</link>
<description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I added commands to my &lt;code&gt;$MYVIFMRC&lt;/code&gt; that can synchronize the view of the next tab to the current pane's directory or directory under the current cursor. Just posting it here in case it's useful for anyone else and in case anyone wants to suggest another alternative.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&quot; Sync next tab to current directory
command! TabSync : let $DIR_CUR = &quot;%d&quot;
                \| tabnext
                \| cd &quot;$DIR_CUR&quot;
                \| tabprev
nnoremap &amp;lt;a-u&amp;gt; :TabSync&amp;lt;cr&amp;gt;
&quot; Sync next tab to directory under cursor
command! TabSyncCursor : let $DIR_CUR = &quot;%c&quot;
                      \| tabnext
                      \| cd &quot;$DIR_CUR&quot;
                      \| tabprev
nnoremap &amp;lt;a-p&amp;gt; :TabSyncCursor&amp;lt;cr&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;I use it in combination with other &lt;code&gt;sync&lt;/code&gt; keymaps like below:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;&quot; Sync other pane to current directory
nnoremap &amp;lt;a-i&amp;gt; :sync&amp;lt;cr&amp;gt;
&quot; Sync other pane to directory under cursor
nnoremap &amp;lt;a-o&amp;gt; :sync %c&amp;lt;cr&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2283/sync-tabs-like-sync-for-panes</guid>
<pubDate>Tue, 28 Oct 2025 14:45:38 +0000</pubDate>
</item>
<item>
<title>Answered: catch-all preview</title>
<link>https://q2a.vifm.info/2280/catch-all-preview?show=2282#a2282</link>
<description>&lt;p&gt;Looks correct to me, although you may want to change &lt;code&gt;&amp;lt;text/plain&amp;gt;&lt;/code&gt; to &lt;code&gt;&amp;lt;text/*&amp;gt;&lt;/code&gt;.  It's also possible that some application-specific mime types need to be listed, you can look those up in &lt;kbd&gt;Ctrl+G&lt;/kbd&gt; dialog when a file isn't previewed as you expect.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2280/catch-all-preview?show=2282#a2282</guid>
<pubDate>Tue, 28 Oct 2025 13:52:34 +0000</pubDate>
</item>
<item>
<title>Answered: File highlight broken?</title>
<link>https://q2a.vifm.info/2275/file-highlight-broken?show=2276#a2276</link>
<description>&lt;p&gt;Highlighting based on file type has higher priority than highlighting based on file name/mime.  You probably copied those files from a FAT or other Windows drive and they have executable bit set.  Try running &lt;code&gt;:chmod -x&lt;/code&gt; with one of those files under the cursor.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2275/file-highlight-broken?show=2276#a2276</guid>
<pubDate>Fri, 10 Oct 2025 16:00:00 +0000</pubDate>
</item>
<item>
<title>Answered: Open .xlsx file with sc-im</title>
<link>https://q2a.vifm.info/2270/open-xlsx-file-with-sc-im?show=2271#a2271</link>
<description>&lt;p&gt;My Vifm opens &lt;code&gt;.xlsx&lt;/code&gt; files with sc-im as expected. My configuration file contains the following line:&lt;/p&gt;
&lt;pre&gt;&lt;code class=&quot;vim&quot;&gt;filextype {*.xls,*.xlsx,*.ods} sc-im %f
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Maybe the &lt;code&gt;&amp;amp;&lt;/code&gt; is causing your issue?&lt;/p&gt;
&lt;p&gt;Which application appears first when running &lt;code&gt;:file&lt;/code&gt;, sc-im or&lt;br&gt;
LibreOffice?&lt;br&gt;
Do you get the same &lt;code&gt;Background Process Error: Device not configured&lt;/code&gt; error when you manually select sc-im from the &lt;code&gt;:file&lt;/code&gt; menu?&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2270/open-xlsx-file-with-sc-im?show=2271#a2271</guid>
<pubDate>Mon, 06 Oct 2025 07:38:44 +0000</pubDate>
</item>
<item>
<title>Answered: Filter by file permission</title>
<link>https://q2a.vifm.info/2267/filter-by-file-permission?show=2268#a2268</link>
<description>&lt;p&gt;No internal means for that, but custom view could be used to do such filtering:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;command! perm :select * | !stat -c'%%%%A/%%%%n' %%f | grep '^.%a' | cut -d/ -f1 --complement %%u

perm rwx
perm .w.
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2267/filter-by-file-permission?show=2268#a2268</guid>
<pubDate>Thu, 02 Oct 2025 13:26:13 +0000</pubDate>
</item>
<item>
<title>Answered: Look behind in filetype regex pattern.</title>
<link>https://q2a.vifm.info/2264/look-behind-in-filetype-regex-pattern?show=2265#a2265</link>
<description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;Yes, POSIX regexps (&lt;code&gt;man 7 regex&lt;/code&gt;) don't have positive/negative look behind/ahead, but you can still achieve the desired effect in Vifm.  You even almost got it, just drop the comma:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;filetype {*.tar.gz} command-1
filetype {*.gz}!{*.tar.gz} command-2
&lt;/code&gt;&lt;/pre&gt;
&lt;hr&gt;
&lt;p&gt;&lt;code&gt;filetype {a},{b} command&lt;/code&gt; is just a shorthand for&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;filetype {a} command
filetype {b} command
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;That's basically a disjunction (logical OR).  &lt;code&gt;filetype {a}{b} command&lt;/code&gt;, on the other hand, is a conjunction (logical AND) of 2 patterns each of which can be negated individually.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2264/look-behind-in-filetype-regex-pattern?show=2265#a2265</guid>
<pubDate>Mon, 29 Sep 2025 12:48:14 +0000</pubDate>
</item>
<item>
<title>Answered: cp -n warning popup</title>
<link>https://q2a.vifm.info/2262/cp-n-warning-popup?show=2263#a2263</link>
<description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;Thanks for your kind words and bringing this to my attention, I wasn't aware coreutils had this change of behaviour and a new warning.  Will have to take it into account.&lt;/p&gt;
&lt;p&gt;Adding &lt;code&gt;set syscalls&lt;/code&gt; (&lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/vifm-app.txt#vifm-%27syscalls%27&quot;&gt;docs&lt;/a&gt;) to your configuration should address the issue by not using &lt;code&gt;cp&lt;/code&gt; for copying.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2262/cp-n-warning-popup?show=2263#a2263</guid>
<pubDate>Sat, 13 Sep 2025 21:38:23 +0000</pubDate>
</item>
<item>
<title>Answered: Unsuccessful key binding (F3 and F4 keys)</title>
<link>https://q2a.vifm.info/2258/unsuccessful-key-binding-f3-and-f4-keys?show=2259#a2259</link>
<description>&lt;p&gt;I'm not sure what &lt;code&gt;xterm-color&lt;/code&gt; terminfo entry is for and why it's defined this way, but it uses definitions of functional keys that don't match what XTerm is actually sending:&lt;/p&gt;
&lt;pre&gt;&lt;code class=&quot;bash&quot;&gt;[~]$ infocmp xterm-color xterm-256color | grep 'kf[34]:'
        kf3: '\E[13~', '\EOR'.
        kf4: '\E[14~', '\EOS'.
[~]$ Ctrl+V F3: ^[OR
[~]$ Ctrl+V F4: ^[OS
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Using &lt;code&gt;xterm&lt;/code&gt; or &lt;code&gt;xterm-256color&lt;/code&gt; should work fine.  There may be a configuration option for XTerm which makes it compatible with &lt;code&gt;xterm-color&lt;/code&gt;.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2258/unsuccessful-key-binding-f3-and-f4-keys?show=2259#a2259</guid>
<pubDate>Sat, 06 Sep 2025 10:44:45 +0000</pubDate>
</item>
<item>
<title>Answered: How to expand macros when adding bookmarks</title>
<link>https://q2a.vifm.info/2251/how-to-expand-macros-when-adding-bookmarks?show=2254#a2254</link>
<description>&lt;p&gt;If I understood you correctly:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;nnoremap &amp;lt;silent&amp;gt; B :execute 'bmark!' '%c' expand('%c')&amp;lt;cr&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2251/how-to-expand-macros-when-adding-bookmarks?show=2254#a2254</guid>
<pubDate>Sat, 30 Aug 2025 10:09:57 +0000</pubDate>
</item>
<item>
<title>Answered: How to 'detatch' an edit?</title>
<link>https://q2a.vifm.info/2235/how-to-detatch-an-edit?show=2236#a2236</link>
<description>&lt;p&gt;Try this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;nnoremap &amp;lt;silent&amp;gt; ,C :write | execute '!foot nvim $MYVIFMRC' | restart full&amp;lt;cr&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;&lt;code&gt;execute&lt;/code&gt; isn't a function, so no need for parenthesis.  It runs command-line command, so you want &lt;code&gt;!&lt;/code&gt; to run an external command.  &lt;code&gt;:execute&lt;/code&gt; is needed to allow running &lt;code&gt;:restart&lt;/code&gt; after a &lt;code&gt;|&lt;/code&gt;, otherwise it would be passed to a shell.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2235/how-to-detatch-an-edit?show=2236#a2236</guid>
<pubDate>Mon, 18 Aug 2025 12:22:09 +0000</pubDate>
</item>
<item>
<title>Answered: How to `ga` or `gA` every file and directory on open?</title>
<link>https://q2a.vifm.info/2227/how-to-ga-or-ga-every-file-and-directory-on-open?show=2229#a2229</link>
<description>&lt;pre&gt;&lt;code class=&quot;vifm&quot;&gt;command! size :normal ga
autocmd DirEnter * %size
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;This will work, but may consume a lot of memory if you change to something like &lt;code&gt;/&lt;/code&gt;.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2227/how-to-ga-or-ga-every-file-and-directory-on-open?show=2229#a2229</guid>
<pubDate>Sun, 17 Aug 2025 15:54:13 +0000</pubDate>
</item>
<item>
<title>Answered: How would one toggle an executable?</title>
<link>https://q2a.vifm.info/2223/how-would-one-toggle-an-executable?show=2224#a2224</link>
<description>&lt;p&gt;There is no &lt;code&gt;test&lt;/code&gt; command/function, need to use &lt;code&gt;system()&lt;/code&gt; for that:&lt;/p&gt;
&lt;pre&gt;&lt;code class=&quot;vim&quot;&gt;command togglex :
\|   if system(expand('test -x %%c &amp;amp;&amp;amp; echo x')) == 'x'
\|     chmod -x
\|   else
\|     chmod +x
\|   endif

nnoremap &amp;lt;silent&amp;gt; * :togglex&amp;lt;cr&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;blockquote&gt;&lt;p&gt;don't see any examples or questions about it&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Toggling a permission seems uncommon to me.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2223/how-would-one-toggle-an-executable?show=2224#a2224</guid>
<pubDate>Sun, 17 Aug 2025 10:20:18 +0000</pubDate>
</item>
<item>
<title>Answered: Archive mounts on macOS</title>
<link>https://q2a.vifm.info/2218/archive-mounts-on-macos?show=2219#a2219</link>
<description>&lt;blockquote&gt;&lt;p&gt;There is a macfuse kext, but Apple is currently trying to move such things into userspace.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;As long as it works, you can use it.&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;There is fuse-t, but it seems to only have fuse-zip, so there is no support for .rar or .7z files.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;macfuse and fuse-t don't implement custom file systems themselves, they only provide means for such implementations.  fuse-t should work with many existing FUSE implementations, they don't need to target it specifically.  For example, I think &lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/macos-fuse-t/fuse-t/issues/89&quot;&gt;here&lt;/a&gt; the same ntfs-3g installation was used with both macfuse and fuse-t.&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;Are there any other ways to do this?&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Not that I know of, but I know very little about macOS, so there may very well be other options.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2218/archive-mounts-on-macos?show=2219#a2219</guid>
<pubDate>Sat, 02 Aug 2025 12:39:53 +0000</pubDate>
</item>
<item>
<title>Answered: Questions about the Lua API</title>
<link>https://q2a.vifm.info/2215/questions-about-the-lua-api?show=2217#a2217</link>
<description>&lt;blockquote&gt;&lt;p&gt;1) Is the Lua API the only way to add a description to a key binding?&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;v0.15 will &lt;a rel=&quot;nofollow&quot; href=&quot;https://github.com/vifm/vifm/commit/20d3ddaa2305581b4ca8b6c76455232e8ee8d24f&quot;&gt;allow&lt;/a&gt; doing this without Lua as:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;nnoremap &amp;lt;help&amp;gt;&amp;lt;Space&amp;gt;r {edit file as root}:RootEditFile&amp;lt;CR&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Syntax is similar to that of &lt;code&gt;:file[x]type&lt;/code&gt; but requires &lt;code&gt;&amp;lt;help&amp;gt;&lt;/code&gt; for disambiguation, so ends up somewhat verbose.&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;2) According to the help file: &quot;Builtin &lt;code&gt;print()&lt;/code&gt; function puts messages to plugin's log (see |vifm-:plugins| menu).&quot; Where can I view these logs? Running &lt;code&gt;:plugins&lt;/code&gt; just shows a list of plugins. I've been using &lt;code&gt;vifm.sb.info('...')&lt;/code&gt; instead for logging, but that isn't ideal.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;You need to press &lt;kbd&gt;e&lt;/kbd&gt; to see the log.  Search for &lt;code&gt;Plugins (:plugins) menu&lt;/code&gt; in documentation (there is no tag for it, it's below &lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/vifm-app.txt#vifm-m_c&quot;&gt;this&lt;/a&gt;).&lt;/p&gt;
&lt;p&gt;You can simply do &lt;code&gt;print = vifm.sb.info&lt;/code&gt; to not have to open the menu while debugging.  It turned out to not be convenient, but allows to see messages from different plugins without mixing them up.&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;3) Is there something built-in to pretty-print tables? In Neovim you can do &lt;code&gt;:lua print( vim.inspect( tbl ) )&lt;/code&gt;.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;No, I think Lua itself doesn't offer anything for that and Vifm doesn't offer pretty-printing either.&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;4) A helper function like the following can pretty-print tables:&lt;/p&gt;
&lt;p&gt;How would one print, for example, &lt;code&gt;vifm.currview()&lt;/code&gt;, which is of type &lt;code&gt;Vifmview&lt;/code&gt;? I've also encountered the type &lt;code&gt;userdata&lt;/code&gt;.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;code&gt;Vifmview&lt;/code&gt; is also user data, but not a lighweight one (that one is reported as &lt;code&gt;userdata&lt;/code&gt;).  These types are implemented in C, although syntactically they can act similar to tables.&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;5) I expected there would be something like &lt;code&gt;vim.cmd()&lt;/code&gt; in Neovim, but if I understand correctly, it's impossible to call a built-in command like &lt;code&gt;:messages&lt;/code&gt; or &lt;code&gt;:normal! j&lt;/code&gt; from the Lua API? For the latter, there's an alternative (&lt;code&gt;local c = vifm.currview().cursor; c.pos = c.pos + 1&lt;/code&gt;), but for the former, there isn't?&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;There is intentionally no &lt;code&gt;vifm.cmd()&lt;/code&gt;, couple paragraphs on that are &lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/vifm-lua.txt#vifm-lua-design&quot;&gt;here&lt;/a&gt;.  It's easy to add but there is no way to guarantee proper escaping for arguments because :commands are too irregular in how they treat input.  In my experience with Vim plugins partially written in Python, that was a source of never ending issues and I see no solution.&lt;/p&gt;
&lt;p&gt;This does mean that an equivalent of each :command needs to be exposed to Lua in its own way and there isn't one for &lt;code&gt;:messages&lt;/code&gt;.&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;6) There isn't a way to run Lua from the Vifm command-line either, like &lt;code&gt;:lua print('foo')&lt;/code&gt; in Neovim?&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;No, for the same reason, although this can be implemented by a plugin:&lt;/p&gt;
&lt;pre&gt;&lt;code class=&quot;lua&quot;&gt;local function lua(info)
    local code = string.format('return tostring(%s)', info.args)
    local f, err = load(code, &quot;:Lua args&quot;)
    if f == nil then
        vifm.sb.error(&quot;Failed to compile arguments: &quot;..err)
    else
        vifm.sb.info(f())
    end
end

local function luaS(info)
    local f, err = load(info.args, &quot;:Lua args&quot;)
    if f == nil then
        vifm.sb.error(&quot;Failed to compile arguments: &quot;..err)
    else
        f()
    end
end

local added = vifm.cmds.add {
    name = &quot;Lua&quot;,
    description = &quot;evaluate and print a Lua expression&quot;,
    handler = lua,
    minargs = 1,
    maxargs = -1,
}
if not added then
    vifm.sb.error(&quot;Failed to register :Lua&quot;)
end

local added = vifm.cmds.add {
    name = &quot;LuaS&quot;,
    description = &quot;execute a Lua statement&quot;,
    handler = luaS,
    minargs = 1,
    maxargs = -1,
}
if not added then
    vifm.sb.error(&quot;Failed to register :LuaS&quot;)
end

return {}
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2215/questions-about-the-lua-api?show=2217#a2217</guid>
<pubDate>Fri, 01 Aug 2025 22:17:18 +0000</pubDate>
</item>
<item>
<title>Answered: The cmdline blinks when running long string map key than screen width</title>
<link>https://q2a.vifm.info/2207/the-cmdline-blinks-when-running-long-string-than-screen-width?show=2208#a2208</link>
<description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;Even without &lt;code&gt;&amp;lt;silent&amp;gt;&lt;/code&gt; I can't notice the effect in &lt;code&gt;xterm&lt;/code&gt; or &lt;code&gt;st&lt;/code&gt;, but it's barely visible in &lt;code&gt;vte&lt;/code&gt; sometimes (it's a sample terminal).   What's your terminal and Vifm version?  Terminal shouldn't make a difference here, but won't hurt to know it.&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;even adding &quot;silent&quot; parameter after nnoremap, it also doesn't work&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Are you sure you're not defining the mapping more than once?  You can try commenting out the part of &lt;code&gt;vifmrc&lt;/code&gt; you're editing to see whether the mapping is still available (e.g., &lt;code&gt;:nmap gT&lt;/code&gt;).&lt;/p&gt;
&lt;p&gt;Defining a helper :command could be a workaround:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;nnoremap gT :gT&amp;lt;cr&amp;gt;
command gT : if v:count == 0
          \|     execute 'normal gT'
          \| elseif v:count &amp;gt; tabpagenr('$')
          \|     tabmove
          \| elseif v:count &amp;gt;= tabpagenr()
          \|     execute 'tabmove' v:count
          \| elseif v:count &amp;lt; tabpagenr()
          \|     execute 'tabmove' v:count - 1
          \| endif
&lt;/code&gt;&lt;/pre&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2207/the-cmdline-blinks-when-running-long-string-than-screen-width?show=2208#a2208</guid>
<pubDate>Sat, 26 Jul 2025 12:07:10 +0000</pubDate>
</item>
<item>
<title>Answered: Misc feedback</title>
<link>https://q2a.vifm.info/2199/misc-feedback?show=2201#a2201</link>
<description>&lt;p&gt;Thanks for the feedback!&lt;/p&gt;
&lt;blockquote&gt;&lt;ol&gt;
&lt;li&gt;When deleting two &lt;em&gt;directories&lt;/em&gt;, you get the message &lt;code&gt;Are you sure you want to delete 2 files?&lt;/code&gt; and after confirmation the message &lt;code&gt;2 files deleted&lt;/code&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;/blockquote&gt;
&lt;p&gt;Will change to &quot;items&quot;.  Being more specific requires more bookkeeping and deciding what to do with things like symbolic links to directories.&lt;/p&gt;
&lt;blockquote&gt;&lt;ol&gt;
&lt;li&gt;A &lt;code&gt;:messages clear&lt;/code&gt; (sub)command might be useful when debugging user commands, like in Vim.&lt;/li&gt;
&lt;/ol&gt;
&lt;/blockquote&gt;
&lt;p&gt;Will add.&lt;/p&gt;
&lt;blockquote&gt;&lt;ol&gt;
&lt;li&gt;I don't know if Vifm is to blame for this, but when using the AppImage version, FUSE mounts over SSH work very slowly, to the point of being almost unusable. The Homebrew version works just fine.&lt;/li&gt;
&lt;/ol&gt;
&lt;/blockquote&gt;
&lt;p&gt;I don't see there being a difference.  Is there a delay when you're making a connection or is everything slow?  The first one could be related to things like SSH agent and associated timeouts.&lt;/p&gt;
&lt;blockquote&gt;&lt;ol&gt;
&lt;li&gt;Is it possible to configure how often the file is reloaded when using automatic forwarding? It feels pretty slow at the moment. Some tests seem to indicate that it's only forwarded once every 10 seconds, while &lt;code&gt;tail -f&lt;/code&gt; reflects updates instantaneously.&lt;/li&gt;
&lt;/ol&gt;
&lt;/blockquote&gt;
&lt;p&gt;You can adjust &lt;a rel=&quot;nofollow&quot; href=&quot;https://vifm.info/docs/vifm-app.txt#vifm-%27timeoutlen%27&quot;&gt;'timeoutlen'&lt;/a&gt; which is 1 second by default (don't know how you got 10 seconds).  There is no delaying of file checks, they happen in response to key presses or when reading a key times out.&lt;/p&gt;
&lt;blockquote&gt;&lt;ol&gt;
&lt;li&gt;The link to the &lt;code&gt;#vifm@Freenode&lt;/code&gt; IRC channel on the website should probably be changed to Libera Chat, or removed.&lt;/li&gt;
&lt;/ol&gt;
&lt;/blockquote&gt;
&lt;p&gt;I wasn't sure if that channel still exists and checked it only now.  Seems to be gone (there is a new one in its place), so removed the link.&lt;/p&gt;
&lt;blockquote&gt;&lt;ol&gt;
&lt;li&gt;I noticed two very small typos in the documentation. I could make a PR, but I'm not sure how to do so because there is both &lt;code&gt;vifm-app.txt&lt;/code&gt; and &lt;code&gt;vifm.1&lt;/code&gt; and I assume one is generated based on the other.&lt;/li&gt;
&lt;/ol&gt;
&lt;/blockquote&gt;
&lt;p&gt;Will fix.  The files are just edited at the same time.  I'm not aware of ways to generate one from the other (although there might be tools for trivial cases).&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2199/misc-feedback?show=2201#a2201</guid>
<pubDate>Wed, 16 Jul 2025 17:40:10 +0000</pubDate>
</item>
<item>
<title>Answered: How to execute a single command from sudo?</title>
<link>https://q2a.vifm.info/2055/how-to-execute-a-single-command-from-sudo?show=2200#a2200</link>
<description>&lt;p&gt;I like to use the following command and key binding for situations like this:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;command! RootRelaunchVifm :!sudo vifm %d %D
nnoremap &amp;lt;Space&amp;gt;R :RootRelaunchVifm&amp;lt;CR&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;You hit the key binding to relaunch Vifm as root, enter your password, move the file to &lt;code&gt;/usr/local/bin&lt;/code&gt;, and finally run &lt;code&gt;:quit&lt;/code&gt; (or a corresponding key binding) to return to your regular Vifm instance.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2055/how-to-execute-a-single-command-from-sudo?show=2200#a2200</guid>
<pubDate>Wed, 16 Jul 2025 17:19:14 +0000</pubDate>
</item>
<item>
<title>how to make vifm choose a single file</title>
<link>https://q2a.vifm.info/2195/how-to-make-vifm-choose-a-single-file</link>
<description>&lt;p&gt;&lt;strong&gt;CONTEXT:&lt;/strong&gt; I am trying to use vifm as a &lt;strong&gt;xdg file chooser&lt;/strong&gt; using the &lt;code&gt;xdg-desktop-portal-termfilechooser&lt;/code&gt; library. But facing some limitations.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;vifm &lt;code&gt;--choose-files&lt;/code&gt; and &lt;code&gt;--choose-dir&lt;/code&gt; always prints a newline to &lt;code&gt;stdout&lt;/code&gt; when selection is abort/or no selection.&lt;/li&gt;
&lt;li&gt;vifm &lt;code&gt;--choose-files&lt;/code&gt; command line argument that lets user select one or multiple objects and then returns the selection. Unlike &lt;code&gt;ranger&lt;/code&gt;, vifm doesn't have a mechanism where only one selection is valid and in case multiple objects selected, it will block and show warning. Is there any plugin or method to simulate such behavior?&lt;/li&gt;
&lt;li&gt;Is there a navigation mode for normal command line operation? (afaik it only works in search mode)&lt;/li&gt;
&lt;/ul&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2195/how-to-make-vifm-choose-a-single-file</guid>
<pubDate>Tue, 15 Jul 2025 04:37:45 +0000</pubDate>
</item>
<item>
<title>How to spawn Erlang LSP server when editing Erlang source?</title>
<link>https://q2a.vifm.info/2191/how-to-spawn-erlang-lsp-server-when-editing-erlang-source</link>
<description>&lt;p&gt;When using standalone Vim, the Erlang Language Server works as expected, using the following CocConfig:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;{
  &quot;languageserver&quot;: {
    &quot;erlang&quot;: {
      &quot;command&quot;: &quot;erlang_ls&quot;,
      &quot;filetypes&quot;: [&quot;erlang&quot;]
    }
  }
}
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;But when I try to open and edit Erlang source files from within Vifm, I get the following error:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;erlang client: couldn't create connection to server.
Launching server using command erlang_ls failed. Error: spawn erlang_ls ENOENT
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;What command should I use in order to spawn the Erlang Lsp from within Vifm?&lt;/p&gt;
&lt;p&gt;Thank you in advance.&lt;/p&gt;
</description>
<category>vifm</category>
<guid isPermaLink="true">https://q2a.vifm.info/2191/how-to-spawn-erlang-lsp-server-when-editing-erlang-source</guid>
<pubDate>Fri, 11 Jul 2025 18:06:28 +0000</pubDate>
</item>
</channel>
</rss>