Questions about file naming process



Hughters birthdayi,

i am trying to set up a photobooth for my daughter's birthday, using the same script to print and save as I used 4 years ago. But something has changed.

This is what happens when I use inotify to detect a new photo in the webcam folder, it is the extra characters after the .jpg suffix which is messing with the process. Here is the output

andrewg linux-ltv0:~> inotifywait -m ~/Pictures/Webcam
Setting up watches.
Watches established.
/home/andrewg/Pictures/Webcam/ CREATE 2016-06-17-185734.jpg.C4S7IY
/home/andrewg/Pictures/Webcam/ OPEN 2016-06-17-185734.jpg.C4S7IY
/home/andrewg/Pictures/Webcam/ MODIFY 2016-06-17-185734.jpg.C4S7IY
/home/andrewg/Pictures/Webcam/ CLOSE_WRITE,CLOSE 2016-06-17-185734.jpg.C4S7IY
/home/andrewg/Pictures/Webcam/ MOVED_FROM 2016-06-17-185734.jpg.C4S7IY
/home/andrewg/Pictures/Webcam/ MOVED_TO 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ OPEN,ISDIR
/home/andrewg/Pictures/Webcam/ ACCESS,ISDIR
/home/andrewg/Pictures/Webcam/ ACCESS,ISDIR
/home/andrewg/Pictures/Webcam/ CLOSE_NOWRITE,CLOSE,ISDIR
/home/andrewg/Pictures/Webcam/ OPEN,ISDIR
/home/andrewg/Pictures/Webcam/ ACCESS,ISDIR
/home/andrewg/Pictures/Webcam/ ACCESS,ISDIR
/home/andrewg/Pictures/Webcam/ CLOSE_NOWRITE,CLOSE,ISDIR
/home/andrewg/Pictures/Webcam/ OPEN 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ ACCESS 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ ACCESS 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ ACCESS 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ ACCESS 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ ACCESS 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ ACCESS 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ ACCESS 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ ACCESS 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ ACCESS 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ ACCESS 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ ACCESS 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ CLOSE_NOWRITE,CLOSE 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ OPEN 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ ACCESS 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ CLOSE_NOWRITE,CLOSE 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ OPEN 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ ACCESS 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ CLOSE_NOWRITE,CLOSE 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ OPEN 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ ACCESS 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ ACCESS 2016-06-17-185734.jpg
/home/andrewg/Pictures/Webcam/ CLOSE_NOWRITE,CLOSE 2016-06-17-185734.jpg

The lpr routine does not recognise the filename with extra suffix.

Any ideas on how a shot can be saved without having to be renamed?

Thanks

Andrew Greig
Melbourne, Australia


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]