Bug 318034 - Trailing spaces are not removed from file or directory name
Summary: Trailing spaces are not removed from file or directory name
Status: CONFIRMED
Alias: None
Product: krusader
Classification: Applications
Component: general (other bugs)
Version First Reported In: unspecified
Platform: Ubuntu Linux
: NOR wishlist
Target Milestone: ---
Assignee: Krusader Bugs Distribution List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-04-08 13:43 UTC by Murz
Modified: 2020-05-24 20:49 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Murz 2013-04-08 13:43:24 UTC
When we create the file or directory via copy-paste from other documents, very often pastes name with trailing space or tabulation, for example "folder name  " instead of "folder name".
And Krusader creates folder with trailing spaces, that not visible in file list.
Will be good if Krusader trim all spaces after file name, and maybe - before filename.
But I find the issue https://bugs.kde.org/show_bug.cgi?id=148866 with another situation - author want that spaces stay here. 
Good solution will be add an option in settings for tune up this process. Can you add this in future versions?
Comment 1 Toni Asensi Esteve 2020-05-24 20:49:24 UTC
As it was shown in [news from yesterday](https://pointieststick.com/2020/05/23/this-week-in-kde-we-have-migrated-to-gitlab/):

KDE developers also found this "remove trailing whitespaces" dilemma:
    - Bug 421075 - Trailing Whitespace when creating directories or files
        https://bugs.kde.org/show_bug.cgi?id=421075
    where it was argued:
        Consistency with other file managers.
            - Nautilus, Thunar, Nemo, etc all prevent you from entering 
        a name with a trailing or leading white space.                
        [...]

    - Show inline warning when creating items with leading or trailing spaces
        https://phabricator.kde.org/D29483
        "This is a somewhat unusual thing for a user to do intentionally, so let's show a warning to make sure they're aware that they're doing it."

    - Also related:
        - Show feedback inline when creating new files or folders
            https://phabricator.kde.org/D21907
            https://phabricator.kde.org/file/data/sl4mjdloflybh5gu3z26/PHID-FILE-jufyl66qrkil2lfwfrgn/Peek_2019-06-19_17-59.gif