Rockbox.org home
Downloads
Release release
Dev builds dev builds
Extras extras
themes themes
Documentation
Manual manual
Wiki wiki
Device Status device status
Support
Forums forums
Mailing lists mailing lists
IRC IRC
Development
Bugs bugs
Patches patches
Dev Guide dev guide
Search



Donate

Rockbox Technical Forums


Login with username, password and session length
Home Help Search Staff List Login Register
News:

Thank You for your continued support and contributions!

+  Rockbox Technical Forums
|-+  Support and General Use
| |-+  Plugins/Viewers
| | |-+  Usefull Bookmark Tools written by LUA
« previous next »
  • Print
Pages: [1]

Author Topic: Usefull Bookmark Tools written by LUA  (Read 1360 times)

Offline Purple

  • Member
  • *
  • Posts: 1
Usefull Bookmark Tools written by LUA
« on: March 15, 2013, 06:22:12 AM »
Hi,
I wrote little script that make my life with Rockbox easy :)
It does three things:
1) Create playlist from marked songs and put it to song's folder
2) Move marked songs to separate folder( /<source-folder> (b)/ )
3) Delete files in folder before last marked.
Every thing has a choice to delete source .bmark file if you already don't need to keep it.
I tested it on Sansa Clip+, but it must work on other platforms.

Some explanation.
1) For example you have collection of songs /music/MegaHits2013/*.mp3
During listen you bookmarked few songs you liked. By default bookmarks saved in /music/MegaHits2013.bmark file.
After you run the script, chose "Create playlist" and select /music/MegaHits2013.bmark file you will have an /music/MegaHits2013/#best.m3u8 file with all songs which you previous marked.

2) For example you have the same collections of songs /music/MegaHits2013/*.mp3 and /music/MegaHits2013.bmark file.
After you run the script, chose "Move to new dir" and select /music/MegaHits2013.bmark file you will have created new folder /music/MegaHits2013 (b)/ and all marked files will be moved to this folder.
Usually after this I go to file browser and manually delete source /music/MegaHits2013/ folder to leave only favorite songs and free space.

3) For example you have an audiobook saved as
/audiobooks/Erich Maria Remarque - Three Comrades/001.mp3
...
/audiobooks/Erich Maria Remarque - Three Comrades/154.mp3
During listing you save your last listed position (ex. 107.mp3 03:25) in bookmark so /audiobooks/Erich Maria Remarque - Three Comrades.bmark file is created.
After you run the script, choose "Delete files before last bookmark",  and select /audiobooks/Erich Maria Remarque - Three Comrades.bmark file, next files start from 001.mp3 till 106.mp3 will be deleted.
Be careful if you have files named 1.mp3, 2.mp3,... 9.mp3, 10.mp3 and numerical sorting setup in you rockbox! Because script sorting files only alphabet and delete 10.mp3 immediately after 1.mp3, not after 9.mp3.

If you have any ideas about it, please write.

UPD: Added 4th function for cleanup - "Del all except marked".
It deletes all music files in directory except bookmarked files. It doesn't delete pictures, texts or other fies, only deletes files with same extension as last bookmarked file.
* Bookmark_Tools.lua.txt (10.95 kB - downloaded 140 times.)
« Last Edit: March 29, 2013, 05:31:35 AM by Purple »
Logged

  • Print
Pages: [1]
« previous next »
+  Rockbox Technical Forums
|-+  Support and General Use
| |-+  Plugins/Viewers
| | |-+  Usefull Bookmark Tools written by LUA
 

  • SMF 2.0.17 | SMF © 2019, Simple Machines
  • Rockbox Privacy Policy
  • XHTML
  • RSS
  • WAP2

Page created in 0.045 seconds with 15 queries.