Jump to content

jjaco

Member
  • Posts

    13
  • Joined

  • Last visited

Posts posted by jjaco

  1. Ah, cool, almost there!
    Now it works as long as I don't have any spaces in the filenames. Somehow the escaping seems not to work. The bug report is:

    [12:13:33.077] ERROR: Convert flv to mp4[Run Script] ffmpeg version 3.1.1 Copyright (c) 2000-2016 the FFmpeg developers
      built with Apple LLVM version 7.3.0 (clang-703.0.31)
      configuration: --prefix=/usr/local/Cellar/ffmpeg/3.1.1 --enable-shared --enable-pthreads --enable-gpl --enable-version3 --enable-hardcoded-tables --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-opencl --enable-libx264 --enable-libmp3lame --enable-libxvid --disable-lzma --enable-vda
      libavutil      55. 28.100 / 55. 28.100
      libavcodec     57. 48.101 / 57. 48.101
      libavformat    57. 41.100 / 57. 41.100
      libavdevice    57.  0.101 / 57.  0.101
      libavfilter     6. 47.100 /  6. 47.100
      libavresample   3.  0.  0 /  3.  0.  0
      libswscale      4.  1.100 /  4.  1.100
      libswresample   2.  1.100 /  2.  1.100
      libpostproc    54.  0.100 / 54.  0.100
    /Users/me/Downloads/bsp: No such file or directory
    ffmpeg version 3.1.1 Copyright (c) 2000-2016 the FFmpeg developers
      built with Apple LLVM version 7.3.0 (clang-703.0.31)
      configuration: --prefix=/usr/local/Cellar/ffmpeg/3.1.1 --enable-shared --enable-pthreads --enable-gpl --enable-version3 --enable-hardcoded-tables --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-opencl --enable-libx264 --enable-libmp3lame --enable-libxvid --disable-lzma --enable-vda
      libavutil      55. 28.100 / 55. 28.100
      libavcodec     57. 48.101 / 57. 48.101
      libavformat    57. 41.100 / 57. 41.100
      libavdevice    57.  0.101 / 57.  0.101
      libavfilter     6. 47.100 /  6. 47.100
      libavresample   3.  0.  0 /  3.  0.  0
      libswscale      4.  1.100 /  4.  1.100
      libswresample   2.  1.100 /  2.  1.100
      libpostproc    54.  0.100 / 54.  0.100
    copy.flv: No such file or directory

    The filename is "bsp copy.flv". If I use "bsp_copy.flv", it works.

     

    Since I don't understand yet how the "$f" and "${f}.mp4" work, I am still stuck… any hint appreciated!

  2. Thanks, sounds good.

    I made some mistake, though. Debugger says:

    [12:00:14.053] Convert flv to mp4[File Action] Processing complete
    [12:00:14.058] Convert flv to mp4[File Action] Passing output '(
        "/Users/me/Dropbox/Strassenszenen_Frankfurt_20er_Jahre.flv",
        "/Users/me/Dropbox/Paul.flv"
    )' to Run Script
    [12:00:14.077] ERROR: Convert flv to mp4[Run Script] /Users/me/Library/Caches/com.runningwithcrayons.Alfred/Workflow Scripts/0B1A8350-B332-46E9-966D-284D2305D6A1: line 2: ffmpeg: command not found
    /Users/me/Library/Caches/com.runningwithcrayons.Alfred/Workflow Scripts/0B1A8350-B332-46E9-966D-284D2305D6A1: line 2: ffmpeg: command not found
    /Users/me/Library/Caches/com.runningwithcrayons.Alfred/Workflow Scripts/0B1A8350-B332-46E9-966D-284D2305D6A1: line 2: ffmpeg: command not found
    /Users/me/Library/Caches/com.runningwithcrayons.Alfred/Workflow Scripts/0B1A8350-B332-46E9-966D-284D2305D6A1: line 2: ffmpeg: command not found
    /Users/me/Library/Caches/com.runningwithcrayons.Alfred/Workflow Scripts/0B1A8350-B332-46E9-966D-284D2305D6A1: line 2: ffmpeg: command not found
    /Users/me/Library/Caches/com.runningwithcrayons.Alfred/Workflow Scripts/0B1A8350-B332-46E9-966D-284D2305D6A1: line 2: ffmpeg: command not found
    /Users/me/Library/Caches/com.runningwithcrayons.Alfred/Workflow Scripts/0B1A8350-B332-46E9-966D-284D2305D6A1: line 2: ffmpeg: command not found
    /Users/me/Library/Caches/com.runningwithcrayons.Alfred/Workflow Scripts/0B1A8350-B332-46E9-966D-284D2305D6A1: line 2: ffmpeg: command not found

    I copied your script, the settings are in the image attached.

     

    Any ideas?SettingsAlfred.thumb.png.0be1dc1a497bf6fbeb52e97322f36722.png

     

  3. I want do do a simple processing of several files with bash/Alfred file action. I am a bit embarrassed to ask, but I just don't get how to process several files. I read, Alfred passes the selected files to the workflow and I should use argv. But I searched the Forum and the web for hours, I found no example.

    My script is easy as this: 

    ffmpeg -i sys.argv[1] -vcodec copy sys.argv[1].mp4

    But apparently, this is not how it works. The Debugger says "no matches found: sys.argv[1]" 

     

    What does work, but only for single files:

    ffmpeg -i {query} -vcodec copy {query}.mp4

    When I run this for several files, Terminal asks me if I want to overwrite the existing file before doing anything else.

     

    What am I missing? I know it is easy, but I could just not find an answer… Any hint appreciated!

  4. Thank you very much for your quick reply.

    Unfortunately, I can't get it to work.

    The File Action and Run Script I did set up, but invoking the workflow seems to do nothing.

     

    Is it possible that there is a problem with the $-signs in the code?

    I am new to bash, but shouldn't  $query and $element have a $-sign?

     

    But adding them did not did the trick for me.

    Neither did the script

    gzip {query}

    work for a single file. 

     

    It seems so simple, but I am stuck - embarrassing. 

  5. Hi,

     

    I am trying to achieve something quite simple, but can't do it. I want a workflow which gzips all selected files in the Finder in an archive each.

     

    So I created a hotkey, and a Terminal command with gzip - but to no avail. Just nothing happens, no error, nothing.

     

    Any ideas to get me started?

     

    Thanks in advance,

    J

  6. I love the new workflows, and I use it to rate my unrated songs. I created a Workflow that rates the current song and plays the next. The only problem is: it is highly unreliable.

     

    I have an intelligent playlist in iTunes which contains only the unrated songs. In prior versions of iTunes, when a song was rated, it disappeared from the list and the next was played. But in the current version, playback stops. So I use I workflow which rates the song and issues a "Play/Pause" action. But 1 in 3 times, this command is issued before the rated song is purged from the list by iTunes, and so playback stops.

     

    So: please add a "play" action to the workflow commands.

     

    Thanks for considering this!

×
×
  • Create New...