Comments (4)
In that Stack Overflow thread there was another, better readable solution (in particular better readable in the cleanup output window and in the log):
'Don't do this'
-> 'Don'\''t do this'
Implemented with b08df9a.
from qdirstat.
QDirStat had always escaped such single quotes, but not the way common shells (Bash, Zsh) expect it: They don't want a backslash in front of that embedded single quote. Rather, you need to terminate the string with a single quote, start a new one with double quotes only containing the embedded single quote, and then re-open the old string.
Thus, 'Don't do this'
becomes 'Don'"'"'t do this'
.
Yikes. This is so utterly broken by design I can't find proper words for it. I just wonder how much other software is out there that does it the way most people would expect it: Trying to use a backslash to escape that embedded single quote ('Don\'t do this'
).
Of course, such file names should be avoided entirely, but you can't help some slightly broken MP3 ripper program doing it, so it needs to be handled correctly.
Fixed with c8da4e8.
from qdirstat.
As is the case so often, the answer was on Stack Overflow: http://stackoverflow.com/questions/1250079/how-to-escape-single-quotes-within-single-quoted-strings
from qdirstat.
I can confirm the fix works, thank you.
from qdirstat.
Related Issues (20)
- Selected empty directories don't get the correct highlight HOT 5
- Treemap Improvements HOT 1
- More Ideas for Treemap Improvements by @Lithopsian HOT 4
- Mime category config page glitches HOT 1
- Way to follow symlink? HOT 3
- File type statistics don't add up = literally HOT 10
- Qt6 support? HOT 7
- File type statistics for packages sometimes allowed, sometimes not HOT 9
- Find files subtree not updated when the DirTree is reloaded HOT 2
- Unexpected results when refreshing the locate files window HOT 2
- Accelerator clashes HOT 6
- Fonts can't always be resized in the output window HOT 1
- Crash during recursive cleanup with refresh policy "assume deleted" HOT 10
- Cross filesystems setting not respected HOT 2
- Possibly unintended change to the sorting of hardlinks HOT 1
- Crash when unable to open a cache file HOT 5
- 100% CPU after reading is aborted HOT 1
- Package member file sometimes not showing package data in file details view HOT 2
- Erratic crash apparently related to the Unpkg dialog HOT 12
- Question for use in Linux with files with multiple hard links HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from qdirstat.