View Single Post
Old 01-31-2017, 04:11 PM   #21
tshering
Wizard
tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.
 
Posts: 3,489
Karma: 2914715
Join Date: Jun 2012
Device: kobo touch
Quote:
Originally Posted by anarcat View Post
that sounds a *lot* like the refresh-library.sh script from the wget-sync hooks... but i couldn't make head or tails of that thing...
I just tried the idea, and I like it. What follows is the minimal version, without testing whether there is an external sd inserted or not. In this case it is supposed that there is no external sd. I created /mnt/onboard/.mysd/ and put a book into it. Then, with nickel running, I did

Code:
(none) login: root
[root@(none) ~]# mkdir -p /mnt/onboard/.mysd
[root@(none) ~]# mount --bind /mnt/onboard/.mysd /mnt/sd
[root@(none) ~]# echo sd add /dev/mmcblk1p1 >> /tmp/nickel-hardware-status
[root@(none) ~]#
nickel reads the book from .mysd, and updates the library whenever you execute:
Code:
 echo sd add /dev/mmcblk1p1 >> /tmp/nickel-hardware-status
tshering is offline   Reply With Quote