Skip to content

Commit bfde271

Browse files
authored
Added README.md
1 parent ad0be9d commit bfde271

File tree

1 file changed

+48
-0
lines changed

1 file changed

+48
-0
lines changed

YouTube Audio Downloader/README.md

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
# How To Download Audio Of A YouTube Video?
2+
3+
1. Setup python and pip if you haven’t already
4+
5+
2. Install virtualenv
6+
7+
`pip install virtualenv`
8+
9+
3. Create Virtual environment
10+
11+
`virtualenv venv`
12+
13+
4. Activate virtual environment
14+
15+
- `source venv/bin/activate` (Linux)
16+
- `venv\Scripts\activate` (Windows)
17+
18+
5. Install requirements
19+
20+
`pip install -r requirements.txt`
21+
22+
6. Specify url of the YouTube video whoose audio you want (in YouTubeAudioDownloader.py)
23+
24+
ex: `url = "https://www.youtube.com/watch?v=ZSXN_dpG5jk"`
25+
26+
7. Run YouTubeAudioDownloader.py
27+
28+
![YouTubeAudioDownloader.py Output](https://github.com/sejalsksagar/Amazing-Python-Scripts/blob/youtube_audio/YouTube%20Audio%20Downloader/Output.PNG)
29+
30+
You will find file of .webm format downloaded in the same folder.
31+
32+
## How To convert .webm to .mp3 format?
33+
34+
1. Install moviepy in the same environment
35+
36+
`pip install moviepy==1.0.3`
37+
38+
2. Specify path of .webm file (in WebmToMp3.py)
39+
40+
ex: `clip = mp.AudioFileClip("C:/Users/sejal/Desktop/YouTube Audio Downloader/Rainbow.webm").subclip()`
41+
42+
3. Specify path where .mp3 file should be saved (in WebmToMp3.py)
43+
44+
ex: `clip.write_audiofile("C:/Users/sejal/Desktop/YouTube Audio Downloader/rainbow.mp3")`
45+
46+
4. Run WebmToMp3.py
47+
48+
![YouTube Audio Downloader Folder](https://github.com/sejalsksagar/Amazing-Python-Scripts/blob/youtube_audio/YouTube%20Audio%20Downloader/Folders.PNG)

0 commit comments

Comments
 (0)