Skip to content
This repository has been archived by the owner on Dec 1, 2021. It is now read-only.

Piping commands to sort images results not all images to be shown #320

Open
Faalagorn opened this issue Feb 14, 2021 · 8 comments
Open

Piping commands to sort images results not all images to be shown #320

Faalagorn opened this issue Feb 14, 2021 · 8 comments

Comments

@Faalagorn
Copy link

Faalagorn commented Feb 14, 2021

A follow up to #146 (comment) – not sure if that is some limit/bug on my system, it seems that doing something like find . -type f | sort -V | imv sort files properly, but not all files are shown in my folder.

  • imv * shows all 34676 files (just not sorted)
    screenshot_2021-02-14-225319
  • find . -type f | sort -V | imv shows less files (it seems to be random, once it's 4895, then it's 5507 files) (properly sorted)
    screenshot_2021-02-14-225410
@n3f4s
Copy link
Contributor

n3f4s commented Jul 13, 2021

How many files does find . -type f | sort -V give you (you should be able to pipe it to wc -l to get the number of files)?

@Faalagorn
Copy link
Author

How many files does find . -type f | sort -V give you (you should be able to pipe it to wc -l to get the number of files)?

Word count counts it properly:

[faalagorn@faalagorn-pc ZomboidTiles]$ find . -type f | sort -V | wc -l
34676

However, piping it to imv does not. (currently getting 1632 items on that folder)
screenshot_2021-07-14-205342

@n3f4s
Copy link
Contributor

n3f4s commented Jul 15, 2021

Are there some special files in the directory (links, ...)? I haven't managed to reproduce the bug.

@eXeC64
Copy link
Owner

eXeC64 commented Jul 15, 2021

If you pipe the files to disk and run imv using that file as input does the same problem occur? i.e. find . -type f | sort -V > images; cat images | wc -l; imv <images

@Faalagorn
Copy link
Author

Faalagorn commented Jul 15, 2021

This doesn't seem to change anything sadly @eXeC64
125870903-e297dea5-76fe-4895-bca2-6851647f9fcb

I don't think there are any symlinks there really, just a lot of files
, some do have weird names though, not sure if that's the case. I'm using f2fs currently.
screenshot_2021-07-16-013820

@n3f4s
Copy link
Contributor

n3f4s commented Jul 16, 2021

I don't think imv can read xcf images. If you cycle through all the images (using the arrow keys) when calling imv *, does the number of images drop?

EDIT: I've tried with a directory containing those images:

5.jpg
Sélection_002.xcf
\.xcf

And both find . -type f | sort -V | imv and imv * give me the same number of files

@Faalagorn
Copy link
Author

Faalagorn commented Jul 17, 2021

I don't think imv can read xcf images. If you cycle through all the images (using the arrow keys) when calling imv *, does the number of images drop?

Actually, it does, it starts with 34677 images, then when I go back it's 34676
, then after two more 34675 and so on. It seems that it happens to images ending with _? Maybe it's something from my locale? I'm using en_DK.UTF-8

[faalagorn@faalagorn-pc ZomboidTiles]$ cat /etc/locale.conf
LANG=en_DK.UTF-8
[faalagorn@faalagorn-pc ZomboidTiles]$ localectl
   System Locale: LANG=en_DK.UTF-8
       VC Keymap: pl
      X11 Layout: n/a

@n3f4s
Copy link
Contributor

n3f4s commented Jul 17, 2021

The number of images reduce because imv encounter xcf images which it can't read do it removes them from the list (and update the total number of images).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants