-
Notifications
You must be signed in to change notification settings - Fork 127
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Handle files with leading at signs, update README #50
base: master
Are you sure you want to change the base?
Handle files with leading at signs, update README #50
Conversation
fafc06f
to
9c369f1
Compare
Are you sure about empty filenames working? I have the same version of ImageMagick and I have to hit ^C to cancel. $ convert --version
Version: ImageMagick 6.9.11-60 Q16 x86_64 2021-01-25 https://imagemagick.org
$ convert "" foo.png
^C I do like that you encapsulated imescape in a function, but doesn't it seem like overkill to fork a new Using Bash's builtin regular expressions, or even just globbing, would be one way to avoid a fork, but it still isn't ideal: imescape() {
[[ $1 == @* ]] && echo -n ./
echo "$1"
} I want to resist the impulse to let |
I wanted to do the minimum patch, size-wize, to remedy this issue. If you're comfortable with me making the change at a higher level, i'm pretty sure i can combine all of this into one sed, or come up with a better solution. let me play around with imagemagick a bit today and see what can be done. |
I think I missed something. What else were you going to fix with 'sed'? I'm open to a larger patch if it helps me to understand the grand scheme. |
oh, well you've just already got several there's no grand scheme =] just gonna take an hour at some point and see if this can be slimmed down =] |
Ah, you are referring to processlabel(), the seamy underbelly of lsix that features That discreditable bit of code has long bothered me and eventually I would like to remove it. I think the ideal solution would be if ImageMagick's montage understood how to shorten filename labels (by wrapping or eliding) so they do not extend beyond a tile. Similarly, it may make the most sense to submit a patch to ImageMagick so that it does not get confused by a filename of "" or "@foo". |
The bit about empty strings no longer appears to be the case, at least with ImageMagick 6.9.11-60. Update README. When supplied an initial '@', prefix it with './' to work around another IM issue. Update README.