[konsole] [Bug 380881] New: Bash interprets COMMAND {folder}/.* as COMMAND {folder}/..
dk
bugzilla_noreply at kde.org
Tue Jun 6 09:31:42 UTC 2017
https://bugs.kde.org/show_bug.cgi?id=380881
Bug ID: 380881
Summary: Bash interprets COMMAND {folder}/.* as COMMAND
{folder}/..
Product: konsole
Version: 17.04.0
Platform: Neon Packages
OS: Linux
Status: UNCONFIRMED
Severity: major
Priority: NOR
Component: general
Assignee: konsole-devel at kde.org
Reporter: datenela at gmail.com
Target Milestone: ---
This is my very first bug entry. Maybe this is normal behavior. But I never
saw this on other Linux machines before (Trusty 14.04 for instance).
Please ask back if something is unclear.
I wanted to chown hidden files in a subdirectory with
chown {user}:{group} -R {folder}/.*
The result was, that all folders and subfolders in . have been touched too.
Same happens with rm -R {folder}/.*. But removing was refused because I
was in ./
That means, {folder}/.* is interpreted also as {folder}/..
Please try:
cd /tmp
mkdir test
mkdir test/test
mkdir test/test/folder1
mkdir test/test/folder2
touch test/test/.hiddenfile
touch test/test/folder1/.hiddenfile1
touch test/test/folder2/.hiddenfile2
cd test
pwd
/tmp/test/test
ls -lath /tmp/test/test
drwxrwxr-x 2 test test 4,0K Jun 6 11:05 folder2
drwxrwxr-x 4 test test 4,0K Jun 6 11:05 .
drwxrwxr-x 2 test test 4,0K Jun 6 11:05 folder1
-rw-rw-r-- 1 test test 0 Jun 6 11:05 .hiddenfile
drwxr-xr-x 3 test test 4,0K Jun 6 11:04 ..
# change folder1 and subfolders to testgroup
chown test:testgroup -R folder1/
ls -lath
drwxrwxr-x 2 test test 4,0K Jun 6 11:05 folder2
drwxrwxr-x 4 test test 4,0K Jun 6 11:05 .
drwxrwxr-x 2 test testgroup 4,0K Jun 6 11:05 folder1
-rw-rw-r-- 1 test test 0 Jun 6 11:05 .hiddenfile
drwxr-xr-x 3 test test 4,0K Jun 6 11:04 ..
# change folder1 and subfolders to testgroup
ls -lath folder1/
drwxrwxr-x 2 test testgroup 4,0K Jun 6 11:05 .
drwxrwxr-x 4 test test 4,0K Jun 6 11:05 ..
-rw-rw-r-- 1 test testgroup 0 Jun 6 11:05 .hiddenfile1
# change folder1 and hidden files to testgroup
chown test:testgroup -R folder1/.*
drwxrwxr-x 2 test testgroup 4,0K Jun 6 11:05 folder2
drwxrwxr-x 4 test testgroup 4,0K Jun 6 11:05 .
drwxrwxr-x 2 test testgroup 4,0K Jun 6 11:05 folder1
-rw-rw-r-- 1 test testgroup 0 Jun 6 11:05 .hiddenfile
drwxr-xr-x 3 test test 4,0K Jun 6 11:04 ..
# Removing subfolders
alias rm='rm -i' # This asks to remove ../
rm -R folder1/.*
rm: refusing to remove '.' or '..' directory: skipping 'folder1/.'
rm: refusing to remove '.' or '..' directory: skipping 'folder1/..'
rm: remove regular empty file 'folder1/.hiddenfile1'? n
As the KDE Neon Dev stable installation is a test installation I cannot
guarantee that I'll have this system still installed when you answer me.
The history should be reproducible.
The installation is a fresh install with a low latency kernel, five or siy
small packages from KXStudio repo installed and with upgraded packages.
ISO: neon-devedition-gitstable-20170605-1854-amd64.iso
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the konsole-devel
mailing list