Jump to content

Raffie77

Member
  • Content Count

    19
  • Joined

  • Last visited

About Raffie77

  • Rank
    Newbie

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. In php you can include other php files. Can I also do that with bash script in Alfred?
  2. Ok tanks deanishe and vitor it starts to make sense now I still love scripting👌
  3. huh?😣 that works ok now I am confused, it's great that it works now thanks @vitor. If you take a look at the script in my first post you see a case k_basRenExtFile and k_basRenCurFile those work. and I thought I used the same technique I'm gonna study this script for a while thank you both for your time, I appreciate that very much
  4. $tracklog is set with -userparam tracklog="$clip" -userparam tracklog= "$clip" ^ ^ ^ exiftool function create a exiftool value defined in the workflow var it's clipboard content1
  5. ok this is a exiftool thing lets say if I want to see the model of a image, I type: ${exiftool} $model photo.jpg if I type: ${exiftool} -overwrite_original -geotag="${clip}" "${files[@]}" exiftool thinks I want to see the property of ${clip} and that doesn't exist that's where the -userparam kicks in -userparam tracklog="$clip" it means create a property tracklog with the value of $clip and $clip means clipboard see the screenshot and when I echo $clip I see this result in the debug: Clip = /Users/ralphschipper/Downloads/2020-05-09 17_15_25.gpx
  6. oh sorry I forgot to say: var tracklog is located in a var in alfred see screenshot when I add this line in te script: ${exiftool} -overwrite_original -userparam tracklog="$clip" -geotag=$tracklog "${files[@]}" echo "Clip = $clip" The debug result = Clip = /Users/ralphschipper/Downloads/2020-05-09 17_15_25.gpx I have the workflow here
  7. It's very bizar I have this script in Alfred: ####################################### #Exiftool utility for Alfred workflow # ####################################### set -x IFS=$'\t' read -ra files <<< "${file_list}" command=${command} #Located at the arg block after the List Filter in the workflow sourceFiles="/Users/$USER/temp/" case $command in basRen) #Basic rename ${exiftool} -d "%Y-%m-%d %H,%M,%S%%-c" '-filename<${DateTimeOriginal} $Make-$Model.%e' "${files[@]}" ;; k_basRenExtFile) #Basic rename with an extra added name from a query ${exiftool} -userparam extName
  8. vitor: thank you very very very much🙌 it works! I nerver heard of/used IFS=$'\t' so i read into that, now I understand I tested this and it still didn't work, the issue is, in this line: ${exiftool} -d "%Y-%m-%d %H,%M,%S%%-c" '-filename<${DateTimeOriginal} $Make-$Model "${1}".%e' "${files[@]}" The "${1}" in this line doesn't work, if you take a look at $Make-$Model that means that Exiftool gets the value of the make and the model. "${1}" is not a Exiftool value, but Exiftool is reading this as a Exiftool value and that value doesn't exist.
  9. ok I have a link to this workflow in my dropbox you can download it here yes I found your labelcolor workflow, I learned from that how to add a keyword in the file action. I hope you can take a look at this workflow. I'm not sure what I am missing here
  10. I also add a keyword in alfred in cas I want to add an extra name like "flower" of "tree" etc. in the script i have this: ${exiftool} -d "%Y-%m-%d %H,%M,%S%%-c" '-filename<${DateTimeOriginal} $Make-$Model "${keyname}".%e' "${files}" If I enable the debug mode I get this message: The "$keyname" is a var that I created in Alfred see screenshot, the first var is the "$files" and the second var = "$keyname" in te script I used "$keyname" with the purpose to enter the text that I typ in Alfred, but Exiftool thinks that "$keyname" is a Exiftool code and that's not
  11. YES that works thank you so much 🥳 this makes life a lot easier thanks
  12. ooohhh shoot, you're right I tweaked the script a bit and it almost works the link that you are refering to is ment for one single file. when I select multiple files in my new script, only one gets renamed how can I make it happen that he renames all the files I select and not just one? Do I need to convert a array or something?
  13. i want to create a script for exiftool so I want to select those files that I want to rename and copy this to the clipboard: exiftool -d "%Y-%m-%d %H,%M,%S%%-c" '-filename<${DateTimeOriginal} $Make-$Model.%e' {multiple files that are decent escaped} ok I never worked with python i'll look into that I see that I can run a Pythons script in Alfred workflow Thanks
  14. Hi, I'm trying to create a workflow that can copy paths for later use. Frist I create a new workflow and add a file action to it that accepts multiple lines then I enter a copy to clipboard module that says {query} I run this script by selecting 2 files and double tap the command key and choose my test script and I paste it textedit the result: /temp/test 1/MapA/test (2).JPG /temp/test 1/MapA/test (1).JPG the thing is when I drag the 2 files to a terminal window I get this: /test\ 1/MapA/test\ \(1\).JPG /test\ 1/MapA/test\ \(2\).JPG f
  15. Oh and btw, I prefer that google opens the photo in satelite mode to fix this I edit this line in the bash script part of your workflow: and made it: now it opens the photo in satelite mode. It took me a while to figure that one out
×
×
  • Create New...