Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.
sudo curl -L

how important is that -L?
the manual seems to indicate it's for automatic redirections should that location had been changed

i had only used curl without -L before and it was working fine for me
 
thanks, but yet another question regarding the destination: 😳

/usr/local/bin/youtube-dl

when i was trying to check that location in advance, my /usr/local/ folder is empty as of yet, so no bin/ inside that folder

so is /usr/local/bin/ the default folder macOS is automatically using for add-on executables that didn't come pre-installed with the OS?
 
the download and access permission changes worked beautifully, but when i was trying to launch or just version check it i'm getting this message:

env: python: No such file or directory

restarting Terminal didn't help, so i guess it's time to go down that rabbit hole i was trying to avoid and install Python (or any programming language for that matter)? 🤡
would you suggest using Apple's CLDT, brew download select certain things, or something else? 🤠

(i think i've read that you have to re-install Apple's tools every time you update macOS, but does this mean i'd have to do this again, if 12.5.2 arrived tomorrow, or would this only be necessary if i made a full version upgrade to macOS 13?)
 
the download and access permission changes worked beautifully, but when i was trying to launch or just version check it i'm getting this message:



restarting Terminal didn't help, so i guess it's time to go down that rabbit hole i was trying to avoid and install Python (or any programming language for that matter)? 🤡
would you suggest using Apple's CLDT, brew download select certain things, or something else? 🤠
You already have Python 3, this works on Intel
Code:
echo "alias python=/usr/bin/python3" >> ~/.zshrc
Not sure why it's not working on M1.
We will find a solution without that dreadful homebrew :)
 
alias python=/usr/bin/python3

no change, even after trying to put ' before and after the location to see if that helped


when trying to launch python3 (or python for that matter), even without that alias enabled i'm getting:

xcode-select: note: no developer tools were found at '/Applications/Xcode.app', requesting install. Choose an option in the dialog to download the command line developer tools.


edit: just found it in the /usr/bin/ folder though
 
no change, even after trying to put ' before and after the location to see if that helped
Delete /usr/local/bin/youtube-dl and alias python=/usr/bin/python3 from ~/.zshrc
Use alternative installation method:
Code:
sudo -H pip3 install --upgrade pip
sudo pip3 install youtube_dl
youtube-dl --version
Tested and working on M1 12.5.1 (21G83)
 
what the *pip* am i doing here?

(only understanding gibberish, but will do as you command anyway! 🤘)
 
sudo -H pip3 install --upgrade pip
sudo pip3 install youtube_dl
youtube-dl --version

even trying to execute the first command line, it's asking me to install Apple's Developers Command Line Tools 😂

but maybe they can be useful even for a dummy like me anyway 🤓
 
even trying to execute the first command line, it's asking me to install Apple's Developers Command Line Tools 😂

but maybe they can be useful even for a dummy like me anyway 🤓
I was under the impression that you already installed them, as you used curl.
 
dunno, curl simply worked right out of the box for me 🤷‍♂️

so, will i have to re-install these tools every time i do a .1 (or ..1) update?
or is this only required when switching to a full 1. update?
 
ok, going to install these tools next time i'll put my MBA on a charger, so probably tonight

are there any advantages / disadvantages to any of these methods? (other than approx. 12GB more disk space for option c and d?)

a) pop up window prompt when using certain Terminal commands like ld, python, etc.
b) xcode -select install from the Terminal
c) xcode install from the Terminal
d) xcode install from the App Store?
 
xcode-select --install has alwaays been the command to install the Command Line Tools package
So, a) are b) are the same, c) doesn’t work and d) will install the Xcode app https://developer.apple.com/xcode/
What is the Command Line Tools Package?
The Command Line Tools Package is a small self-contained package available for download separately from Xcode and that allows you to do command line development in macOS.
https://developer.apple.com/library/archive/technotes/tn2339/_index.html
 
ok, so now after having installed Apple CLT, installation "worked" via the alternate route (tried curling & aliasing python first with no luck again)

youtube-dl --version is showing 2021.12.17 for me now

though i got two warning messages during "sudo pip3 install youtube_dl":

  1. WARNING: The directory '/Users/account/Library/Caches/pip' or its parent directory is not owned or is not writable by the current user. The cache has been disabled. Check the permissions and owner of that directory. If executing pip with sudo, you should use sudo's -H flag.
  2. WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv

i guess i can safely disregard #2, but does #1 affect performance in any way? has it been caused by me not having given Terminal full disk access permission yet?


edit:
doing my first test download at the moment
what i find funny is (also noticed this during my first curl attempts), that despite the Terminal not having a GUI, your are provided with actually more download speed related parameters, than on the GUI download window of macOS

though at the moment it is actually really slow for some reason with only 61KB/s - i hope it's YT server related and not by youtube-dl!
luckily, i just chose a <5min @1080p video, ETA is still >2h remaining though 😂
 
sometimes i'm at the point thinking UNIX is totally awesome, and then comes something like this: 😂
Use -H, example to update youtube-dl

did sudo -h install, the response:
Requirement already satisfied: youtube_dl in /Library/Python/3.8/site-packages (2021.12.17)
so it's still the same version as before (maybe with some different cache settings, but i received no feedback regarding this)
do i need to delete it first, or is 2021.12.17 still the latest version?
 
sorry, not a Terminal related question (though still a dummy one ;) )

just finished my first download with youtube-dl and it seems to be capping vids at 720p, even if those are played on YT in 1080p or higher
it is the same behavior i had with VLC player, the one i was using "before"

am i using the wrong URLs, or does YT indeed cap downloads at 720p?

also DL speed seems very slow, haven't gotten more than 70KB/s yet... YT server related?


oh, and lastly: when i first started a download with the version i installed with just sudo, not sudo -h, it was downloading to ~/Downloads, now it's seemingly defaulting to ~/
youtube-dl <URL> ~/Downloads/ was not accepted
 
sorry, not a Terminal related question (though still a dummy one ;) )

just finished my first download with youtube-dl and it seems to be capping vids at 720p, even if those are played on YT in 1080p or higher
it is the same behavior i had with VLC player, the one i was using "before"

am i using the wrong URLs, or does YT indeed cap downloads at 720p?

also DL speed seems very slow, haven't gotten more than 70KB/s yet... YT server related?
This following is one great downloading app. I have used it for years (as have others here) without any problems. It will allow you to download the proper resolution and quickly.

 
  • Like
Reactions: oogje
thanks for the suggestion, but i'm one of those weirdos who's trying to rely on quite a minimal set of tools.
I'm sure it will be good, but i'm already using VLC, which is good for other things like home network streaming too and now youtube-dl.
I might even be just using it wrong though too /steve voice

but maybe now that i've already spoiled my Mac with filthy stuff like CLT, and also sudo'ed some large snake on my HD, i really might start easing up on my OCD and look into other stuff too (like knockknocking my system 😂, or even worse 😱) 👍
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.