mirror of
https://github.com/th-ch/youtube-music.git
synced 2026-01-11 02:31:45 +00:00
Merge pull request #1297 from nnnlog/master
fix(downloader): Korean filename is broken on non-macOS devices
This commit is contained in:
@ -199,10 +199,13 @@ async function downloadSongUnsafe(
|
|||||||
presetSetting = presets[preset];
|
presetSetting = presets[preset];
|
||||||
}
|
}
|
||||||
|
|
||||||
const filename = filenamify(`${name}.${presetSetting?.extension ?? 'mp3'}`, {
|
let filename = filenamify(`${name}.${presetSetting?.extension ?? 'mp3'}`, {
|
||||||
replacement: '_',
|
replacement: '_',
|
||||||
maxLength: 255,
|
maxLength: 255,
|
||||||
});
|
});
|
||||||
|
if (!is.macOS()) {
|
||||||
|
filename = filename.normalize('NFC');
|
||||||
|
}
|
||||||
const filePath = join(dir, filename);
|
const filePath = join(dir, filename);
|
||||||
|
|
||||||
if (config.get('skipExisting') && existsSync(filePath)) {
|
if (config.get('skipExisting') && existsSync(filePath)) {
|
||||||
|
|||||||
@ -178,7 +178,7 @@ Some predefined themes are available in https://github.com/kerichdev/themes-for-
|
|||||||
```bash
|
```bash
|
||||||
git clone https://github.com/th-ch/youtube-music
|
git clone https://github.com/th-ch/youtube-music
|
||||||
cd youtube-music
|
cd youtube-music
|
||||||
npm
|
npm ci
|
||||||
npm run start
|
npm run start
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user