@@ -32,7 +32,8 @@ private static void Authenticate()
3232 string frob = f . AuthGetFrob ( ) ;
3333 string url = f . AuthCalcUrl ( frob , AuthLevel . Read ) ;
3434 System . Diagnostics . Process . Start ( url ) ;
35- Console . Write ( "Press ENTER to continue once you have authorized this app." ) ;
35+ Console . WriteLine ( "Press ENTER to continue once you have authorized this app." ) ;
36+ Console . Write ( "--> " ) ;
3637 Console . ReadLine ( ) ;
3738 Auth auth = f . AuthGetToken ( frob ) ;
3839 userId = auth . User . UserId ;
@@ -113,6 +114,13 @@ private static void MergeVideos()
113114 }
114115 }
115116 int count = 0 ;
117+ Console . WriteLine ( "Found {0} videos and {1} metadata, press ENTER to proceed." , videos . Count , idsToPaths . Count ) ;
118+ Console . Write ( "--> " ) ;
119+ if ( Console . ReadKey ( ) . Key != ConsoleKey . Enter )
120+ {
121+ Console . WriteLine ( ) ;
122+ return ;
123+ }
116124 foreach ( string file in videos )
117125 {
118126 string id = Path . GetFileNameWithoutExtension ( file ) ;
@@ -128,6 +136,15 @@ private static void MergeVideos()
128136 {
129137 File . Delete ( newFile ) ;
130138 }
139+ // delete the txt file and mp4 file
140+ if ( File . Exists ( path ) )
141+ {
142+ File . Delete ( path ) ;
143+ }
144+ if ( File . Exists ( mp4File ) )
145+ {
146+ File . Delete ( mp4File ) ;
147+ }
131148 File . Move ( file , newFile ) ;
132149
133150 // copy over dates
@@ -136,9 +153,6 @@ private static void MergeVideos()
136153 info . CreationTimeUtc = oldInfo . CreationTimeUtc ;
137154 info . Refresh ( ) ;
138155
139- // delete the txt file and mp4 file
140- File . Delete ( path ) ;
141- File . Delete ( mp4File ) ;
142156 Console . Write ( "Videos Moved: {0} \r " , ++ count ) ;
143157 if ( Console . KeyAvailable && Console . ReadKey ( true ) . Key == ConsoleKey . Enter )
144158 {
0 commit comments