Skip to content
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

Windows - Batch variables %% problem #7950

Closed
Kdmeizk opened this issue Dec 22, 2015 · 4 comments
Closed

Windows - Batch variables %% problem #7950

Kdmeizk opened this issue Dec 22, 2015 · 4 comments

Comments

@Kdmeizk
Copy link

@Kdmeizk Kdmeizk commented Dec 22, 2015

@"%HOMEPATH%\Downloads\youtube-dl\youtube-dl.exe" --ignore-config --no-playlist --buffer-size 500000000 --no-cache-dir -o %%HOMEPATH%%\Desktop%(title)s.%(ext)s --console-title -v --print-traffic --no-call-home --youtube-skip-dash-manifest --add-metadata %urlVideo%

Is possible the command prompt can read %HOMEPATH% for -o setting ? The first works, but not for -o. Even with %%%, but I think we are going into an infinite loop

@dstftw
Copy link
Collaborator

@dstftw dstftw commented Dec 23, 2015

-o "%HOMEPATH%\Desktop\%(title)s.%(ext)s" works fine.

@dstftw dstftw closed this Dec 23, 2015
@Kdmeizk
Copy link
Author

@Kdmeizk Kdmeizk commented Dec 23, 2015

I don't know why your output works.

  1. It's necessary to put the drive letter for the output before %HOMEPATH%, is possible to youtube-dl to know itself the drive letter used ? %HOMEPATH% = \Users\Username. Windows understands it and puts the drive letter automatically, youtube-dl doesn't it.
  2. The file below shows you my result : the filename is (ext)s.

output.txt

@dstftw
Copy link
Collaborator

@dstftw dstftw commented Dec 23, 2015

  1. %HOMEDRIVE%
  2. %'s supposed to be plain characters must be escaped in batch file -o "%HOMEPATH%\Desktop\%%(title)s.%%(ext)s".
@Kdmeizk
Copy link
Author

@Kdmeizk Kdmeizk commented Dec 23, 2015

Ok, my searches were bad, I didn't add one more % to youtube-dl's variables.
Thank you so much, it works !

@jaimeMF jaimeMF mentioned this issue Apr 1, 2016
0 of 4 tasks complete
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.