On channels in videos tab you can sort videos by:
- Most popular
- Date added (oldest)
- Date added (newest)
But you cannot sort by length. So I decided to create a bookmarklet to do it in ascending order.
Rust error handling is nice but obligatory. Which makes it sometimes plenty of code.
Functions return values of type Result that is "enumeration". In Rust enumeration means complex value that has alternatives and that alternative is shown with a tag.
Result is defined as Ok or Err. The definition is generic, and both alternatives have
Open Terminal Ctrl+Alt+T
Download Firefox Developer Edition tar file
wget https://download.mozilla.org/?product=firefox-aurora-latest-ssl&os=linux64&lang=en-US
Copy tar file to opt
sudo cp -rp firefox-35.0a2.en-US.linux-x86_64.tar.bz2
Open opt
folder (cd /opt/
) and untar file
sudo tar xjf firefox-35.0a2.en-US.linux-x86_64.tar.bz2
function timeConversion(stringg){ | |
let hour = stringg.substring(0,2) | |
let mins = stringg.substring(3,5) | |
let seconds = stringg.substring(6,8) | |
let timeconvention = stringg.substring(8,10) | |
let rest = stringg.substring(2,8) | |
if(timeconvention == 'PM'){ | |
if(parseInt(hour) != 12){ | |
let hour1 = 0 |
def timeConversion(stringg): | |
hour = stringg[:2] | |
mins = stringg[3:5] | |
seconds = stringg[6:8] | |
timeconvention = stringg[8:] | |
rest = stringg[2:8] | |
if int(hour) >= 1 and int(hour) <= 12 and int(mins) >= 0 and int(mins) <= 59 and int(seconds) >= 0 and int(seconds) <= 59: | |
if(timeconvention == 'PM'): | |
if(int(hour) is not 12): |