Accesso rapido:  

Forum: General Discussion

Topic: Cue file into Youtube Playlist format
Just wanted to share to all users that not are familiar with using open source in github and how to use them. Like my myself since I'm to used with windows and .exe programs

Simply tried ChatGPT to convert the cuefile as a tracklist for youtube and hearthis.at

With this command
Strip these lines in plain text with timecode - performer - title; Convert Index 01 from minutes:seconds:frame to hours:minutes:seconds; case convert every first letter in word

Copy and paste the cue file that wanted to be used
ex:
TRACK 01 AUDIO
TITLE "Tragedy Blows on the Dancefloor (Kesha, Sophie Ellis-Bextor, Cutting Crew vs. Bee Gees)"
PERFORMER "Titus Jones"
INDEX 01 00:00:00
TRACK 02 AUDIO
TITLE "Call My Name"
PERFORMER "BLOND:ISH"
INDEX 01 02:41:00
TRACK 03 AUDIO
TITLE "HIPS DON`T LIE / SMACK YO (Charlie Roennez Mashup)"
PERFORMER "Shakira"
INDEX 01 05:49:00


With the result
Here are the lines stripped in plain text with the requested format:

**00:00:00 - Titus Jones - Tragedy Blows On The Dancefloor (Kesha, Sophie Ellis-Bextor, Cutting Crew Vs. Bee Gees)**
**02:41:00 - BLONDISH - Call My Name**
**05:49:00 - Shakira - Hips Dont Lie / Smack Yo (Charlie Roennez Mashup)**
 

Inviato Mon 04 Nov 24 @ 7:13 am
locoDogPRO InfinityModeratorMember since 2013
You could have done this with a regex incantation, without having to second guess if AI just decided to make something up.

Source input .cue file


Search for
([\n]{0,1})\s*TRACK \d+ AUDIO\n\s{4}TITLE "(.+)"\n\s{4}PERFORMER "(.+)"\n\s{4}INDEX \d+ (\d+:\d+):\d+

replace all with
\1**\4 - \3 - \2**

After replacing


Then as a second pass to convert minutes to hours:minutes
you need a different np++ plugin [multiReplace] search using regex, allow variables
Search for
\*\*(\d+)

replace with
set( string.format("**%02d:%02d", math.floor(CAP1 / 60), CAP1 % 60) )

After 2nd pass


Top 3 lines if you don't want to just deal with it manually
Ctrl+H for
\A.+\n.+\n.+

replace with
**Tracklisting**


Output
**Tracklisting**
**00:00:00 - Fed. - Christ Blaster (EP Vers.)**
**01:04:26 - Labmig - Access Only For Beautiful People**
**02:05:19 - Fed. - 92 (Wild Thing)**



Job done without glugging drinkable water or using power solving already solve problems.
 

Inviato Mon 04 Nov 24 @ 9:47 am
locoDogPRO InfinityModeratorMember since 2013
Truth be told, GPT got it wrong, unless your second track started 2 hours into the mix.
My regex is right.
 

Inviato Mon 04 Nov 24 @ 11:31 am
Worked yesterday with timecode that work. Today it didn't do the same with the same input. Strange.. Thought it would do the same as yesterday.

I need to do course A in computer programming before I can use the code you shared @logodog. Thanx anyway
 

Inviato Mon 04 Nov 24 @ 12:10 pm
I've also done this with a Python script to upload the tracklist to Mixcloud (also with the ability to adjust times if joining recordings together in audacity).

IMO ChatGPT almost always gets the most important details wrong for any non-trivial problem you throw at it (it's even hallucinated API calls to me at times...try it for any non trivial vdjscript operation). It's always good to know what you want to do, have a general idea of how it could be done and definitely know when it's done wrong, otherwise you'll be in for some disappointment with ChatGPT or any other Generative AI tool.
 

Inviato Mon 04 Nov 24 @ 1:41 pm
locoDogPRO InfinityModeratorMember since 2013
I might make it as a c++ thing if I get bored over the quite times. I'm not 100% sure it can be done with just regex, the whole MMM:SS > HH:MM:SS feels tricky,
I think I could do it with a brute force of a few hundred passes.

it probably can but needs some cursed 100 char incantation to be done right,

Actually I might hack a crack at a np++ plugin, there's a couple of things I wish it could do, finding 3 digits and doing a bit of math to replace feels entry level enough.
 

Inviato Mon 04 Nov 24 @ 2:06 pm
Got it to work when logging in
Using This link

Since I'm not a programmer and don't have the skills to work with code, I'm only trying find tools to skip the manual editing.

Starting 1983 with basic and my only education
10 print "deejayskye";
20 goto 10
Run
 

Inviato Mon 04 Nov 24 @ 4:02 pm
locoDogPRO InfinityModeratorMember since 2013
My code update with corrections
 

Inviato Sun 17 Nov 24 @ 12:33 am
locoDog wrote :

Search for
([\n]{0,1})\s*TRACK \d+ AUDIO\n\s{4}TITLE "(.+)"\n\s{4}PERFORMER "(.+)"\n\s{4}INDEX \d+ (\d+:\d+):\d+

replace all with
\1**\4 - \3 - \2**




Noob question, but where and which file do I want to search and edit?
 

Inviato Sat 30 Nov 24 @ 2:28 pm
locoDogPRO InfinityModeratorMember since 2013
The .cue file.
 

Inviato Sat 30 Nov 24 @ 2:33 pm
locoDogPRO InfinityModeratorMember since 2013






slightly edited the regex as cue is written with just \n not \r\n
 

Inviato Sat 30 Nov 24 @ 2:51 pm
Noob Q #2
Edit: Multireplace found.
Can't find the refresh but maybe it is the same as Ctrl+R
Seems I'm missing the accurate plugins for my Notepad++.
Which one's should be used?
 

Inviato Sun 01 Dec 24 @ 9:42 am
locoDogPRO InfinityModeratorMember since 2013
multireplace download it via "plugin admin"
 

Inviato Sun 01 Dec 24 @ 9:48 am
Finally got it to work, thanx a million for quick support and updating the main post instruction @locodog

Had to clear the asterisks (*) from the format since www.hearthis.at mess up with them uploading playlist
Added that feature and also used case conversion to proper case

When trying to use MACRO for all steps for an easy one click command, the plugin Multireplace wouldn't record that piece of action. Seems to not be implemented in the script for macro, which is sad.

Anyway, the result. Awsome job Locodog
**Tracklisting**
00:00:00 - Robin S & Crystal Waters - 100_ Pure Luv (Dario Db Bootleg)
00:01:43 - Faithless - Drifting Away
00:04:44 - Sidney Youngblood - If Only I Could (Sgt Slick Recut)
00:08:52 - Kylie - Dancing (Stormby's Big Night Out Club)
00:12:32 - Robyn - Dancing On My Own (Fred Falke Club)

 

Inviato Sun 01 Dec 24 @ 3:29 pm
locoDogPRO InfinityModeratorMember since 2013
multiReplace you can save steps as a list, then use list.
write this to a notepad file save as .csv you can then load it in to multiReplace
and it will do everything in 1 click

YTstyle.csv
Selected,Find,Replace,WholeWord,MatchCase,UseVariables,Regex,Extended
1,"([\\n]{0,1})\\s*TRACK \\d+ AUDIO\\n\\s{4}TITLE ""(.+)""\\n\\s{4}PERFORMER ""(.+)""\\n\\s{4}INDEX \\d+ (\\d+:\\d+):\\d+","\\1**\\4 - \\3 - \\2",0,1,0,0,1
1,"\\*\\*(\\d+)","set( string.format(""%02d:%02d"", math.floor(CAP1 / 60), CAP1 % 60) )",0,1,1,0,1
1,"\\b(\\w)","\\U\\1",0,0,0,0,1
1,"\\A.+\\n.+\\n.+","**Tracklisting**",0,0,0,0,1
 

Inviato Mon 02 Dec 24 @ 12:04 am