Created
September 6, 2018 16:41
-
-
Save arthurwolf/03baa542a06196e82dd3fa4031ed58f3 to your computer and use it in GitHub Desktop.
HOW MAKE SHORTER ?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if( progress_answer.match(/est time/)){ | |
var found = progress_answer.match(/file: (.+?), (\d+) % complete, elapsed time: (\d+):(\d+):(\d+), est time: (\d+):(\d+):(\d+)/); | |
that.status.file = found[1]; | |
that.status.percent = found[2]; | |
that.status.elapsed.set(found[3], found[4], found[5]); | |
this.status.estimated.set(found[6], found[7], found[8]); | |
}else{ | |
var found = progress_answer.match(/file: (.+?), (\d+) % complete, elapsed time: (\d+):(\d+):(\d+)/); | |
that.status.file = found[1]; | |
that.status.percent = found[2]; | |
that.status.elapsed.set(found[3], found[4], found[5]); | |
this.status.estimated.set('00', '00', '00'); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment