Prepend value of system-wide PROMPT_COMMAND variable to the mc's one.
Thanks wjaguar for the idea and Serhiy Storchaka and Oswald Buddenhagen
for the patch itself.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Problem:
Suppose you want to replace a substring in some file names with another,
so you do a File Rename operation with source pattern:
*OLDSTRING*
and target pattern:
\1NEWSTRING\2
If OLDSTRING occurs inside a filename, it is replaced correctly, but if
at the beginning or end of the filename, the corresponding zero-length
wildcard match is replaced by literal \1 or \2, respectively.
Expected
Wildcards that match a zero-length substring should be substituted with
an empty string.
Thanks boris<> for the original patch.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Support for puppet manifest highlighting was kindly
provided by Sergey Zhuga, original is here:
https://github.com/scrill/puppet-syntax-mcedit
Mr. Zhuga agreed with inclusion in mainstream MC:
https://github.com/scrill/puppet-syntax-mcedit/issues/2
Reasons to favor puppet syntax over pascal for .pp files:
---------------------------------------------------------
I will not argue whether in 2014 pascal is still being used or not,
and to what extent. I would like to point out that whoever is using
any variation of pascal for any serious development, is probably not
using 'mcedit' as an IDE. Instead, this development activity is
probably situated in nice, fully-featured graphical IDE.
Platform wise, judging by the weekly download statistics of FreePascal
at SourceForge, at this moment more than 80% of all downloads are for
Windows environents. On the other hand Midnight Commander is Linux
based. Considering this in combination with speculation from the
previous paragraph, there seems to be only a small chance that 'mcedit'
is being used as an editor of choice for pascal development.
On the contrary, puppet currently certainly does have wider audience
amongst sysadmins, who regularly use Linux. Puppet master requires a
server (usually) and quite a few sysadmins edit files directly on
servers that act as puppet masters for puppet development
environments.
When accessing these servers remotely, mcedit comes very handy for
quick edits here and there. Also keep in mind that puppet files are
normally not very large. Therefore actual IDE would be an overkill and
'mcedit' does the job quite ok, but syntax highlighting would be
much appreciated.
To sum it up:
If we speculate about the *actual* usage of 'mcedit', I do believe that
a wider audience would benefit by having .pp files highlighted by
default with puppet syntax definition instead of pascal syntax
definition.
contrib/Makefile.am: mc.sh and friends should depend on config.status.
In this case contrib/*.?sh are recreated after each rerun of configure.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Major rewrite of mcview's parts responsible for rendering and scrolling the contents:
* no more partial lines at the top and failure to scroll when Up or Down
is pressed;
* better handling of CJK characters;
* handle combining accents;
* improved nroff support;
* more conventional scrolling behavior at the end of the file.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
* 3339_mcedit_paste_to_clipboard:
Clarify description of clipboard_store and clipboard_paste options.
Clarify flags and mode to open clipboard file.
Ticket #3339: fix pasting from clipboard.
When clipboard_paste option was set but clipboard utility was not
installed, nothing was pasted and clipboard file became empty.
Solution: reimplement pasting way using mc_pipe_t instead of my_system().
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
* 3265_cleanup: (26 commits)
Update po/*.po files.
Ticket #3333: fix g_error_new_valist().
lib/glibcompat.h: add missing include of stdarg.h.
src/filemanager/boxes.c: move static functions to the matched section.
(sel_skin_button): simplify.
(format_file): remove unused arguments.
mceditor: syntax: reimplement context list using GPtrArray.
mceditor: syntax: remove syntax_keyword_t::first member.
mceditor: syntax: reimplement keyword list using GPtrArray.
(edit_read_syntax_rules): minor refactoring of keyword first chars collect.
(edit_read_syntax_rules): fix pointer tests.
mceditor: reimplement syntax name list using GPtrArray.
Ticket #3277: Info panel can't obtain file system statistics on Solaris.
Recognize "Java archive data (JAR)" as zip archive.
(mcview_offset_doz): use more.
Sync with gnulib 2768ceb7994506e2cfba88be3b6bd13ef5440a90.
Sync with gnulib 3ea43e02541ece750ffc6cd1dfe34195421b4ef3.
(mcview_dimen_min): remove. Use min() macro instead.
(mcview_get_byte_string): minor optimization.
mcviewer: clarify support of UTF-8 codeset.
...
The 'file' utility determine the file type differently:
till file-5.16 - Java Jar file data (zip)
since file-5.17 - Java archive data (JAR)
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
mountlist: don't use libmount to decide on dummy/remote.
Don't use the libmount routines to determine whether a file system is
dummy or remote, as they're not currently compatible. For example the
remoteness is determined on file system type (for which the list seems
incomplete), rather than simply checking for a ':' in the device name.
Also libmount currently determines that 'tmpfs' is a dummy file system
even though it has associated storage.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
mountlist: use /proc/self/mountinfo when available
Use libmount to propagate device IDs provided by Linux in
/proc/self/mountinfo. This will give more accurate output when using df
in chroot'ed environments as the device IDs are not determined by stat()
which may be inaccurate within the chroot.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>