@command('save')
def save_last():
 if g.last_opened:
  open_save_view('save', g.last_opened)
 else:
  saveas = ''
  if g.model:
   saveas = g.model[0].title[:18].strip()
   saveas = re.sub('[^-\\w]', '-', saveas, re.UNICODE)
  post = 0
  while g.userpl.get(saveas):
   post += 1
   saveas = ((g.model[0].title[:18].strip() + '-') + str(post))
  saveas = saveas.lstrip('0123456789')
  open_save_view('save', saveas)

@ command ( 'save' ) def save_last ( ) : if g . last_opened : open_save_view ( 'save' , g . last_opened ) else : saveas = '' if g . model : saveas = g . model [ 0 ] . title [ : 18 ] . strip ( ) saveas = re . sub ( '[^-\\w]' , '-' , saveas , re . UNICODE ) post = 0 while g . userpl . get ( saveas ) : post += 1 saveas = ( ( g . model [ 0 ] . title [ : 18 ] . strip ( ) + '-' ) + str ( post ) ) saveas = saveas . lstrip ( '0123456789' ) open_save_view ( 'save' , saveas )
save command with no playlist name .